Actually the this.id part is completely invalid, unless you define this as an instance variable before that code runs. To reference the instance outside the with statement we use other(in this example, other will be the player).Īnd for the code in the enemy object, you don't have to use instance_find at all. In my player object: if (sprite_index = spr_player_attack_left) ". I need to be able to destroy a specific instance of my enemy object without using the collision event. I've just started using gamemaker studio 2 and I've been scratching my head over this one for a while. If the object's sprite has reached the end of its animation - evanimationupdate: Animation event that runs every step for objects that use skeletal animations - evanimationevent: Animation event that runs for skeletal animations as assigned in the skeletal animation tool - evendofpath: If the object has reached the end of a path.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |