Here's a proper example, haven't tested but it's adequate..
Not in a callback (global):
pawn Код:
new objects[50]; // Change 50 to suit your number of objects
OnGameModeInit/OnFilterScriptInit
pawn Код:
objects[0] = CreateObject(blah blah poo);
objects[1] = CreateObject(blah blah poo);
...
objects[49] = CreateObject(blah blah poo); //Change 49 to one less than your total objects
OnGameModeExit/OnFilterScriptExit
pawn Код:
for(new a=0; a<50; a++)
{
DestroyObject(objects[a]);
}