Go Back   www.tombraiderforums.com > Tomb Raider Modding > Tomb Raider Level Editor > Tutorials and Resources

Closed Thread
Thread Tools
Old 12-04-19, 23:54   #1
Danath's Avatar
Join Date: Apr 2005
Location: Barcelona, Spain
Posts: 1,577
Lightbulb Dxtre3D - Using alternate flags + Dragon boss

Greetings, in this thread i want to share with you something quite valuable i learned for building levels in Dxtre3D. It is the use of alternate flags.

First, what are alternate flags?
Alternate flags are a tool that can help with one of TR1/2/3 biggest limitations: you can only have 1 group of alternate rooms activated/deactivated. All the alternate rooms in a level change at the same time!
These flags store the state of an alternate set of rooms, giving the illusion that different alternate groups can be used on a level.

This doesn't change the fact that all altenate rooms change together, but it lets you control when to have alternates active. So this way you can have different puzzles in different places of the level that use alternates to change rooms, and have each of the puzzles solved or not independently.
The only 2 downsides to this system are that you have to setup it in a way that you cannot see the groups of rooms changing before you enter them, and you have to deactivate all alternates when leaving each of the zones.

Let me show you a picture to explain how it is used in the editor:

- There are 2 groups of rooms with only 1 room changing, one on the left and one on the right. Left one is group 1, right one is group 2.
- In each of the zones, there is a puzzle that changes them. In this case it's a switch, it can be a key or even an object such as a movable block.
- Before exiting the zones, there is a "do_activate" trigger with action "alternate_flag()". This saves the state of each zone when stepping/jumping through that sector.
- When exiting the zone, there is a "do_activate" trigger with action "alternate_off()". This deactivates all alternates when stepping/jumping through that sector.

So to recap, you store the state of each zone before leaving, and then later you restore the state with the flag trigger.
If there is more than 1 exit from a zone, you will need the alternate_flag and alternate_off placed on each of the exits.

I hope you understood all of that, i'm a bit crap at explaining things.
Here's a link to the level on that picture, with a .tre project file you can open in Dxtre inside the download: Alternate_flag demo level

And now how to use the Dragon boss in a TR2 level!

- You need to select "Xian.tr2" as your base level. I suppose the short cutscene in which Lara recovers the Dagger from the dragon's body is hardcoded to be only in that level ( makes sense ).
- In the room you want the boss battle in, you place the item "Bartoli" on the ground.
- You place a "do_activate" trigger for the Bartoli item when you enter the boss room. It will not activate the boss inmediately, but when you get close to it, it will appear automatically with the sparks and then expanding bubble effect.
- To open a door after the dragon dies, you have to create an "item_at_sector" trigger, with the door as the action. Then place it all over the floor where the dragon moves around, so no matter where it dies, killing it will open the door.
- Optionally, you can also use the earthquake effect when it dies. Just place the "earthquake" item on the boss room, then include it in the "item_at_sector" trigger from earlier.

That's it! It really is as simple as that.
Working on Tomb Raider II: The Ancient Jade Mask
Danath is offline  
Closed Thread

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

All times are GMT. The time now is 22:44.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2020, vBulletin Solutions Inc.