18.07.2011, 18:37
I use to use this:
Then, when creating the particle object:
Where "time" is the estimated time the particle effect runs.
You could also combine this in a CreateTimedObject function that automatically creates and removes the object after a given time.
pawn Код:
forward DestroyObjectPub(objectid);
public DestroyObjectPub(objectid)
{
DestroyObject(objectid);
}
pawn Код:
SetTimerEx("DestroyObjectPub", time, 0, "i"; objectid_of_the_particle_object);
You could also combine this in a CreateTimedObject function that automatically creates and removes the object after a given time.