New Problem; Even if they aren't admin, they don't lose their stats. There is nothing wrong with the clearing script, it's something with the admin part. I'm aiming for admins not to lose stats, but non-admins do. Heres the code I have:
// When the players gets killed
function GameConnection::onDeath(%client, %killerPlayer, %killer, %damageType, %damageLoc)
{
Parent::onDeath(%client, %killerPlayer, %killer, %damageType, %damageLoc);
if (%client.isAdmin)
{
// Message about Stats
messageClient('', "<color:ffffff>Your stats have been preserved because you are admin.");
%client.RPData.value["tools"] = "";
return;
}
// Lose tools and Clear Stats
if (isObject(%client) && %client.isInRP())
return;
%client.RPData.value["tools"] = "";
%client.RPData.clear();
}
There is no Syntax.