Jump to content

Question

Posted

Hello, can someone please tell me what's wrong with this script of mine :

 

-	script	weaponmastcmdc	-1,{
OnInit:
	bindatcmd "train",strnpcinfo(3)+"::OnTrainweap";
	end;

OnTrainweap:
if (countitem(30722) > 1) goto LNope;
dispbottom "[ Weapon Training Guard ]";
dispbottom "Sorry, but you need a TRAINING PASS to enter the training room.";
dispbottom "You can purchase it from the TCG exchanger NPC.";
	end;


LNope:
warp "pvp_y_1-1",0,0;
dispbottom "[ Weapon Training Guard ]";
dispbottom "Welcome back.";
end;

}

This script is supposed to warp the char who typed @train to a map if they have a weapon training pass (30722) in their inventory.
Everytime i type @train even with the training pass in myinventory it wont warp me to the map.

Anything I did wrong ? 

2 answers to this question

Recommended Posts

Posted


- script weaponmastcmdc -1,{

OnInit:

bindatcmd "train",strnpcinfo(0)+"::OnTrainweap";

end;

OnTrainweap:

if (countitem(30722) < 1) {

dispbottom "Sorry, but you need a TRAINING PASS to enter the training room.";

dispbottom "You can purchase it from the TCG exchanger NPC.";

end;

}

warp "pvp_y_1-1",0,0;

dispbottom "[ Weapon Training Guard ]";

dispbottom "Welcome back.";

end;

}

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...