RyanC
Member
Hi everyone,
I'm having some trouble deactivating my floor objects and was wondering if anyone can help?
I deactivate the obj_floor before I deactivate the enemies but the enemies are still getting stuck in the floor.
I think it's because the enemies bounding boxes could be overlapping the activation region, but sometimes the floor beneath them is not.
This is what I have every 7 steps in an alarm.
I'm having some trouble deactivating my floor objects and was wondering if anyone can help?
I deactivate the obj_floor before I deactivate the enemies but the enemies are still getting stuck in the floor.
I think it's because the enemies bounding boxes could be overlapping the activation region, but sometimes the floor beneath them is not.
This is what I have every 7 steps in an alarm.
Code:
instance_deactivate_object(obj_PARENT_Collectable)
instance_deactivate_object(obj_PARENT_Enemy)
instance_deactivate_object(obj_level_scenery_PARENT)
instance_deactivate_object(obj_floor)
instance_activate_region(view_xview[0]-384,view_yview[0]-256,view_wview[0]+800,view_hview[0]+800,true)
alarm[11] = 7