To begin, create a basic chest (as detailed in Part 1), we'll need to set up the randomized traps, then 4 additional Conditional Branches with the different traps triggered, including one where you avoid the trap.
The following routine is placed after the third Wait Command and before the rewards (called with the "Random Contents" Call Event we defined in Part 3).
<>Variable Oper: [0001:Randomizer] Set, Rnd [1-4] <>Branch if Var [0001:Randomizer] is 1 <>Show Battle Animation: Fire Breath, Hero (Wait) <>Message: You triggered a fire trap. <>Change HP: Entire Party's HP 10 Remove <> : End <>Branch if Var [0001:Randomizer] is 2 <>Show Battle Animation: Ice Breath, Hero (Wait) <>Message: You triggered an ice trap. <>Change HP: Entire Party's HP 10 Remove <> : End <>Branch if Var [0001:Randomizer] is 3 <>Show Battle Animation: Poison Breath, Hero (Wait) <>Message: You triggered a poison trap. : You've been poisoned! <>Change Cond: Entire Party Poison Inflict <> : End <>Branch if Var [0001:Randomizer] is 4 <>Message: You avoided the trap. <> : End
With that in place, the chest will open normally and you'll receive the goodies from within the chest after the trap has been triggered.
2 Comments So Far:
Your tutorials here are quite handy. Thanks for writing them.
You're welcome. So glad you can benefit from them. If you have any suggestions for further expansions on this tutorial, feel free to comment them. Thanks for visiting.
Post a Comment