OnFilterScriptExit - RemoveAllCars - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: OnFilterScriptExit - RemoveAllCars (
/showthread.php?tid=155844)
OnFilterScriptExit - RemoveAllCars -
Omnitrix - 19.06.2010
Ok basically. our server we have decided to have all cars on FS. But we cannot decide a way to make the cars remove when the filterscript goes.
First Option : Each Car Has A "new" Variable , Which Add's A Lot Of Lines Of Script And Is Very Annoying using DestroyCar
Second Option : Something With Virtual Worlds ..., VW1 Cars VW2 Carless..
how have you guys done it?
Re: OnFilterScriptExit - RemoveAllCars -
Carlton - 19.06.2010
pawn Код:
public OnFilterScriptExit() {
for(new i = 0; i < MAX_VEHICLES; i ++ ) {
DestroyVehicle(i);
}
}
Re: OnFilterScriptExit - RemoveAllCars -
Omnitrix - 20.06.2010
Many Thanks Ill Try This Now ..
Re: OnFilterScriptExit - RemoveAllCars -
Sergei - 20.06.2010
First vehicle ID is 1, so start loop with 1
pawn Код:
public OnFilterScriptExit() {
for(new i = 1; i < MAX_VEHICLES; i ++ ) {
DestroyVehicle(i);
}
}
Re: OnFilterScriptExit - RemoveAllCars -
Omnitrix - 20.06.2010
Love You Man <3
Re: OnFilterScriptExit - RemoveAllCars -
GaGlets(R) - 21.06.2010
Quote:
Originally Posted by $ЂЯĢ
First vehicle ID is 1, so start loop with 1
pawn Код:
public OnFilterScriptExit() { for(new i = 1; i < MAX_VEHICLES; i ++ ) { DestroyVehicle(i); } }
|
Hey, by the that way.
you are makeing it for vehicle id 2 +++
but id 1 will stay
Thinking logical
Код:
if(GeTPlayerMoney(asdads) > 51)
explenation - i cant buy if i have $51
soo
Код:
for i = 1; 1 < ASDASASD)
the same - destroying car with id 2 and higher..
soooo...
id 1 will stay..
if im wrong then say it to me.