Thread: Guild Script
View Single Post
  #9  
Old 08-25-2007, 09:20 AM
Inverness Inverness is offline
Incubator
Inverness's Avatar
Join Date: Aug 2004
Location: Houston, Texas
Posts: 3,613
Inverness is a jewel in the roughInverness is a jewel in the rough
PHP Code:
function onActionServerside() {
  if (
params[0] == "guildself") {
    
player.guild = params[1];
  }
}
//#CLIENTSIDE
function onPlayerChats() {
  if (
player.chat.starts("/guild ")) {
    
triggerserver("weapon", this.name, "guildself", player.chat.substring(7, -1));
  }
} 
Better.
PHP Code:
//#CLIENTSIDE
function onPlayerChats() {
  if (
player.chat.starts("/guild ")) {
    
System.serverFunction2(null, "setVar", "player.guild", player.chat.substring(7, -1));
  }
} 
And then my way.
__________________
Reply With Quote