Adjusted AP gains, to get it to work following the AP Reset check method. Fixed usage of inexistent itemids on CPQ and fishing. Fixed one-of-a-kind items being lost in player trades due to missing inventory checks. Implemented matching system for the guild creation phase. All players intending to join the new guild must be on the Guild Headquartes and accept the creation of the guild. Fixed changing jobs not properly updating info on the party tab. Fixed double tooltip information on CPQ actions UI. Fixed CPQ not disbanding after a player leaves the party/instance. Fixed checks for "in-progress" CPQ instances. Fixed changing maps on CPQ not leading players back to the starting battlefield. Reviewed login system, now preventing non-local IP connecting on local server and local IP on non-local server. Reviewed login system, now cherrypicking sessions in transition state when trying to disconnect them due to a failed login (avoiding possible mishaps due to duplicate sessions of a same account). Adjusted PiratePQ stage 2, now mobs respawn rather than making party leader request for new waves. Adjusted Prime Minister, its spawn is no longer related to starting the quest. It should also allow party fights. Fixed "forcevac" command not properly applying, rather sending to inventory, "consume-on-pickup" items. Fixed (probably) accId = 0 issue on login, that was occurring due to client accountid's being set to 0 a while before being checked once again on finishLogin(). Fixed an issue with extended time on CPQ not properly showing the end-match's visual effect.
84 lines
3.2 KiB
JavaScript
84 lines
3.2 KiB
JavaScript
/*
|
|
NPC: Blocked Entrance (portal?)
|
|
MAP: Mushroom Castle - East Castle Tower (106021400)
|
|
*/
|
|
|
|
var status;
|
|
|
|
function start(){
|
|
status = -1;
|
|
action(1, 0, 0);
|
|
}
|
|
|
|
function action(mode, type, selection){
|
|
if(mode == -1){
|
|
cm.dispose();
|
|
return;
|
|
}
|
|
else if(mode == 0 && status == 0){
|
|
cm.dispose();
|
|
return;
|
|
}
|
|
else if(mode == 0)
|
|
status--;
|
|
else
|
|
status++;
|
|
|
|
|
|
if(cm.getMapId() == 106021402) {
|
|
if (!(cm.isQuestCompleted(2331))) {
|
|
cm.dispose();
|
|
return;
|
|
}
|
|
|
|
if(status == 0){
|
|
cm.sendSimple("#L0#Enter to fight #bKing Pepe#k and #bYeti Brothers#k.#l\r\n#L1#Enter to fight #bPrime Minister#k.#l");
|
|
}
|
|
else if(status == 1){
|
|
if(selection == 0){
|
|
var pepe = cm.getEventManager("KingPepeAndYetis");
|
|
pepe.setProperty("player", cm.getPlayer().getName());
|
|
pepe.startInstance(cm.getPlayer());
|
|
cm.dispose();
|
|
return;
|
|
}
|
|
|
|
else if(selection == 1){
|
|
var em = cm.getEventManager("MK_PrimeMinister2");
|
|
|
|
var party = cm.getPlayer().getParty();
|
|
if (party != null) {
|
|
if (!em.startInstance(party, cm.getMap())) {
|
|
cm.sendOk("Another party is already challenging the boss in this channel.");
|
|
}
|
|
} else {
|
|
if (!em.startInstance(cm.getPlayer())) {
|
|
cm.sendOk("Another party is already challenging the boss in this channel.");
|
|
}
|
|
}
|
|
|
|
cm.dispose();
|
|
return;
|
|
}
|
|
}
|
|
} else {
|
|
var questProgress = cm.getQuestProgress(2330, 3300005) + cm.getQuestProgress(2330, 3300006) + cm.getQuestProgress(2330, 3300007); //3 Yetis
|
|
if (!(cm.isQuestStarted(2330) && questProgress < 3)) { // thanks Vcoc for finding an exploit with boss entry through NPC
|
|
cm.dispose();
|
|
return;
|
|
}
|
|
|
|
if(status == 0){
|
|
cm.sendSimple("#L1#Enter to fight #bKing Pepe#k and #bYeti Brothers#k.#l");
|
|
}
|
|
else if(status == 1){
|
|
if(selection == 1){
|
|
var pepe = cm.getEventManager("KingPepeAndYetis");
|
|
pepe.setProperty("player", cm.getPlayer().getName());
|
|
pepe.startInstance(cm.getPlayer());
|
|
cm.dispose();
|
|
return;
|
|
}
|
|
}
|
|
}
|
|
} |