vargv

Started by KAKAN, Oct 06, 2015, 10:39 AM

Previous topic - Next topic

KAKAN

So, the topic says all again!
I need a brief description about the function 'vargv', I have seen it in many functions, one good ex is Sunshine Autos made by @rulk.

Ps:- sorry is something is wrong. Currently I'm at phone
oh no

EK.IceFlake

Well look at this example
function VariableParametersFunction(...)
{
    for (local i = 0; i <= vargv.len() - 1; ++i) print(vargv[i]);
}
Passing 128, "hey guys", 8881.995 will result in
[SCRIPT] 128
[SCRIPT] hey guys
[SCRIPT] 8881.995
Its basically an array if you define a parameter as ...

.

#2
If you look at my signature you'll find a ridiculous amount of links to Squirrel documentation/tutorials etc. And all of these are documented there. We're here to deal with the VC:MP scripting and not copy the Squirrel documentation over to the forum because some of us are too lazy to open a link and simply search for something.

.

KAKAN

Okay, Thanks @NE.CrystalBlue
I'll surely go through that, @S.L.C
Topic Locked
oh no