Im making a simple add-on that will allow me to add a clan suffix to a name. It makes sure you are admin,targeted a player and have a clan suffix.
I dont know exactly what im doing wrong but I hope someone can help.
function servercmdtag(%client, %name, %tag)
{
%target = findClientByName(%name);
if(!%client.isAdmin){
messageClient(%client,"\c0 You must be an admin to use this function!");
return;
}
if(!%target)
{
messageClient(%client,"","\c0Player was not found!");
return;
}
if(!%tag)
{ messageClient(%client,"","\c0You did not include a tag!");
return;
}
else
{
findClientByName(%target).clansuffix = %tag;
return;
}
}