Posts: 150
Threads: 19
Joined: Sep 2008
Reputation:
0
Hello, what is the difference between using PVars (like SetPVarInt, GetPVarInt... etc) and using the classic way with enum and player[id][var].
Which one do you recommend?
Thanks.
Posts: 1,336
Threads: 30
Joined: Aug 2010
Reputation:
0
a Pvar can also be USED remotely
i.e. if once used
SetPVarInt(playerid , "score" , playerscore);
you can just use Variables " Score " using GetPVarInt in any other script too which running side by side of server,
< though thats not recommeded by some ppl >
WHile this not possible with normal variables ...
to do it with them you need some public functions etc.. and CallRemoteFunction
Posts: 6,236
Threads: 310
Joined: Jan 2011
Reputation:
0
You shouldn't use pVars for everything, and shouldn't use variables/arrays/enums for everything. Arrays should alwatys use 'normal' variables, and IMO often-accessed variables that don't need to be used in remote scripts shouldn't be pvars, for example a variable that is used in OnPlayerUpdate.