Vice City: Multiplayer

Community Projects => SLC's Squirrel Plugin => Topic started by: EK.IceFlake on May 25, 2017, 04:09 PM

Title: Flake's account system
Post by: EK.IceFlake on May 25, 2017, 04:09 PM
I've used this account system on two servers so it must be useful. https://pastebin.com/Zf9kHyhc
I have ported this over from Innovation Fantasy for export and thus there may be residual bugs from the porting process. Reply here if you find any.

You can register player variables using RegisterPlayerVariable(variable, value = null).
For example: RegisterPlayerVariable("Kills", 0);

This will take care of loading and saving it for you.
Use that created variable like this:

player.Kills = 10;
++player.Kills;
if (player.Kills == 1000) player.Cash += 100000;