Each enemy type’s unique functions are carried out via a state machine that runs in the generic object’s step event. The spawning manager object passes a behavior variable to each enemy instance it creates based on their respective type.
While most enemies default to a basic walking behavior, certain types like the Climber progress through several states before transitioning to standard movement behavior (as shown here).
Others, like the Juker, temporarily transition out of standard movement behavior based on certain triggers – in this case, coming into contact with a dodge-able trap. Specific variables such as movement speed are randomized in the spawn manager to add further variety to each enemy.