Thread: 2 Questions...
View Single Post
  #7  
Old 08-06-2010, 09:48 PM
xMane xMane is offline
NPC-Server (Server)
xMane's Avatar
Join Date: May 2010
Posts: 59
xMane is on a distinguished road
Quote:
Originally Posted by fowlplay4 View Post
You need to tell the server to warp the player, which is done easily with triggeraction. Since this is just a level npc, you can do it like this:

PHP Code:
function onCreated() {
  
// Gives NPC shape to be 'hit' with triggeractions on the server-side.
  
setshape(13232);
}

function 
onActionWarpPlayer() {
  
player.setlevel2("onlinestartlocal.nw"3030);
}

//#CLIENTSIDE

function onPlayerTouchsMe() {
  
triggeraction(this.1this.y, + 1"WarpPlayer""");

Your duplicate code can also be redone with a for loop.
Do you know how much i love you? <3 Thanks. EDIT : NVM! EDIT x2: NVM TAT NVM I LOVE U!
PHP Code:
function onActionWarpPlayer() {
  
player.setlevel2("express_boat-storm2.nw",36.5,18);
}
//#CLIENTSIDE
function onCreated()
  {
  
setshape(1,32,32);
}
function 
onPlayerTouchsMe()
  {
  if(
client.quest1=4)
    {
    
triggeraction(this.1this.y, + 1"WarpPlayer""");
    
setani("sleep",NULL);
    
client.quest1=5;
  }

it still no work! but setting client.quest1 works perfectly...

Last edited by xMane; 08-06-2010 at 09:59 PM.. Reason: no love for no working script >:( EDIT x2 lololol u dont have to add +1 to each coord in the triggeraction...
Reply With Quote