Thread: Kicking script
View Single Post
  #1  
Old 11-23-2006, 05:08 PM
xAndrewx xAndrewx is offline
Registered User
xAndrewx's Avatar
Join Date: Sep 2004
Posts: 5,260
xAndrewx has much to be proud ofxAndrewx has much to be proud ofxAndrewx has much to be proud ofxAndrewx has much to be proud ofxAndrewx has much to be proud ofxAndrewx has much to be proud ofxAndrewx has much to be proud of
Kicking script

Add the /* */ part's in to a level and name the class 'level_objectkick'.

HTML Code:
/*
function onCreated()
{
  this.levelGuild = "Andrew's Guild";
  this.kickLevel = {"levelname.nw", kickingx, kickingy};
  this.join("level_objectkick");
}
*/
function onPlayerChats()
{
  if(player.guild != this.levelGuild)
  {
    return false;
  }
  if(player.chat.substring(0, 5) == ":kick")
  {
    temp.currentPlayer = findPlayer(player.chat.substring(5).trim());
    if (temp.currentPlayer == "")
    {
      return false;
    }
    if (temp.currentPlayer.level.name != player.level.name)
    {
      return false;
    }
    temp.currentPlayer.setlevel2(this.kickLevel[0], this.kickLevel[1], this.kickLevel[2]);
  }
}
__________________
Reply With Quote