Page 2 of 2

Re: [Solved] [Persitent] Keeping player data across ALL serv

Posted: 18 Jun 2015, 07:51
by Dommy
Declaring a persistent variable for Page or LocalUser will save the value until title pack where its used is uninstalled or profile GBX file is deleted.

Don't use persistent to share statistics across servers directly in mode script, it will save value to server profile on its file system only. Use manialink instead - manialinks are executed on client side, which allows you to store persistent on user side.

Pro tip - in single player both server host and manialink user are using the same profile, so persistent values can be used instead netwrite/netread to share variable between solo mode script and manialink instantly.


Offtop:
@olivierde8: In your script I saw setting variable value with class:

Code: Select all

declare Boolean[Text] UserSettings = Boolean[Text];
Is it working? I wasn't able to check this ^^.

Re: [Solved] [Persitent] Keeping player data across ALL serv

Posted: 18 Jun 2015, 10:01
by Darkminus
I just use persistent variables for clients, declared in Manialink.

The goal of these variables is just to store final stats to get them when the player comes back or go to another server.

When the script is running, I use Net variables (which are copy of persistent) declared for player to read/write stats in Script.

Then I copy them to client's persistent variable to store it. It seems to work as expected ^^

:thx:

Re: [Solved] [Persitent] Keeping player data across ALL serv

Posted: 24 Jun 2015, 19:33
by oliverde8
domino54 wrote:Offtop:
@olivierde8: In your script I saw setting variable value with class:

Code: Select all

declare Boolean[Text] UserSettings = Boolean[Text];
Is it working? I wasn't able to check this ^^.
I am pretty sure it does :D that code has been running on servers for over a year now.