Expand description
Commands that cost or refund money after a build: elevator cars
(Simulation::add_car, Simulation::remove_car), stretching a shaft
(Simulation::extend_transport) and removing a room or a shaft
(Simulation::remove_facility).
Each one checks, changes the tower and moves the money in one step and reports the amount, so a frontend sends the command and never writes money itself.
Structs§
- Charge
Result - What a charged command did.
- Extend
Result - What an extension did: the charge, and the shaft’s span afterwards.
Enums§
- Extend
End - Which end of a shaft an extension moves.
Constants§
- ADD_
CAR_ COST - The price of one more elevator car.
- INVALID_
REQUEST - The refusal for a malformed command, such as a brush with too many tiles. The JavaScript binding also gives it for an id or floor that is not a whole number, or an unknown name; a Rust host passes typed values and never sees those cases.
- TRANSPORT_
FLOOR_ COST - The price of each floor an elevator is built or extended past its first.