Mines - Original TR4 setup
by Fluen

Imagine that Lara moves around in a warzone. Some areas are mined and prevent her from passing through. Lara's objective is to acquire a mine detonator that makes all mines explode and thus clear her path.

My tutorial explains how to make this possible.

Necessary objects:

From the Trenches-wad you will need:

- MINE 
- PUZZLE_ITEM8 (mine detonator)
- PUZZLE_ITEM8_COMBO1 (mine detonator body - optional)
- PUZZLE_ITEM8_COMBO2 (mine position data - optional)
- ANIMATING11 (optional)

- MESHSWAP3 (Lara holding the mine detonator)
- LARA (with all animations from a revised wad)

And for your script you will need the lines:

Puzzle= 8,Mine Detonator, $0008,$0400,$8000,$0000,$0000,$2002 
PuzzleCombo= 8,1,Mine Detonator Body, $0008,$0400,$8000,$0000,$0000,$0002 
PuzzleCombo= 8,2,Mine Position Data, $0004,$0280,$8000,$c000,$0000,$0002 

The two lines about the puzzle_combos are optional. But you must have a line about puzzle_item8 or the setup will not work. Lara will simply refuse to use it, even if you have done everything else correctly.

What to do

1. Use all rooms up to room 25 and/or room 26. One of these two rooms is where Lara is able to use the detonator so keep one of them available for this.

2. Place mines where you want them in your level. You must place some in the room you intend to use for the detonation setup (room 25 and/or 26).

The mines must have the default OCB code (OCB = 0). They will be visible in the editor, but invisible and deadly in game. They don't need a trigger.

When Lara steps on a block where a mine is placed it will explode and kill her. She is able to jump unharmed over the block with the mine, because it works like a kind of pad-trigger.

Ouch! Lara touched a mine!

3. Because the mines are invisible to the player you must use some kind of warning of the mine fields. Animating11 is a fence/sign warning of danger. Place it to warn of the mined areas.

4. Now make your room for the detonation setup. It must be small to make sure Lara stands on a block next to the mines when she uses the detonator.

If Lara stands too far away from the mines she will perform the correct animation with the mine detonator in her hand and the mine detonator will be gone from the inventory afterwards, but the mines stay intact.

5. It is up to you if you want Lara to acquire the mine detonator in one piece or if she must search for the two parts of it.

6. The setup doesn't need a trigger. Lara must simply stand on a block next to a mine in either room 25 or room 26 and the player must manually select the mine detonator from the inventory - just like when the waterskin or the mechanical scarab is used.

7. Open your script and add the lines about the mine detonator and (optional) the parts it consists of to your level. Save and convert your script.

Note: When Lara uses the mine detonator all mines with OCB = 0 in the entire level detonate.
Mines with OCB = 1 are visible to the player, they don't harm Lara, they need a trigger to explode and they are not affected by the mine detonation setup.

Let's use the mine detonator

The blue line in the picture above indicates the border of room 25. If Lara stands behind this line she will refuse to use the mine detonator.

Boom!

All clear!