View Single Post
  #6  
Old 05-06-2011, 10:11 PM
cbk1994 cbk1994 is offline
the fake one
cbk1994's Avatar
Join Date: Mar 2003
Location: San Francisco
Posts: 10,718
cbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond repute
Send a message via AIM to cbk1994
Quote:
Originally Posted by Astram View Post
Sorry, Im new to scripting. Can you give me an example?
PHP Code:
function onActionServerSide(temp.cmd) {
  if (
temp.cmd == "createHouse") {
    if (
player.clientr.phouse2 == null) {
      
copyLevel("toad-level1.nw""world/phouse/house_" player.account ".nw");
      
// no "levels/" in the path
    
}
  }
}

//#CLIENTSIDE
function onPlayerChats() {
  if (
player.chat == "create house") {
    
triggerServer("gui"this.name"createHouse");
  }

and then give the NPC-server the rights

Quote:
rw levels/world/phouse/house_*.nw
Haven't tested but it should work.
__________________
Reply With Quote