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

@@ -1,15 +1,15 @@
var status = -1;
var sel;
var destinations = new Array("Ellinia", "Ludibrium", "Leafre", "Mu Lung", "Ariant", "Ereve");
var boatType = new Array("the ship", "the train", "the bird", "Hak", "Genie", "the ship");
var destinations = ["Ellinia", "Ludibrium", "Leafre", "Mu Lung", "Ariant", "Ereve"];
var boatType = ["the ship", "the train", "the bird", "Hak", "Genie", "the ship"];
function start() {
var message = "Orbis Station has lots of platforms available to choose from. You need to choose the one that'll take you to the destination of your choice. Which platform will you take?\r\n";
for(var i = 0; i < destinations.length; i++){
message += "\r\n#L" + i + "##bThe platform to " + boatType[i] + " that heads to " + destinations[i] + ".#l";
}
cm.sendSimple(message);
var message = "Orbis Station has lots of platforms available to choose from. You need to choose the one that'll take you to the destination of your choice. Which platform will you take?\r\n";
for (var i = 0; i < destinations.length; i++) {
message += "\r\n#L" + i + "##bThe platform to " + boatType[i] + " that heads to " + destinations[i] + ".#l";
}
cm.sendSimple(message);
}
function action(mode, type, selection) {
@@ -18,10 +18,10 @@ function action(mode, type, selection) {
return;
}
status++;
if (status == 0){
if (status == 0) {
sel = selection;
cm.sendNext("Ok #h #, I will send you to the platform for #b#m" + (200000110 + (sel * 10)) + "##k.");
}else if (status == 1) {
} else if (status == 1) {
cm.warp(200000110 + (sel * 10), "west00");
cm.dispose();
}