Returns the active state of the instance.


GML Code Example


Returns: Boolean


This read-only variable returns whether or not the instance is currently "sleeping" (true) or not (false), A "sleeping" instance is one that is not actively engaged in any physical simulation. GameMaker: Studio will put objects to sleep to save simulation cycles when an instance is at rest and not in collision with another instance.


GML Code Example

if phy_sleeping

The above code checks to see if the object is being actively simulated or not and if it is not it is destroyed.

No Examples Submitted

Does this page need better examples? Be the first to Submit

No Edits Suggested

Is this page unclear or not descriptive enough? Suggest an edit to the page and with enough upvotes your changes will be made.

No Questions Have Been Ask

Do you have a question about this page? Ask it Here