Welcome to Harder Than You Think, a series about things that seem fairly easy to an outsider but can rapidly spiral into extremely complicated or expensive behaviors. Today, we’ll be talking about elevators and how much of a rat’s nest they can be.
The first thing to note about elevators in video games is that many video game elevators are actually not actually elevators at all, but teleporters. When you walk up to the button and press it in game, it often gives you a list of floors you choose from. Upon choosing it, the screen fades to black, and then it fades back in with your character at the new floor. There may be a pause and some sound effect played, but there is no actual movement across space. The elevator is merely a facade for a teleportation button. I’ve heard these occasionally called Wonkavators because “ …elevators only go up. The Wonkavator goes up, down, sideways and every other which way you can think of going.” The teleporter allows designers to conveniently sidestep issues of making environments have to fit within a contiguous space, and instead magically join two discrete points, potentially within the same environment, just physically separated so that the teleporter is the only way between them.
One major reason for this is because non-teleporting elevators become an absolute nightmare in multi-user environments. Since there are potentially multiple people who could all try to use the elevator at the same time, we essentially have to construct an actual elevator with a queueing system where users at different floors request a pickup, and then users inside the elevator request floors to arrive. The elevator itself has to remember its movement direction, and all of the requested floors in each direction in order to decide which floor it needs to go to next. As a coding exercise, try writing an algorithm for common elevator behavior in a ten-floor building. It is no trivial task! One studio I know would use this as a programming test to see how well engineering candidates could parse the nuances of a complicated control scheme.
The vast majority of non-teleporting elevators in games are one of two types - they either only have two locations they can visit, or they will only cycle through their various destination heights over time without player input. This is because things start scaling out of hand if the elevator can reach multiple destinations from each source. In most cases, each elevator floor can (usually) reach every other elevator floor except the one it is currently on, which means you have a N(N-1) number of connections to set up. Two floors is only two connections, but connecting six floors requires 30 different combinations and ten floors will require 90. Moving elevators can also cause all sorts of weird physics problems because the character is no longer on solid ground. The elevator must move the characters smoothly, which has its own set of simulation and physics problems.
Finally… elevators are often not particularly engaging gameplay. In this situation, an elevator is the thing that moves players from point A to point B. The majority of the time players are not going to find anything interesting or compelling about interacting with an elevator. It’s often just a means of gating the player to keep them from reaching some other element of the game until a certain point, and these kinds of gates should probably not suck up a huge amount of your development resources when they could much more easily be spent on the content and systems actually meant to be engaging. It’s hard to make an actual elevator fun. Most of the things we can do to make elevators more engaging involves gameplay elements other than the elevator itself, which still requires a reasonably significant amount of complexity. This is why elevators tend to be extremely simple and basic in games.
[Join us on Discord] and/or [Support us on Patreon]
The FANTa Project is being rebooted. [What is the FANTa project?]
Got a burning question you want answered?
- Short questions: Ask a Game Dev on Twitter
- Long questions: Ask a Game Dev on Tumblr
- Frequent Questions: The FAQ