01.12.2018, 22:29
Thank you very much for your answer.
I did it successfully.It works as I wanted..
I just have question about destroy object,is there any better way to destroy all playerobject then for loop through the whole objects.(I have many objects,so it's very big loop with many checks). (~30,000 objects...)
My code
If not.It's okay,it works.
Sorry for my English..
I did it successfully.It works as I wanted..
I just have question about destroy object,is there any better way to destroy all playerobject then for loop through the whole objects.(I have many objects,so it's very big loop with many checks). (~30,000 objects...)
My code
Код:
DestroySnowObject(playerid) { new data; for(new i; i < Streamer_GetUpperBound(STREAMER_TYPE_OBJECT); ++i) //for loop for all objects { if(!IsValidDynamicObject(i)) continue; Streamer_GetArrayData(STREAMER_TYPE_OBJECT, i, E_STREAMER_PLAYER_ID, data); if(data == playerid) { DestroyDynamicObject(i); } } return 0; }
Sorry for my English..