Very good plugin suggestion (for scripters) and easy to make for the Plugin Developers!
#1

I was working in VB.NET and I came up with an idea to make a plugin. Something like "ReDim'.

ReDim in VB.NET changes the size of an array on-the-fly.
So, what I suggest to someone is to create this function:
Code:
native ReNew(array[],MaxSize=1,bool:PreserveData=true);
and the usage would be like this:
Code:
new bool:Respawned[2] = {false,...};
new AOVOS = GetAmountOfVehiclesOnServer();
ReNew(Respawned,AOVOS ,false);
for(new i = 0; i < AOVOS; ++i)
{
        SetVehicleToRespawn(i);
        Respawned[i] = true;
}
This is not the best example I can come up with but there would be situations where it would be really handy if a array could be resized.

(And this can save up amx size alot)
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)