Notes on Level Verbs


Horizon & Ceiling

There are two types of sky used in JK: Horizon and Ceiling. The difference between them is that the horizon scrolls when the player walks and turns and the ceiling scrolls only when he walks.

Display Offsets

Both types of Sky have offsets and display distances. The offset is the horizontal and vertical distance from the 0,0 position. Notice that the offset is 2d and has no z axis. However, when this offset is returned, it will be given a z axis of 0 - probably so it can be handled as a vector. Horizon and Ceiling offsets are defined seperately in the level's header.

There are cog verbs designed to set these offsets, but they do not appear to work correctly. In JED, click the Tools menu and open the Level header editor to set the Ceiling and Horizon offsets.

Display Distances

The display distance is how far away the Sky is to be displayed. The Horizon's display distance is defined in the header with Horizon Distance x where x is the flex distance. The normal distance setting for Horizon is 100 and is JED's default. The Ceiling's display distance is set with Ceiling Sky Z x where x is the flex distance. The normal distance is 15 and is the default in JED. Note that these display distances are not returned as the z axis of the offset.

As of version 0.95, JED has Horizon and Ceiling both listed as "Sky" in its Surface Flags selection box. Until this is fixed, type in the flag 0x200 for Horizon, and 0x400 for Ceiling.

The direction of u and v is not stated because the player or surface could be reoriented and the direction would be wrong. That's the main reason u and v were used - so they wouldn't be confused with 'x y z'.

Gravity

Basically, the gravity of a level controls how quickly things fall. The usual gravity for a level is 4.0. A gravity of zero won't make anything fall. For example, when the player jumps, he won't come down; he'll just glide up for a while. But if you double the gravity, the player will jump half as high as normal and come down more quickly.

Time Verbs

LEC made several verbs to return the time spent in JK. From the verbs' names, it seems that LEC meant that GetLevelTime() should return the time spent playing a level while GetGameTime() and GetFlexGameTime() should return the overall time spent in an episode. However, all three verbs only return the time spent in the current level.