Game Development Reference
In-Depth Information
Don't forget to erase the regions at your intended destination. The reason for this will become obvious when
we work on the parallel process event.
Note
As promised, the player's two possible routes to leave the floor are blocked by teleportation Regions. Region 61
leads to another part of the map, as covered in Figure 13-2 .
Creating the Puzzle Logic
We have defined where each particular Region leads within the floor, so let's work on the Parallel Process event now.
The first part of our Parallel Process will check the player's x and y coordinates and then use the Get Location Info
event command to get the Region ID from his/her current location. Whenever the player steps into a Region, he/she is
teleported to the appropriate destination. Once the player shatters the crystal powering the teleportation traps,
he/she can advance.
@>Control Variables: [0002:X] = Player's Map X
@>Control Variables: [0003:Y] = Player's Map Y
@>Get Location Info: [0028], Region ID, Variable [0002][0003]
@>Conditional Branch: Switch [0036:TeleportTrapOFF] == ON
@>Jump to Label: Skip
@>
: Branch End
@>Conditional Branch: Variable [0028:teleportspot] == 63
@>Transfer Player:[024:Devil's CastleF1F] (040,042)
@>
: Branch End
@>Conditional Branch: Variable [0028:teleportspot] == 62
@>Transfer Player:[024:Devil's CastleF1F] (011,033)
@>
: Branch End
@>Conditional Branch: Variable [0028:teleportspot] == 61
@>Transfer Player:[024:Devil's CastleF1F] (031,017)
@>
: Branch End
@>Conditional Branch: Variable [0028:teleportspot] == 60
@>Transfer Player:[024:Devil's CastleF1F] (023,042)
@>
: Branch End
@>Conditional Branch: Variable [0028:teleportspot] == 59
@>Transfer Player:[024:Devil's CastleF1F] (006,042)
@>
: Branch End
@>Label: Skip
Here you can see why you need to erase the Region squares I used to mark each destination (save for Region 61).
The event is set up so that the player will be moved if he/she steps upon a Region.
 
 
Search WWH ::




Custom Search