With a little help from DrakilorP2P I created just a script that I'm actually proud of (NOT A SCRIPTER).
Was curious if there was any other easier methods or ways you could handle it?
PHP Code:
function onActionServerSide()
{
if (params[0] == "printMyVariable") {
myNewVar.loadvars("levels/users/Imperialistic/other/imptest.txt");
temp.theVariable = base64decode(myNewVar.variable);
//echo("Loaded ---> " @ temp.theVariable);
findplayer("Imperialistic").sendPM(temp.theVariable);
}
if (params[0] == "saveMyVariable") {
myVar = new TStaticVar();
myVar.variable = params[1];
//myVar.secondvariable = "World";
myVar.variable = base64encode(myVar.variable);
myVar.saveVars("levels/users/Imperialistic/other/imptest.txt", 1);
}
}
//#CLIENTSIDE
function onPlayerChats(){
if (player.chat = ":load"){
triggerServer("gui", this.name, "printMyVariable");
}
if (player.chat.starts("/save")) {
temp.argument = player.chat.substring(5).trim();
temp.arguments = temp.argument.tokenize();
triggerServer("gui", this.name, "saveMyVariable", temp.argument);
}
}