Fields of Mistria — Vanilla GML Reference FoM v1.0.8

obj_hayden.gml

object_create(
    "obj_hayden",
    object_reserve("par_NPC"),
    {
        sprite_index: spr_npc_mask,
        step: function() {
            event_inherit(ObjectEvent.Step);

            //
            if MIST.is_running() && MIST.active_cutscene.id == "farm_introduction" {
                self.shadow_caster.animation = SHADOW_DICTIONARY.get(self.sprite_index);
            }
        },
    }
);