Elevator Entities

From MechWarrior: Living Legends Wiki
Jump to: navigation, search

One of the common experiences of our civilization is the suspense awaiting an elevator to arrive. Havnig this accessible in the game, can't but bolster the immersion.

big fat warning: Elevators are susceptible to the BA grenade impact bug. use with caution!

Prerequisites

For an elevator to exist at all one needs to put two entities into the map and make them connected so they interact:

  1. Elevator entity
  2. Elevator switch entity

And still there is more to that, and quite some.

For an elevator to be any good in the game, one has to define it's geometry (the cgf file) a.k.a. 3d art. The game will then use it as the rigid body of the elevator.

The same applies to the switch, it can be assigned an 3d model, to represent the "elevator calling switch". Although the switch has to be connected by a named link, called up or down, the switch really acts as a toggle and can both call and dispatch the elevator.

For this to occur, and any elevator can have an arbitrary number of switches, every switch has to be connected to it's elevator, and the link is to be named up or down.

So, once the player (the BA in MW:LL) can interact with the elevator, we still can't have other vehicles use it. For them to activate the button, we need to use an entity called proximity area, that can be connected to the switch:

Once an object enters the proximity area, the area entity sends an "event" - this event we connect to the elevator switch.

Now, when an mech steps into an proximity area, an sound can be played, and the elevator begins moving.

Art

Make sure the elevator fits the required role in size and form. The general guidelines for art creation apply.

Elevator entity

When adding an elevator entity to an map, for it to be shown at all, we have to assign it an body (3d art) in form of an .cgf file.

If we don't add any switch to the elevator, but make it automatic instead, it will act upon threading on it, and will go back and forth between the initial and destination floor.

The floor height can be defined in meters, decimal numbers - even negative ones. Negative floor height is advantageous to have the elevator be default on the upper floor, while dispatched to the lower floors (a mine).

Besides the floor height and the initial and destination floor, Cryengine let us define the amount of floors as well, this way the elevator can be operated automatically within an range, but manually called, by an switch, outside (or within) that range.

The elevator axis can be defined to be either X, Y or Z, while the default one is Z.

The elevator motion can be controlled with with speed (m/sec), acceleration (m/sec^2), and stop time (meters before destination)

Elevator switch entity

Here we will show some troubleshooting and explain some options

Proximity area entity

Yes, we have conducted tests, and found the proximity areas do not break MW:LL. Here we will discuss the quirks and tips for optimal usage