Reformat and clean up portal scripts

This commit is contained in:
P0nk
2021-09-09 23:35:59 +02:00
parent d893309b4f
commit a78ca88a02
435 changed files with 2712 additions and 2287 deletions

View File

@@ -1,5 +1,5 @@
function enter(pi) {
pi.playPortalSound();
pi.warp(103040300,1);
pi.warp(103040300, 1);
return true;
}

View File

@@ -20,22 +20,23 @@
*/
/**
-- Odin JavaScript --------------------------------------------------------------------------------
-- Odin JavaScript --------------------------------------------------------------------------------
During The Ride To Ellinia
-- By ---------------------------------------------------------------------------------------------
-- By ---------------------------------------------------------------------------------------------
Information
-- Version Info -----------------------------------------------------------------------------------
-- Version Info -----------------------------------------------------------------------------------
1.4 - Code clean up [Information]
1.3 - Typo >.< [Information]
1.2 - Update to support lastest script [Information]
1.1 - The right statement to bring out the music [Information]
1.0 - First Version by Information
---------------------------------------------------------------------------------------------------
**/
---------------------------------------------------------------------------------------------------
**/
function enter(pi) {
pi.playPortalSound(); pi.warp(200090000, 4);
if(pi.getPlayer().getClient().getChannelServer().getEventSM().getEventManager("Boats").getProperty("haveBalrog").equals("true")) {
pi.playPortalSound();
pi.warp(200090000, 4);
if (pi.getPlayer().getClient().getChannelServer().getEventSM().getEventManager("Boats").getProperty("haveBalrog").equals("true")) {
pi.changeMusic("Bgm04/ArabPirate");
}
return true;

View File

@@ -20,22 +20,23 @@
*/
/**
-- Odin JavaScript --------------------------------------------------------------------------------
-- Odin JavaScript --------------------------------------------------------------------------------
During The Ride To Ellinia
-- By ---------------------------------------------------------------------------------------------
-- By ---------------------------------------------------------------------------------------------
Information
-- Version Info -----------------------------------------------------------------------------------
-- Version Info -----------------------------------------------------------------------------------
1.4 - Code clean up [Information]
1.3 - Typo >.< [Information]
1.2 - Update to support lastest script [Information]
1.1 - The right statement to bring out the music [Information]
1.0 - First Version by Information
---------------------------------------------------------------------------------------------------
**/
---------------------------------------------------------------------------------------------------
**/
function enter(pi) {
pi.playPortalSound(); pi.warp(200090000, 5);
if(pi.getPlayer().getClient().getChannelServer().getEventSM().getEventManager("Boats").getProperty("haveBalrog").equals("true")) {
pi.playPortalSound();
pi.warp(200090000, 5);
if (pi.getPlayer().getClient().getChannelServer().getEventSM().getEventManager("Boats").getProperty("haveBalrog").equals("true")) {
pi.changeMusic("Bgm04/ArabPirate");
}
return true;

View File

@@ -1,5 +1,5 @@
function enter(pi) {
pi.playPortalSound();
pi.warp( pi.getMapId() - 100);
pi.warp(pi.getMapId() - 100);
return true;
}

View File

@@ -1,4 +1,3 @@
/*
[CelticMS] Monster Carnival Reviving Field 1
*/

View File

@@ -1,4 +1,3 @@
/*
[CelticMS] Monster Carnival Reviving Field 1
*/

View File

@@ -1,4 +1,3 @@
/*
[CelticMS] Monster Carnival Reviving Field 1
*/

View File

@@ -1,4 +1,3 @@
/*
[CelticMS] Monster Carnival Reviving Field 1
*/

View File

@@ -1,4 +1,3 @@
/*
[CelticMS] Monster Carnival Reviving Field 1
*/

View File

@@ -1,4 +1,3 @@
/*
[CelticMS] Monster Carnival Reviving Field 1
*/

View File

@@ -1,4 +1,5 @@
function enter(pi) {
pi.playPortalSound(); pi.warp(674030100,"in00");
pi.playPortalSound();
pi.warp(674030100, "in00");
return true;
}

View File

@@ -30,7 +30,7 @@ function enter(pi) {
if (pi.getParty() != null) {
if (pi.isLeader()) {
for (var i = 0; i < dungeons; i++) {
if(pi.startDungeonInstance(dungeonid + i)) {
if (pi.startDungeonInstance(dungeonid + i)) {
pi.playPortalSound();
pi.warpParty(dungeonid + i, "out00");
return true;
@@ -42,7 +42,7 @@ function enter(pi) {
}
} else {
for (var i = 0; i < dungeons; i++) {
if(pi.startDungeonInstance(dungeonid + i)) {
if (pi.startDungeonInstance(dungeonid + i)) {
pi.playPortalSound();
pi.warp(dungeonid + i, "out00");
return true;

View File

@@ -32,7 +32,7 @@ function enter(pi) {
if (pi.getParty() != null) {
if (pi.isLeader()) {
for (var i = 0; i < dungeons; i++) {
if(pi.startDungeonInstance(dungeonid + i)) {
if (pi.startDungeonInstance(dungeonid + i)) {
pi.playPortalSound();
pi.warpParty(dungeonid + i, "out00");
return true;
@@ -44,7 +44,7 @@ function enter(pi) {
}
} else {
for (var i = 0; i < dungeons; i++) {
if(pi.startDungeonInstance(dungeonid + i)) {
if (pi.startDungeonInstance(dungeonid + i)) {
pi.playPortalSound();
pi.warp(dungeonid + i, "out00");
return true;

View File

@@ -32,7 +32,7 @@ function enter(pi) {
if (pi.getParty() != null) {
if (pi.isLeader()) {
for (var i = 0; i < dungeons; i++) {
if(pi.startDungeonInstance(dungeonid + i)) {
if (pi.startDungeonInstance(dungeonid + i)) {
pi.playPortalSound();
pi.warpParty(dungeonid + i, "out00");
return true;
@@ -44,7 +44,7 @@ function enter(pi) {
}
} else {
for (var i = 0; i < dungeons; i++) {
if(pi.startDungeonInstance(dungeonid + i)) {
if (pi.startDungeonInstance(dungeonid + i)) {
pi.playPortalSound();
pi.warp(dungeonid + i, "out00");
return true;

View File

@@ -32,7 +32,7 @@ function enter(pi) {
if (pi.getParty() != null) {
if (pi.isLeader()) {
for (var i = 0; i < dungeons; i++) {
if(pi.startDungeonInstance(dungeonid + i)) {
if (pi.startDungeonInstance(dungeonid + i)) {
pi.playPortalSound();
pi.warpParty(dungeonid + i, "out00");
return true;
@@ -44,7 +44,7 @@ function enter(pi) {
}
} else {
for (var i = 0; i < dungeons; i++) {
if(pi.startDungeonInstance(dungeonid + i)) {
if (pi.startDungeonInstance(dungeonid + i)) {
pi.playPortalSound();
pi.warp(dungeonid + i, "out00");
return true;

View File

@@ -32,7 +32,7 @@ function enter(pi) {
if (pi.getParty() != null) {
if (pi.isLeader()) {
for (var i = 0; i < dungeons; i++) {
if(pi.startDungeonInstance(dungeonid + i)) {
if (pi.startDungeonInstance(dungeonid + i)) {
pi.playPortalSound();
pi.warpParty(dungeonid + i, "out00");
return true;
@@ -44,7 +44,7 @@ function enter(pi) {
}
} else {
for (var i = 0; i < dungeons; i++) {
if(pi.startDungeonInstance(dungeonid + i)) {
if (pi.startDungeonInstance(dungeonid + i)) {
pi.playPortalSound();
pi.warp(dungeonid + i, "out00");
return true;

View File

@@ -32,7 +32,7 @@ function enter(pi) {
if (pi.getParty() != null) {
if (pi.isLeader()) {
for (var i = 0; i < dungeons; i++) {
if(pi.startDungeonInstance(dungeonid + i)) {
if (pi.startDungeonInstance(dungeonid + i)) {
pi.playPortalSound();
pi.warpParty(dungeonid + i, "out00");
return true;
@@ -44,7 +44,7 @@ function enter(pi) {
}
} else {
for (var i = 0; i < dungeons; i++) {
if(pi.startDungeonInstance(dungeonid + i)) {
if (pi.startDungeonInstance(dungeonid + i)) {
pi.playPortalSound();
pi.warp(dungeonid + i, "out00");
return true;

View File

@@ -30,7 +30,7 @@ function enter(pi) {
if (pi.getParty() != null) {
if (pi.isLeader()) {
for (var i = 0; i < dungeons; i++) {
if(pi.startDungeonInstance(dungeonid + i)) {
if (pi.startDungeonInstance(dungeonid + i)) {
pi.playPortalSound();
pi.warpParty(dungeonid + i, "out00");
return true;
@@ -42,7 +42,7 @@ function enter(pi) {
}
} else {
for (var i = 0; i < dungeons; i++) {
if(pi.startDungeonInstance(dungeonid + i)) {
if (pi.startDungeonInstance(dungeonid + i)) {
pi.playPortalSound();
pi.warp(dungeonid + i, "out00");
return true;

View File

@@ -30,7 +30,7 @@ function enter(pi) {
if (pi.getParty() != null) {
if (pi.isLeader()) {
for (var i = 0; i < dungeons; i++) {
if(pi.startDungeonInstance(dungeonid + i)) {
if (pi.startDungeonInstance(dungeonid + i)) {
pi.playPortalSound();
pi.warpParty(dungeonid + i, "out00");
return true;
@@ -42,7 +42,7 @@ function enter(pi) {
}
} else {
for (var i = 0; i < dungeons; i++) {
if(pi.startDungeonInstance(dungeonid + i)) {
if (pi.startDungeonInstance(dungeonid + i)) {
pi.playPortalSound();
pi.warp(dungeonid + i, "out00");
return true;

View File

@@ -30,7 +30,7 @@ function enter(pi) {
if (pi.getParty() != null) {
if (pi.isLeader()) {
for (var i = 0; i < dungeons; i++) {
if(pi.startDungeonInstance(dungeonid + i)) {
if (pi.startDungeonInstance(dungeonid + i)) {
pi.playPortalSound();
pi.warpParty(dungeonid + i, "out00");
return true;
@@ -42,7 +42,7 @@ function enter(pi) {
}
} else {
for (var i = 0; i < dungeons; i++) {
if(pi.startDungeonInstance(dungeonid + i)) {
if (pi.startDungeonInstance(dungeonid + i)) {
pi.playPortalSound();
pi.warp(dungeonid + i, "out00");
return true;

View File

@@ -30,7 +30,7 @@ function enter(pi) {
if (pi.getParty() != null) {
if (pi.isLeader()) {
for (var i = 0; i < dungeons; i++) {
if(pi.startDungeonInstance(dungeonid + i)) {
if (pi.startDungeonInstance(dungeonid + i)) {
pi.playPortalSound();
pi.warpParty(dungeonid + i, "out00");
return true;
@@ -42,7 +42,7 @@ function enter(pi) {
}
} else {
for (var i = 0; i < dungeons; i++) {
if(pi.startDungeonInstance(dungeonid + i)) {
if (pi.startDungeonInstance(dungeonid + i)) {
pi.playPortalSound();
pi.warp(dungeonid + i, "out00");
return true;

View File

@@ -30,7 +30,7 @@ function enter(pi) {
if (pi.getParty() != null) {
if (pi.isLeader()) {
for (var i = 0; i < dungeons; i++) {
if(pi.startDungeonInstance(dungeonid + i)) {
if (pi.startDungeonInstance(dungeonid + i)) {
pi.playPortalSound();
pi.warpParty(dungeonid + i, "out00");
return true;
@@ -42,7 +42,7 @@ function enter(pi) {
}
} else {
for (var i = 0; i < dungeons; i++) {
if(pi.startDungeonInstance(dungeonid + i)) {
if (pi.startDungeonInstance(dungeonid + i)) {
pi.playPortalSound();
pi.warp(dungeonid + i, "out00");
return true;

View File

@@ -30,7 +30,7 @@ function enter(pi) {
if (pi.getParty() != null) {
if (pi.isLeader()) {
for (var i = 0; i < dungeons; i++) {
if(pi.startDungeonInstance(dungeonid + i)) {
if (pi.startDungeonInstance(dungeonid + i)) {
pi.playPortalSound();
pi.warpParty(dungeonid + i, "out00");
return true;
@@ -42,7 +42,7 @@ function enter(pi) {
}
} else {
for (var i = 0; i < dungeons; i++) {
if(pi.startDungeonInstance(dungeonid + i)) {
if (pi.startDungeonInstance(dungeonid + i)) {
pi.playPortalSound();
pi.warp(dungeonid + i, "out00");
return true;

View File

@@ -22,7 +22,8 @@
function enter(pi) {
if (pi.hasItem(3992040)) {
pi.playPortalSound(); pi.warp(610010005, "sU6_1");
pi.playPortalSound();
pi.warp(610010005, "sU6_1");
return true;
}
return false;

View File

@@ -22,7 +22,8 @@
function enter(pi) {
if (pi.hasItem(3992040)) {
pi.playPortalSound(); pi.warp(610010005, "sU6_1");
pi.playPortalSound();
pi.warp(610010005, "sU6_1");
return true;
}
return false;

View File

@@ -22,7 +22,8 @@
function enter(pi) {
if (pi.hasItem(3992040)) {
pi.playPortalSound(); pi.warp(610010005, "sU6_1");
pi.playPortalSound();
pi.warp(610010005, "sU6_1");
return true;
}
return false;

View File

@@ -21,6 +21,7 @@
*/
function enter(pi) {
pi.playPortalSound(); pi.warp(610020015, "CC6_A");
pi.playPortalSound();
pi.warp(610020015, "CC6_A");
return true;
}

View File

@@ -21,6 +21,7 @@
*/
function enter(pi) {
pi.playPortalSound(); pi.warp(610020010, "CC1_A");
pi.playPortalSound();
pi.warp(610020010, "CC1_A");
return true;
}

View File

@@ -22,7 +22,8 @@
function enter(pi) {
if (pi.hasItem(3992039)) {
pi.playPortalSound(); pi.warp(610020000, "CM1_B");
pi.playPortalSound();
pi.warp(610020000, "CM1_B");
return false;
}
return true;

View File

@@ -22,7 +22,8 @@
function enter(pi) {
if (pi.hasItem(3992039)) {
pi.playPortalSound(); pi.warp(610020000, "CM1_C");
pi.playPortalSound();
pi.warp(610020000, "CM1_C");
return false;
}
return true;

View File

@@ -22,7 +22,8 @@
function enter(pi) {
if (pi.hasItem(3992039)) {
pi.playPortalSound(); pi.warp(610020000, "CM1_D");
pi.playPortalSound();
pi.warp(610020000, "CM1_D");
return false;
}
return true;

View File

@@ -22,7 +22,8 @@
function enter(pi) {
if (pi.hasItem(3992039)) {
pi.playPortalSound(); pi.warp(610020000, "CM1_E");
pi.playPortalSound();
pi.warp(610020000, "CM1_E");
return false;
}
return true;

View File

@@ -22,7 +22,8 @@
function enter(pi) {
if (pi.hasItem(3992039)) {
pi.playPortalSound(); pi.warp(610020001, "CM2_C");
pi.playPortalSound();
pi.warp(610020001, "CM2_C");
return false;
}
return true;

View File

@@ -22,7 +22,8 @@
function enter(pi) {
if (pi.hasItem(3992039)) {
pi.playPortalSound(); pi.warp(610020001, "CM2_D");
pi.playPortalSound();
pi.warp(610020001, "CM2_D");
return false;
}
return true;

View File

@@ -21,7 +21,8 @@
*/
function enter(pi) {
if (pi.hasItem(3992039)) {
pi.playPortalSound(); pi.warp(610020001, "CM2_E");
pi.playPortalSound();
pi.warp(610020001, "CM2_E");
return false;
}
return true;

View File

@@ -22,7 +22,8 @@
function enter(pi) {
if (pi.hasItem(3992039)) {
pi.playPortalSound(); pi.warp(610020001, "CM2_F");
pi.playPortalSound();
pi.warp(610020001, "CM2_F");
return false;
}
return true;

View File

@@ -22,7 +22,8 @@
function enter(pi) {
if (pi.hasItem(3992040)) {
pi.playPortalSound(); pi.warp(610010004, "U5_1");
pi.playPortalSound();
pi.warp(610010004, "U5_1");
return false;
}
return true;

View File

@@ -22,7 +22,8 @@
function enter(pi) {
if (pi.hasItem(3992040)) {
pi.playPortalSound(); pi.warp(610010201, "sB2_1");
pi.playPortalSound();
pi.warp(610010201, "sB2_1");
return false;
}
return true;

View File

@@ -22,7 +22,8 @@
function enter(pi) {
if (pi.hasItem(3992040)) {
pi.playPortalSound(); pi.warp(610010001, "sU2_1");
pi.playPortalSound();
pi.warp(610010001, "sU2_1");
return false;
}
return true;

View File

@@ -22,7 +22,8 @@
function enter(pi) {
if (pi.hasItem(3992040)) {
pi.playPortalSound(); pi.warp(610010004, "U5_1");
pi.playPortalSound();
pi.warp(610010004, "U5_1");
return false;
}
return true;

View File

@@ -22,7 +22,8 @@
function enter(pi) {
if (pi.hasItem(3992040)) {
pi.playPortalSound(); pi.warp(610010002, "sU3_1");
pi.playPortalSound();
pi.warp(610010002, "sU3_1");
return false;
}
return true;

View File

@@ -20,23 +20,24 @@
*/
/**
-- Odin JavaScript --------------------------------------------------------------------------------
-- Odin JavaScript --------------------------------------------------------------------------------
During The Ride To Orbis
-- By ---------------------------------------------------------------------------------------------
-- By ---------------------------------------------------------------------------------------------
Information
-- Version Info -----------------------------------------------------------------------------------
-- Version Info -----------------------------------------------------------------------------------
1.4 - Code clean up [Information]
1.4 - Remove event instance [Information]
1.3 - Typo >.< [Information]
1.2 - Update to support lastest script [Information]
1.1 - The right statement to bring out the music [Information]
1.0 - First Version by Information
---------------------------------------------------------------------------------------------------
**/
---------------------------------------------------------------------------------------------------
**/
function enter(pi) {
pi.playPortalSound(); pi.warp(200090010, 4);
if(pi.getPlayer().getClient().getChannelServer().getEventSM().getEventManager("Boats").getProperty("haveBalrog").equals("true")) {
pi.playPortalSound();
pi.warp(200090010, 4);
if (pi.getPlayer().getClient().getChannelServer().getEventSM().getEventManager("Boats").getProperty("haveBalrog").equals("true")) {
pi.changeMusic("Bgm04/ArabPirate");
}
return true;

View File

@@ -20,23 +20,25 @@
*/
/**
-- Odin JavaScript --------------------------------------------------------------------------------
-- Odin JavaScript --------------------------------------------------------------------------------
During The Ride To Orbis
-- By ---------------------------------------------------------------------------------------------
-- By ---------------------------------------------------------------------------------------------
Information
-- Version Info -----------------------------------------------------------------------------------
-- Version Info -----------------------------------------------------------------------------------
1.4 - Code clean up [Information]
1.4 - Remove event instance [Information]
1.3 - Typo >.< [Information]
1.2 - Update to support lastest script [Information]
1.1 - The right statement to bring out the music [Information]
1.0 - First Version by Information
---------------------------------------------------------------------------------------------------
**/
---------------------------------------------------------------------------------------------------
**/
function enter(pi) {
pi.playPortalSound(); pi.warp(200090010, 5);
if (pi.getPlayer().getClient().getChannelServer().getEventSM().getEventManager("Boats").getProperty("haveBalrog").equals("true"))
pi.playPortalSound();
pi.warp(200090010, 5);
if (pi.getPlayer().getClient().getChannelServer().getEventSM().getEventManager("Boats").getProperty("haveBalrog").equals("true")) {
pi.changeMusic("Bgm04/ArabPirate");
}
return true;
}

View File

@@ -24,6 +24,7 @@ Vs Pink Bean - Clear stage portal
*/
function enter(pi) {
pi.playPortalSound(); pi.warp(270050000);
pi.playPortalSound();
pi.warp(270050000);
return true;
}

View File

@@ -20,6 +20,7 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
function enter(pi) {
pi.playPortalSound(); pi.warp(230040420, "out00");
pi.playPortalSound();
pi.warp(230040420, "out00");
return true;
}

View File

@@ -24,6 +24,7 @@ Vs Pink Bean - Resurrection stage portal
*/
function enter(pi) {
pi.playPortalSound(); pi.warp(270050100);
pi.playPortalSound();
pi.warp(270050100);
return true;
}

View File

@@ -29,18 +29,17 @@ function enter(pi) {
if (pi.getParty() == null) {
pi.playerMessage(5, "You are currently not in a party, create one to attempt the boss.");
return false;
} else if(!pi.isLeader()) {
} else if (!pi.isLeader()) {
pi.playerMessage(5, "Your party leader must enter the portal to start the battle.");
return false;
} else {
var eli = em.getEligibleParty(pi.getParty());
if(eli.size() > 0) {
if(!em.startInstance(pi.getParty(), pi.getPlayer().getMap(), 1)) {
if (eli.size() > 0) {
if (!em.startInstance(pi.getParty(), pi.getPlayer().getMap(), 1)) {
pi.playerMessage(5, "The battle against the boss has already begun, so you may not enter this place yet.");
return false;
}
}
else { //this should never appear
} else { //this should never appear
pi.playerMessage(5, "You cannot start this battle yet, because either your party is not in the range size, some of your party members are not eligible to attempt it or they are not in this map. If you're having trouble finding party members, try Party Search.");
return false;
}

View File

@@ -5,10 +5,12 @@ function enter(pi) {
var fc = eim.getIntProperty("falls");
if (fc >= 3) {
pi.playPortalSound(); pi.warp(922240200, 0);
pi.playPortalSound();
pi.warp(922240200, 0);
} else {
eim.setIntProperty("falls", fc + 1);
pi.playPortalSound(); pi.warp(pi.getPlayer().getMapId(), 0);
pi.playPortalSound();
pi.warp(pi.getPlayer().getMapId(), 0);
}
return true;

View File

@@ -5,10 +5,12 @@ function enter(pi) {
var fc = eim.getIntProperty("falls");
if (fc >= 3) {
pi.playPortalSound(); pi.warp(922240200, 0);
pi.playPortalSound();
pi.warp(922240200, 0);
} else {
eim.setIntProperty("falls", fc + 1);
pi.playPortalSound(); pi.warp(pi.getPlayer().getMapId(), 0);
pi.playPortalSound();
pi.warp(pi.getPlayer().getMapId(), 0);
}
return true;

View File

@@ -5,10 +5,12 @@ function enter(pi) {
var fc = eim.getIntProperty("falls");
if (fc >= 3) {
pi.playPortalSound(); pi.warp(922240200, 0);
pi.playPortalSound();
pi.warp(922240200, 0);
} else {
eim.setIntProperty("falls", fc + 1);
pi.playPortalSound(); pi.warp(pi.getPlayer().getMapId(), 0);
pi.playPortalSound();
pi.warp(pi.getPlayer().getMapId(), 0);
}
return true;

View File

@@ -5,10 +5,12 @@ function enter(pi) {
var fc = eim.getIntProperty("falls");
if (fc >= 3) {
pi.playPortalSound(); pi.warp(922240200, 0);
pi.playPortalSound();
pi.warp(922240200, 0);
} else {
eim.setIntProperty("falls", fc + 1);
pi.playPortalSound(); pi.warp(pi.getPlayer().getMapId(), 0);
pi.playPortalSound();
pi.warp(pi.getPlayer().getMapId(), 0);
}
return true;

View File

@@ -3,7 +3,7 @@
function enter(pi) {
var stage = ((Math.floor(pi.getMapId() / 100)) % 10) - 1;
var em = pi.getEventManager("TD_Battle" + stage);
if(em == null) {
if (em == null) {
pi.playerMessage(5, "TD Battle " + stage + " encountered an unexpected error and is currently unavailable.");
return false;
}
@@ -11,18 +11,17 @@ function enter(pi) {
if (pi.getParty() == null) {
pi.playerMessage(5, "You are currently not in a party, create one to attempt the boss.");
return false;
} else if(!pi.isLeader()) {
} else if (!pi.isLeader()) {
pi.playerMessage(5, "Your party leader must enter the portal to start the battle.");
return false;
} else {
var eli = em.getEligibleParty(pi.getParty());
if(eli.size() > 0) {
if(!em.startInstance(pi.getParty(), pi.getPlayer().getMap(), 1)) {
if (eli.size() > 0) {
if (!em.startInstance(pi.getParty(), pi.getPlayer().getMap(), 1)) {
pi.playerMessage(5, "The battle against the boss has already begun, so you may not enter this place yet.");
return false;
}
}
else {
} else {
pi.playerMessage(5, "Your party must consist of at least 2 players to attempt the boss.");
return false;
}

View File

@@ -1,10 +1,9 @@
function enter(pi) {
var questProgress = pi.getQuestProgressInt(2330, 3300005) + pi.getQuestProgressInt(2330, 3300006) + pi.getQuestProgressInt(2330, 3300007); //3 Yetis
if(pi.isQuestStarted(2330) && questProgress < 3){
if (pi.isQuestStarted(2330) && questProgress < 3) {
pi.openNpc(1300013);
}
else{
} else {
pi.playPortalSound();
pi.warp(106021401, 1);
}

View File

@@ -1,25 +1,23 @@
function enter(pi) {
if(pi.isQuestCompleted(2331)) {
if (pi.isQuestCompleted(2331)) {
pi.openNpc(1300013);
return false;
}
if(pi.isQuestCompleted(2333) && pi.isQuestStarted(2331) && !pi.hasItem(4001318)){
if (pi.isQuestCompleted(2333) && pi.isQuestStarted(2331) && !pi.hasItem(4001318)) {
pi.getPlayer().message("Lost the Royal Seal, eh? Worry not! Kevin's code here to save your hide.");
if(pi.canHold(4001318)){
if (pi.canHold(4001318)) {
pi.gainItem(4001318, 1);
}
else{
} else {
pi.getPlayer().message("Hey, how do you plan to hold this Seal when your inventory is full?");
}
}
if(pi.isQuestCompleted(2333)){
if (pi.isQuestCompleted(2333)) {
pi.playPortalSound();
pi.warp(106021600, 1);
return true;
}
else if(pi.isQuestStarted(2332) && pi.hasItem(4032388)){
} else if (pi.isQuestStarted(2332) && pi.hasItem(4032388)) {
pi.forceCompleteQuest(2332, 1300002);
pi.getPlayer().message("You've found the princess!");
pi.giveCharacterExp(4400, pi.getPlayer());
@@ -28,7 +26,7 @@ function enter(pi) {
var party = pi.getPlayer().getParty();
if (party != null) {
var eli = em.getEligibleParty(pi.getParty()); // thanks Conrad for pointing out missing eligible party declaration here
if(eli.size() > 0) {
if (eli.size() > 0) {
if (em.startInstance(party, pi.getMap(), 1)) {
pi.playPortalSound();
return true;
@@ -46,14 +44,13 @@ function enter(pi) {
return false;
}
}
}
else if(pi.isQuestStarted(2333) || (pi.isQuestCompleted(2332) && !pi.isQuestStarted(2333))){
} else if (pi.isQuestStarted(2333) || (pi.isQuestCompleted(2332) && !pi.isQuestStarted(2333))) {
var em = pi.getEventManager("MK_PrimeMinister");
var party = pi.getPlayer().getParty();
if (party != null) {
var eli = em.getEligibleParty(pi.getParty());
if(eli.size() > 0) {
if (eli.size() > 0) {
if (em.startInstance(party, pi.getMap(), 1)) {
pi.playPortalSound();
return true;
@@ -71,8 +68,7 @@ function enter(pi) {
return false;
}
}
}
else{
} else {
pi.getPlayer().message("The door seems to be locked. Perhaps I can find a key to open it...");
return false;
}

View File

@@ -1,6 +1,6 @@
function enter(pi) {
var nex = pi.getEventManager("GuardianNex");
if(nex == null) {
if (nex == null) {
pi.message("Guardian Nex challenge encountered an error and is unavailable.");
return false;
}
@@ -8,14 +8,14 @@ function enter(pi) {
var quests = [3719, 3724, 3730, 3736, 3742, 3748];
var mobs = [7120100, 7120101, 7120102, 8120100, 8120101, 8140510];
for(var i = 0; i < quests.length; i++) {
for (var i = 0; i < quests.length; i++) {
if (pi.isQuestActive(quests[i])) {
if(pi.getQuestProgressInt(quests[i], mobs[i]) != 0) {
if (pi.getQuestProgressInt(quests[i], mobs[i]) != 0) {
pi.message("You already faced Nex. Complete your mission.");
return false;
}
if(!nex.startInstance(i, pi.getPlayer())) {
if (!nex.startInstance(i, pi.getPlayer())) {
pi.message("Someone is already challenging Nex. Wait for them to finish before you enter.");
return false;
} else {

View File

@@ -19,6 +19,7 @@
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*
Zakum PQ portal
*/
@@ -34,6 +35,7 @@ function enter(pi) {
return false;
}
pi.playPortalSound(); pi.warp(211042300);
pi.playPortalSound();
pi.warp(211042300);
return true;
}

View File

@@ -19,32 +19,34 @@
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*
Zakum Entrance
*/
function enter(pi) {
if (!(pi.isQuestStarted(100200) || pi.isQuestCompleted(100200))) {
pi.getPlayer().dropMessage(5,"You need approval from the masters to battle. You may not attempt the boss right now.");
pi.getPlayer().dropMessage(5, "You need approval from the masters to battle. You may not attempt the boss right now.");
return false;
}
if (!pi.isQuestCompleted(100201)) {
pi.getPlayer().dropMessage(5,"You haven't completed all the trials yet. You may not attempt the boss right now.");
pi.getPlayer().dropMessage(5, "You haven't completed all the trials yet. You may not attempt the boss right now.");
return false;
}
if (!pi.haveItem(4001017)) { // thanks Conrad for pointing out missing checks for token item and unused reactor
pi.getPlayer().dropMessage(5,"You do not have the Eye of Fire. You may not face the boss.");
pi.getPlayer().dropMessage(5, "You do not have the Eye of Fire. You may not face the boss.");
return false;
}
var react = pi.getMap().getReactorById(2118002);
if (react != null && react.getState() > 0) {
pi.getPlayer().dropMessage(5,"The entrance is currently blocked.");
pi.getPlayer().dropMessage(5, "The entrance is currently blocked.");
return false;
}
pi.playPortalSound(); pi.warp(211042400,"west00");
pi.playPortalSound();
pi.warp(211042400, "west00");
return true;
}

View File

@@ -19,6 +19,7 @@
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*
* @author: Moogra
* @portal: aMatchMove2
@@ -26,6 +27,7 @@
*/
function enter(pi) {
pi.playPortalSound(); pi.warp(pi.getPlayer().getSavedLocation("MIRROR"));
pi.playPortalSound();
pi.warp(pi.getPlayer().getSavedLocation("MIRROR"));
return true;
}

View File

@@ -19,7 +19,7 @@
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
function enter (pi) {
function enter(pi) {
pi.showInstruction("Press the #e#b[Up]#k arrow#n to use the portal and move to the next map.", 230, 5);
return true;
}

View File

@@ -20,6 +20,7 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
function enter(pi) {
pi.playPortalSound(); pi.warp(670010300, 0);
pi.playPortalSound();
pi.warp(670010300, 0);
return true;
}

View File

@@ -20,6 +20,7 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
function enter(pi) {
pi.playPortalSound(); pi.warp(670010301, 0);
pi.playPortalSound();
pi.warp(670010301, 0);
return true;
}

View File

@@ -20,6 +20,7 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
function enter(pi) {
pi.playPortalSound(); pi.warp(670010302, 0);
pi.playPortalSound();
pi.warp(670010302, 0);
return true;
}

View File

@@ -20,6 +20,7 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
function enter(pi) {
pi.playPortalSound(); pi.warp(670010400, 0);
pi.playPortalSound();
pi.warp(670010400, 0);
return true;
}

View File

@@ -20,6 +20,7 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
function enter(pi) {
pi.playPortalSound(); pi.warp(670010500, 0);
pi.playPortalSound();
pi.warp(670010500, 0);
return true;
}

View File

@@ -20,6 +20,7 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
function enter(pi) {
pi.playPortalSound(); pi.warp(670010600, 0);
pi.playPortalSound();
pi.warp(670010600, 0);
return true;
}

View File

@@ -25,8 +25,9 @@
function enter(pi) {
var name = pi.getPortal().getName().substring(2, 4);
var gate = pi.getPlayer().getMap().getReactorByName("gate" + name);
if(gate != null && gate.getState() == 4) {
pi.playPortalSound(); pi.warp(670010600, "gt" + name + "PIB");
if (gate != null && gate.getState() == 4) {
pi.playPortalSound();
pi.warp(670010600, "gt" + name + "PIB");
return true;
} else {
pi.message("The gate is not opened yet.");

View File

@@ -20,6 +20,7 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
function enter(pi) {
pi.playPortalSound(); pi.warp(230040420, 0);
pi.playPortalSound();
pi.warp(230040420, 0);
return true;
}

View File

@@ -1,4 +1,5 @@
function enter(pi) {
pi.playPortalSound(); pi.warp(914000100, 1);
pi.playPortalSound();
pi.warp(914000100, 1);
return true;
}
}

View File

@@ -19,6 +19,7 @@
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*
@author kevintjuh93
*/

View File

@@ -19,6 +19,7 @@
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*
@author kevintjuh93
*/

View File

@@ -19,6 +19,7 @@
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*
@author kevintjuh93
*/

View File

@@ -19,6 +19,7 @@
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*
@author kevintjuh93
*/

View File

@@ -19,6 +19,7 @@
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*
@author kevintjuh93
*/

View File

@@ -19,6 +19,7 @@
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*
@author kevintjuh93
*/

View File

@@ -19,6 +19,7 @@
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*
@author kevintjuh93
*/

View File

@@ -19,6 +19,7 @@
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*
@author kevintjuh93
*/

View File

@@ -19,6 +19,7 @@
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*
@author kevintjuh93
*/

View File

@@ -19,6 +19,7 @@
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*
@author kevintjuh93
*/

View File

@@ -19,6 +19,7 @@
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*
@author kevintjuh93
*/

View File

@@ -19,6 +19,7 @@
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*
@author kevintjuh93
*/

View File

@@ -10,7 +10,8 @@ function enter(pi) {
pi.teachSkill(20000017, 1, 0, -1);
pi.teachSkill(20000018, 1, 0, -1);
//actually nexon does enableActions here :P
pi.playPortalSound(); pi.warp(914000200, 1);
pi.playPortalSound();
pi.warp(914000200, 1);
return true;
} else {
pi.message("You can only exit after you accept the quest from Athena Pierce, who is to your right.");

View File

@@ -6,6 +6,7 @@ function enter(pi) {
pi.teachSkill(20000014, 1, 0, -1);
pi.teachSkill(20000015, 1, 0, -1);
//actually nexon does enableActions here :P
pi.playPortalSound(); pi.warp(914000210, 1);
pi.playPortalSound();
pi.warp(914000210, 1);
return true;
}

View File

@@ -4,6 +4,7 @@ function enter(pi) {
//nexon sends updatePlayerStats Stat.AVAILABLESP 0
pi.teachSkill(20000016, 1, 0, -1);
//actually nexon does enableActions here :P
pi.playPortalSound(); pi.warp(914000220, 1);
pi.playPortalSound();
pi.warp(914000220, 1);
return true;
}

View File

@@ -20,6 +20,7 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
function enter(pi) {
pi.playPortalSound(); pi.warp(980010020, 0);
pi.playPortalSound();
pi.warp(980010020, 0);
return true;
}

View File

@@ -20,6 +20,7 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
function enter(pi) {
pi.playPortalSound(); pi.warp(980010000, 0);
pi.playPortalSound();
pi.warp(980010000, 0);
return true;
}

View File

@@ -24,8 +24,9 @@ Agit's hideout (leader of the Sand Bandits)
*/
function enter(pi) {
if(pi.isQuestCompleted(3928) && pi.isQuestCompleted(3931) && pi.isQuestCompleted(3934)) {
pi.playPortalSound(); pi.warp(260000201, 1);
if (pi.isQuestCompleted(3928) && pi.isQuestCompleted(3931) && pi.isQuestCompleted(3934)) {
pi.playPortalSound();
pi.warp(260000201, 1);
return true;
} else {
pi.message("Access restricted to only members of the Sand Bandits team.");

View File

@@ -20,14 +20,14 @@
*/
/**
-- Odin JavaScript --------------------------------------------------------------------------------
-- Odin JavaScript --------------------------------------------------------------------------------
Portal - To get into Ariant Castle
-- By ---------------------------------------------------------------------------------------------
-- By ---------------------------------------------------------------------------------------------
Jayd
-- Version Info -----------------------------------------------------------------------------------
-- Version Info -----------------------------------------------------------------------------------
1.0 - First Version by Jayd
---------------------------------------------------------------------------------------------------
**/
---------------------------------------------------------------------------------------------------
**/
function enter(pi) {
if (pi.getPlayer().haveItem(4031582) == true) {

View File

@@ -24,10 +24,11 @@ function isTigunMorphed(ch) {
}
function enter(pi) {
if(isTigunMorphed(pi.getPlayer())) {
if (isTigunMorphed(pi.getPlayer())) {
return false;
} else {
pi.playPortalSound(); pi.warp(260000300, 7);
pi.playPortalSound();
pi.warp(260000300, 7);
pi.message("You, intruder! You don't have permission to roam the palace! Get out!!");
return true;
}

View File

@@ -1,4 +1,5 @@
function enter(pi) {
pi.playPortalSound(); pi.warp(105100000, 2);
pi.playPortalSound();
pi.warp(105100000, 2);
return true;
}

View File

@@ -1,9 +1,10 @@
function enter(pi) {
if (!pi.canHold(4001261,1)) {
if (!pi.canHold(4001261, 1)) {
pi.playerMessage(5, "Please make 1 ETC room.");
return false;
}
pi.gainItem(4001261,1);
pi.playPortalSound(); pi.warp(105100100,0);
pi.gainItem(4001261, 1);
pi.playPortalSound();
pi.warp(105100100, 0);
return true;
}

View File

@@ -1,6 +1,7 @@
function enter(pi) {
if (pi.isQuestStarted(2570)) {
pi.playPortalSound(); pi.warp(120000101, 0);
pi.playPortalSound();
pi.warp(120000101, 0);
return true;
}
pi.earnTitle("You still got some stuff to take care of. I can see it in your eyes. Wait...no, those are eye boogers.");

View File

@@ -10,18 +10,17 @@ function enter(pi) {
if (pi.getParty() == null) {
pi.playerMessage(5, "You are currently not in a party, create one to attempt the boss.");
return false;
} else if(!pi.isLeader()) {
} else if (!pi.isLeader()) {
pi.playerMessage(5, "Your party leader must enter the portal to start the battle.");
return false;
} else {
var eli = em.getEligibleParty(pi.getParty());
if(eli.size() > 0) {
if(!em.startInstance(pi.getParty(), pi.getPlayer().getMap(), 1)) {
if (eli.size() > 0) {
if (!em.startInstance(pi.getParty(), pi.getPlayer().getMap(), 1)) {
pi.playerMessage(5, "The battle against the boss has already begun, so you may not enter this place yet.");
return false;
}
}
else { //this should never appear
} else { //this should never appear
pi.playerMessage(5, "You cannot start this battle yet, because either your party is not in the range size, some of your party members are not eligible to attempt it or they are not in this map. If you're having trouble finding party members, try Party Search.");
return false;
}

View File

@@ -1,4 +1,5 @@
function enter(pi) {
pi.playPortalSound(); pi.warp(925000000, 2);
pi.playPortalSound();
pi.warp(925000000, 2);
return true;
}

View File

@@ -1,11 +1,12 @@
function enter(pi) {
if(pi.isQuestStarted(2224) || pi.isQuestStarted(2226) || pi.isQuestCompleted(2227)) {
if (pi.isQuestStarted(2224) || pi.isQuestStarted(2226) || pi.isQuestCompleted(2227)) {
var hourDay = pi.getHourOfDay();
if(!((hourDay >= 0 && hourDay < 7) || hourDay >= 17)) {
if (!((hourDay >= 0 && hourDay < 7) || hourDay >= 17)) {
pi.getPlayer().dropMessage(5, "You cannot access this area right now.");
return false;
} else {
pi.playPortalSound(); pi.warp(pi.isQuestCompleted(2227) ? 910100001 : 910100000,"out00");
pi.playPortalSound();
pi.warp(pi.isQuestCompleted(2227) ? 910100001 : 910100000, "out00");
return true;
}
}

View File

@@ -3,11 +3,12 @@ var windowTime = 10 * 1000;
function enter(pi) {
var eim = pi.getEventInstance();
var level = eim.getProperty("level");
if(eim.getProperty("stage2b") == "0") {
if (eim.getProperty("stage2b") == "0") {
pi.getMap(925100202).spawnAllMonstersFromMapSpawnList(level, true);
eim.setProperty("stage2b", "1");
}
pi.playPortalSound(); pi.warp(925100202,0);
pi.playPortalSound();
pi.warp(925100202, 0);
return true;
}

View File

@@ -3,11 +3,12 @@ var windowTime = 10 * 1000;
function enter(pi) {
var eim = pi.getEventInstance();
var level = eim.getProperty("level");
if(eim.getProperty("stage3b") == "0") {
if (eim.getProperty("stage3b") == "0") {
pi.getMap(925100302).spawnAllMonstersFromMapSpawnList(level, true);
eim.setProperty("stage3b", "1");
}
pi.playPortalSound(); pi.warp(925100302,0);
pi.playPortalSound();
pi.warp(925100302, 0);
return true;
}

View File

@@ -1,11 +1,14 @@
function passedGrindMode(map, eim) {
if(eim.getIntProperty("grindMode") == 0) return true;
if (eim.getIntProperty("grindMode") == 0) {
return true;
}
return eim.activatedAllReactorsOnMap(map, 2511000, 2517999);
}
function enter(pi) {
if (pi.getMap().getMonsters().size() == 0 && passedGrindMode(pi.getMap(), pi.getEventInstance())) {
pi.playPortalSound(); pi.warp(925100100,0); //next
pi.playPortalSound();
pi.warp(925100100, 0); //next
return true;
} else {
pi.playerMessage(5, "The portal is not opened yet.");

View File

@@ -2,13 +2,14 @@ function enter(pi) {
try {
var eim = pi.getEventInstance();
if (eim != null && eim.getProperty("stage2").equals("3")) {
pi.playPortalSound(); pi.warp(925100200,0); //next
pi.playPortalSound();
pi.warp(925100200, 0); //next
return true;
} else {
pi.playerMessage(5, "The portal is not opened yet.");
return false;
}
} catch(e) {
} catch (e) {
pi.playerMessage(5, "Error: " + e);
}

View File

@@ -1,11 +1,14 @@
function passedGrindMode(map, eim) {
if(eim.getIntProperty("grindMode") == 0) return true;
if (eim.getIntProperty("grindMode") == 0) {
return true;
}
return eim.activatedAllReactorsOnMap(map, 2511000, 2517999);
}
function enter(pi) {
if (pi.getMap().getMonsters().size() == 0 && passedGrindMode(pi.getMap(), pi.getEventInstance())) {
pi.playPortalSound(); pi.warp(925100300,0); //next
pi.playPortalSound();
pi.warp(925100300, 0); //next
return true;
} else {
pi.playerMessage(5, "The portal is not opened yet.");

View File

@@ -1,11 +1,14 @@
function passedGrindMode(map, eim) {
if(eim.getIntProperty("grindMode") == 0) return true;
if (eim.getIntProperty("grindMode") == 0) {
return true;
}
return eim.activatedAllReactorsOnMap(map, 2511000, 2517999);
}
function enter(pi) {
if (pi.getMap().getMonsters().size() == 0 && passedGrindMode(pi.getMap(), pi.getEventInstance())) {
pi.playPortalSound(); pi.warp(925100400,0); //next
pi.playPortalSound();
pi.warp(925100400, 0); //next
return true;
} else {
pi.playerMessage(5, "The portal is not opened yet.");

Some files were not shown because too many files have changed in this diff Show More