Reformat and clean up npc scripts

This commit is contained in:
P0nk
2021-09-09 23:35:02 +02:00
parent 0c1545f81d
commit d893309b4f
665 changed files with 19932 additions and 19046 deletions

View File

@@ -32,31 +32,33 @@ function start() {
function action(mode, type, selection) {
status++;
if (mode != 1){
if(mode == 0 && type != 1)
if (mode != 1) {
if (mode == 0 && type != 1) {
status -= 2;
else if(type == 1 || (mode == -1 && type != 1)){
if(mode == 0)
} else if (type == 1 || (mode == -1 && type != 1)) {
if (mode == 0) {
cm.sendOk("Hmm... I guess you still have things to do here?");
}
cm.dispose();
return;
}
}
if (status == 1) {
if (cm.haveItem(4031801))
if (cm.haveItem(4031801)) {
cm.sendNext("Okay, now give me 150 mesos... Hey, what's that? Is that the recommendation letter from Lucas, the chief of Amherst? Hey, you should have told me you had this. I, Shanks, recognize greatness when I see one, and since you have been recommended by Lucas, I see that you have a great, great potential as an adventurer. No way would I charge you for this trip!");
else
} else {
cm.sendNext("Bored of this place? Here... Give me #e150 mesos#n first...");
}
} else if (status == 2) {
if (cm.haveItem(4031801))
if (cm.haveItem(4031801)) {
cm.sendNextPrev("Since you have the recommendation letter, I won't charge you for this. Alright, buckle up, because we're going to head to Victoria Island right now, and it might get a bit turbulent!!");
else
if (cm.getLevel() > 6) {
} else if (cm.getLevel() > 6) {
if (cm.getMeso() < 150) {
cm.sendOk("What? You're telling me you wanted to go without any money? You're one weirdo...");
cm.dispose();
} else
} else {
cm.sendNext("Awesome! #e150#n mesos accepted! Alright, off to Victoria Island!");
}
} else {
cm.sendOk("Let's see... I don't think you are strong enough. You'll have to be at least Level 7 to go to Victoria Island.");
cm.dispose();