Author Topic: Script_PlayerPersistence?  (Read 1382 times)

What is this add-on? I found it in the add-on list but I don't know what it is.

Quote from: description.txt
Saves player and client object data when user disconnects from server, restores it when they rejoin.

For example, you find 3/5 Treasure Chests in the server. You leave, rejoin, the server will have saved the data of you finding three chests. So when you find another, you will have found 4/5.

It's like the automatic save/load feature for an online server.

> disconnect

> reconnect


> respawn where disconnected

and it save also the size, playertype, weapons etc

> disconnect

> reconnect


> respawn where disconnected

and it save also the size, playertype, weapons etc
that
more clearly, you spawn wherever you last were when you disconnected prior to that connect
you also regain your inventory and playertype

Does it also save your score?

Script_Player_Persistence

A simple player saving mod.  When a player disconnects, it saves their position, datablock, health and items, then restores that information when the player reconnects.  The treasure chest and checkpoint bricks will use this system (if enabled) to save and restore the client's current checkpoint brick and which chests they have found.  

Does it also save your score?
Probably not so that it prevents cheating to have a high score

I want a version of this that also saves variables and score. That'd be nice

Oh wow, that sounds awesome. Wish I actually kept up on this stuff. :P

Oh wow, that sounds awesome. Wish I actually kept up on this stuff. :P

It's default, so it should be put back if you deleted it on startup.

I'm curious if he might add RTB Hooks so people might use RTB to control what information saves...

Does it also save your score?
Not by default but it is very easy to add it

I want a version of this that also saves variables and score. That'd be nice
>Variables
Far too broad to help you
>Score
RegisterPersistenceVar("score", false, "");

Not by default but it is very easy to add it
>Variables
Far too broad to help you
>Score
RegisterPersistenceVar("score", false, "");
oh ok that's cool. But by variables I mean vce variables. Not coding variables, lol

So do I just add that line of code right into the script? my knowledge of scripting might as well= nada. So I'd like instructions as if you were telling this to a 6 year old.  :cookieMonster: Please and ty
« Last Edit: December 30, 2011, 01:45:50 PM by Mysteroo »

oh ok that's cool. But by variables I mean vce variables. Not coding variables, lol

So do I just add that line of code right into the script? my knowledge of scripting might as well= nada. So I'd like instructions as if you were telling this to a 6 year old.  :cookieMonster: Please and ty
VCE variables I don't believe could be saved through persistence, because persistence only saves fields of the player and client, while VCE variables are saved in a seperate object (client.brickgroup.vargroup)

As for score, never mind, it is saved by default.


oh ok that's cool. But by variables I mean vce variables. Not coding variables, lol

So do I just add that line of code right into the script? my knowledge of scripting might as well= nada. So I'd like instructions as if you were telling this to a 6 year old.  :cookieMonster: Please and ty
VCE has it's own saving system you can use. There's no need to make it anything other than perhaps automate it within the addon itself.