** assume that this npc script works **
once i get to the third status, i feel as if the npc forgets what the selection was, thus giving me an error. am i supposed to add a variable somewhere or is there another way to do this?
** and once again, i just typed up part of it real quick, i already know that it works up until the third status which is where i'm supposed to receive my item
thxxxxxx.
PHP:
if (status == 0) {
cm.sendGetNumber("type in the id of an item you want");
cm.dispose();
} else if (status == 1) {
if (selection != blocked) {
cm.sendNext("are you sure you want #v" + selection + "# as your new item?");
} else {
cm.sendOk("this item is blocked.");
cm.dispose();
}
} else if (status == 3) {
cm.gainItem(selection, 1);
cm.dispose();
}
once i get to the third status, i feel as if the npc forgets what the selection was, thus giving me an error. am i supposed to add a variable somewhere or is there another way to do this?
** and once again, i just typed up part of it real quick, i already know that it works up until the third status which is where i'm supposed to receive my item
thxxxxxx.