Add:
if(Weight >= MaxWeight/2) goto Low;
Low:
mes "You are Overweight!";
close;
why when i put this script it will keep telling You are Overweight!
if(Weight >= MaxWeight/2) goto Low;
and
Low:
mes "You are Overweight!";
close;
but when this script only everything works fine the npc will closed automatic but i want to add message when the player is overweight the npc will tell.
if(Weight >= MaxWeight/2)
Where did you put it? Can you post your script?
prontera,141,226,6 script Lotti Girl 714,{
mes "[Lotti Girl]";
mes "Hello Sir! Are you out";
mes "shopping in the city?!";
next;
mes "[Lotti Girl]";
mes "I'm Lotti! I'll exchange cool";
mes "random prizes for every";
mes "^ff00001 Premium Ticket^000000.";
next;
mes "[Lotti Girl]";
mes "Our Grand prize is:";
mes "^ff0000Combat Knife^000000";
mes "Special prizes are:";
mes "^ff0000+7 Armor Refine Deed^000000";
mes "^ff0000+10 Weapon Refine Deed^000000";
mes "and ^ff0000+6 Armor Refine Deed^000000";
next;
mes "[Lotti Girl]";
mes "You can still get random item";
mes "if you failed to get the grand";
mes "prize and special prizes.";
if (countitem(7608) < 1) close;
next;
if(Weight >= MaxWeight/2) goto Low;
Low:
mes "You are Overweight!";
close;
next;
if(select("Deal me in!:No way...")==2)
close;
mes "[Lotti Girl]";
mes "Here we go...";
delitem 7608,1;
set .@Total,2;//<%>,<ItemID>,<Amount>
setarray .@P1[0],10,6233,1;
setarray .@P2[0],20,1228,1;
setarray .@P3[0],90,2423,1;
setarray .@Default[0], 14232,5;
set .@i, rand(1,.@Total);
if (rand(1,100) > getd(".@P"+.@i+"[0]")) {
for(set .@j,0; .@j<getarraysize(.@Default);
set .@j,.@j+2) {
getitem .@Default[.@j], .@Default[.@j+1];
if(!.@k[0])
setarray .@k[0], .@Default[.@j], .@Default[.@j+1]; }}
else{
for(set .@j,1; .@j<getarraysize(getd(".@P"+.@i)); set .@j,.@j+2) {
getitem getd(".@P"+.@i+"["+.@j+"]"), getd(".@P"+.@i+"["+(.@j+1)+"]");
if (!.@k[0]) {
set .@gz,.@i;
setarray .@k[0], getd(".@P"+.@i+"["+.@j+"]"), getd(".@P"+.@i+"["+(.@j+1)+"]");
break; } } }
if(1<=.@gz&&.@gz<=4)
announce "Congratulations! "+strcharinfo(0)+" just received "+getitemname(.@k[0])+" x "+.@k[1]+" from Lotti Girl (prontera 139 173)!",0; specialeffect2 248;
close;}