destroy objects with the same id ?
#3

What you can do is create your own CreateObjectEx to detect the model ids.
pawn Код:
new ModelID[MAX_OBJECTS];//top of script
new ObjectID=0;//top of script

stock CreateObjectEx(modelid,Float:x,Float:y,Float:z,Float:rx,Float:ry,Float:rz)
{
        ObjectID++;
    CreateObject(modelid,x,y,z,rx,ry,rz);
        ModelID[ObjectID]=modelid;
}

//place this where you want it
for(new i; i<MAX_OBJECTS; i++)
{
    if(IsValidObject(i) && ModelID[i]==1225)
    DestroyDynamicObject(i);
}
I didnt tested the code so tell me if you have issues.
Reply


Messages In This Thread
destroy objects with the same id ? - by omidi - 07.08.2013, 21:37
Re: destroy objects with the same id ? - by Macluawn - 07.08.2013, 21:40
Re: destroy objects with the same id ? - by Admigo - 07.08.2013, 22:22

Forum Jump:


Users browsing this thread: 1 Guest(s)