Labels

Friday 21 March 2014

Puzzle and Level Mechanics - Fire

Once the Ice section mechanics were finished I moved to to the mechanics of the fire level. Some of the mechanics have been shared between sections, such as the moving / falling platforms. The Fire section was designed with only one large puzzle as it was decided that to increase the difficulty, the level would be more focus around difficult platforming mechanics.

The first part of the Fire section is a vertical ascent up the inside of a volcano. As you scale the volcano there is lava that rises below you. This was a fairly simple mechanic to script as it uses pretty much the same script as the other moving platforms with a few adjustments. You can see it in action below:


In the section following the volcano there are a series of "floating" platforms that are to be used for the player to travel over the lava that they are floating on. These also use similar code to the previous moving platforms, however these platforms move along a path made with a series of waypoints:


The following code shows how the waypoint system has been implemented:


In the same area as the floating platforms there is another level hazard that comes in the form of falling volcanic boulders. There is a series of game objects suspended above the level that each fall at a random speed. Each time a boulder hits the player or another collider, they are destroyed and the boulders position is reset to its starting height but with a random position along the X axis so that no pattern is formed to increase the difficulty:


This code snippet shows how the rocks are repositioned and how their falling speed is set:


As the section that is to follow the fire section has no puzzles, the final puzzle in the fire section is much more complex than previous puzzles. The mechanic behind the puzzle is a series of 3 buttons that must be pressed in specific orders to open certain doors. Following the section with the 3 buttons the player is faced with a large door. To open the door a button or lever must be interacted with to open the door. Each time the button is pressed the door only opens a small amount and will continuously close. In order to make it through the player must keep pressing the button until the door is raised fully and then run to make it under the door before it closes.


This code shows how the ordering of the 3 buttons is managed. It proved to be quite difficult to script this as it had to be possible to press the buttons in the incorrect order and have them reset so that you had to start the order again.


No comments:

Post a Comment