Advertisement
Dannu

/forcespawn for Cavik

Oct 25th, 2015
113
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.70 KB | None | 0 0
  1. function serverCmdForceSpawn(%client, %entry)
  2. {
  3. if(%client.isAdmin)
  4. {
  5. %target = findClientByName(%entry);
  6. if(isObject(%target) && !isObject(%target.player))
  7. {
  8. %target.instantrespawn();
  9. messageClient(%client, 0, "\c6You respawned\c3" SPC %target.getPlayerName() @ "\c6.");
  10. }
  11. else
  12. {
  13. if(isObject(%target.player))
  14. {
  15. messageClient(%client, 0, "\c3" @ %target.getPlayerName() SPC "\c6appears to be spawned already.");
  16. }
  17. else if(!isObject(%target))
  18. {
  19. messageClient(%client, 0, "\c6Can't find any user with the name of\c3" SPC %entry @ "\c6.");
  20. }
  21. }
  22. }
  23. else
  24. {
  25. messageClient(%client, 0, "\c6You must be an admin or higher to use this command!");
  26. }
  27. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement