Tutorials by Bob Lawrence
World Editor Tutorial
Presentation of GEdit
6.1 Creating and animating an Elevator
You will now create an elevator in the second room. To do so, you have to scale up the second room.
First, zoom out in the Side View. Switch to Camera Mode,
hold down the right mouse button and move the mouse down in the Side View in order to see the entire world.
Switch to Select Mode,
select the second room brush, click on the Scale Brush button,
drag and drop the ceiling of the second room in the Side View as shown below:
Switch to Template Mode,
click on the Template Panel, click on the Create Box button,
set the Top and Bottom Sizes to 100, the Y Size to 8 and select Solid (not Cut Brush).
Move the elevator brush to the upper right corner of the second room in the Top View, and place it on the floor in the Side View and press the Enter key.
Switch back to Select Mode and select the elevator brush. Click on the Models Panel, on the Add Model button, and enter the name "platform1".
Click on the Lock Z button,
click on Animate and, in the Side View, move the elevator up to the 2/3 of the room.
Click on Stop Animating and enter the key time 2. Click on Animate, don't move the brush, click on Stop Animating and enter the key time 2.01 (help the engine to animate the elevator during its motion. See Chapter 5. Doors).
You want the elevator to stop in this position for 2 seconds. Click on Animate, don't move the brush, click Stop Animating and enter the key time 4. Same than above, click Animate, Stop Animating, enter 4.01.
Now, you will make the elevator going down fast. Click Animate, in the Side View move the elevator back to its original position on the floor, click Stop Animating and enter 5. Same thing again for helping the engine, click Animate, don't move the brush, click Stop Animating and enter 5.01. The Models Panel should look like this:
Our elevator will go up in 2 seconds, stay for 2 seconds and go down in 1 second.
Unlock the Z axis by clicking on the Lock Z button.
Switch to Template Mode and click on the Template Panel. Choose the entity MovingPlat in the Entity List,
click on the "light bulb" button, move the blue cross close to the elevator and press the Enter key.
Click on the Entity Dialog button,
in the Drop down menu, choose the MovingPlat1 entity.
Double-click on the parameter Model and choose the model "platform1". Close the Entity Dialog box.
Now compile and run. Notice that an actor have to step on the elevator brush to activate it.
Shot of the player on the elevator:
Shot of a Bot on the elevator:
6.2 Creating and animating a moving platform
To create a moving platform, it's basically the same procedure. The difference is that the platform will move horizontally.
This bring a problem. In GTest, while the platform moves horizontally, the actor placed on it will not follow its movement and just fall from the platform moving away. The solution is to make a thin solid brush around the platform to maintain the actor on it.
You can also modify GTest or code in your own application to detect if the actor is on a moving platform and move it simultaneously with the platform. But this is not part of this tutorial.