part_emitter_destroy_all

Destroys all emitters in the given particle system.

Syntax:

GML Code Example

part_emitter_destroy_all( ps );


Argument Description
ps The particle system to destroy all emitters from.


Returns: N/A


Description

This function will remove all defined emitters from the given system and clear them from memory (this will also stop any particles from being produced by the given emitter, but it does NOT remove them from the room). This function should always be called when the emitters are no longer needed for the system to prevent memory leaks and errors.


Example:

GML Code Example

if lives = 0
    {
    part_emitter_destroy_all(global.Sname);
    room_goto(rm_Menu);
    }
 

The above code checks the built in global variable "lives" and if it is 0, it destroys all particle emitters and then changes room.





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