SA-MP Forums Archive
What does it means? - 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)
+--- Thread: What does it means? (/showthread.php?tid=359069)



What does it means? - Qur - 12.07.2012

Hey.. I would like to know what the ++ or -- means..

for example:

Код:
Gas[vehicle]++;

Gas[vehicle]--;
Thanks


Re: What does it means? - MP2 - 12.07.2012

Increases or decreases the variable by 1.

Same as

Gas[vehicleid] = Gas[vehicleid]-1;
Gas[vehicleid] = Gas[vehicleid]+1;


AW: What does it means? - Nero_3D - 12.07.2012

var++; or ++var; is a little bit faster than var += 1;