I cant seem to get this script to work. As a level NPC it wont work, but when i use it as a WNPC, it will. (though i need it as a level npc)
When I use it as a level NPC, it cant seem to get through to the serverside action. What am i doing wrong?
PHP Code:
function onActionServerSide(cmd){
if(temp.cmd == "arrive"){
setlevel2(client.destination[0],client.destination[1],client.destination[2]);
}
}
//#CLIENTSIDE
function onCreated(){
setcoloreffect 1,1,1,0.01;
setimgpart block.png,0,0,32,16;
}
function onPlayerchats(){
if(player.chat = "Testdestination"){
client.destination = {"overworld_bw061.nw",15.5,15};
}
setTimer(3);
}
function onTimeout(){
triggerserver("npc",this.name,"arrive");
}