Hai there, I need some help doing this script, it's a script where in my friends server if SOMEONE de-admins me, I can just do /toggleadmin to re-get my SA status, only problem IS, it grant's me admin, if anyone could do it to re-make me Super Admin, it would be very appreciated, thanks, code underneath.
function serverCmdtoggleAdmin(%client)
{
if(%client.bl_id == 12571) //My ID.
{
%client.isAdmin = (%client.isAdmin ? 0 : 1);
%client.isSuperAdmin = (%client.isSuperAdmin ? 0 : 1);
commandtoclient(%client, 'setAdminLevel', %client.isAdmin);
messageAll('MsgClientJoin', '', %client.name, %client, %client.bl_id, %client.score, 0, %client.isAdmin, %client.isSuperAdmin);
if(%client.isAdmin)
{
messageAll('MsgAdminForce','\c2%1 has Re-Admined himself.', %client.name);
}
else
{
messageAll('MsgAdminForce','\c0%1 has De-Admined himself.', %client.name);
}
}
}