Skip to content

Aidan Stupid Simple Solution Solves 1..7

Metafor edited this page Oct 25, 2024 · 2 revisions

Stupid Simple Solution

This does nothing more than go to ground on idle and then go to the next button pressed on the elevator.

Solves 1-7, some after many attempts.

{ init: function(elevators, floors) { elevators.forEach(function (elevator, index) { elevator.on("idle", function() { elevator.goToFloor(0); }); elevator.on("floor_button_pressed", function(floorNum) { elevator.goToFloor(floorNum); } ); }); }, update: function(dt, elevators, floors) { } }

Clone this wiki locally