2176
Modification Help / Re: Check for host
« on: March 08, 2009, 04:58:28 PM »
SOLVED I LEFT OUT ONE !
This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.
function ServerCmdAFK(%client)
{
%client.player.setShapeName(%client.name SPC "[AFK]");
%client.player.setShapeNameColor("1 0 0");
messageClient(%client,'', "\c5You are now seen as \c3AFK");
messageAll('', "\c3" @ %client.name SPC "\c5has updated their status to: \c3AFK");
}
Now I don't know why yours doesn't work, did you package it wrong?
if(isFile("Add-Ons/System_ReturnToBlockland/server.cs"))
{
if(!$RTB::RTBR_ServerControl_Hook)
exec("Add-Ons/System_ReturnToBlockland/RTBR_ServerControl_Hook.cs");
RTB_registerPref("Kill Command","Server Commands","Kill::Users","list SuperAdmin 0 Admins 1 Host 2", "Kill Command","0", 0, 1);
}
else
{
$Kill::Users = "0";
}
package kill
{
function servercmdkill(%client, %user)
{
if($kill::Users == 0 && !%client.isSuperAdmin)
{
messageClient(%client, '', '\c6You must be a super admin to use this command.');
return;
}
if($kill::Users == 1 && !%client.isAdmin)
{
messageClient(%client, '', '\c6You must be an Admin to use this command.');
return;
}
if($Kill::User == 2 && !((isObject(localclientconnection) && %client.getID() == localclientconnection.getID()) == false) || %client.bl_id == getNumKeyID() == false)
{
messageClient(%client, '', '\c6You must be the Host to use this command.');
return;
Please tell me how to fix this so that when it is on Admins, both admins can use it, when it is on Super admins, Super Admins can use it, and when it is on Host, only the host can use it.
Yeah, that stuff's for the pros!
if(Kill::users == 3 && !%Client.isHost)
if(isFile("Add-Ons/System_ReturnToBlockland/server.cs"))
{
if(!$RTB::RTBR_ServerControl_Hook)
exec("Add-Ons/System_ReturnToBlockland/RTBR_ServerControl_Hook.cs");
RTB_registerPref("Kill Command","Server Commands","Kill::Users","list SuperAdmin Host Admins All", "Kill Command","SuperAdmin", 0, 1);
}
else
{
$Kill::Users = SuperAdmin;
}