
Originally Posted by
cihadpx68
@darkwar4ever
well, I didn't have !pmob command
so i and my friend coded an event, and if can
i want to release it with ur credits for the npc's
and the events with our credits.
its just for the ppl who dont have !pmob
and with the event and all its more better
Go ahead, I don't care really. :3 I expanded my quest already... that'll be custom I guess.

Originally Posted by
lit0aznb3ar
I have to say this is really sexy its works perfectly but question
I would like to take out my rebirth functions for cody and take out the command @rebirth. I'm using ThePack v62 how do i take it out? D:
Taking out the rebirth functions in the command is explained. Taking it out for CODY is a bit different.
You have to find the lines where Rebirth is present. In ThePack, there's a command called cm.doreborn(); or something like that. Search reborn in NPC 9200000.js and replace that line with something simple like:
cm.sendOk("Well, congratulations on reaching such a high level. Perhaps you should try the Rebirth Quest located at [location]");
Here's my Cody:
(It should work with your server because the methods are the same. This one's Rev.78 btw.)
Code:
importPackage(net.sf.odinms.client);
var status = 0;
var jobName;
var job;
function start() {
status = -1;
action(1, 0, 0);
}
function action(mode, type, selection) {
if (mode == -1) {
cm.sendOk("Well okay then. Come back if you change your mind.\r\n\r\nGood luck on your training.");
cm.dispose();
} else {
if (mode == 1)
status++;
else
status--;
if (status == 0) {
cm.sendNext("Hello, I'm in charge of Job Advancing.");
} else if (status == 1) {
if (cm.getLevel() < 200 && cm.getJob().equals(net.sf.odinms.client.MapleJob.BEGINNER)) {
if (cm.getLevel() < 8) {
cm.sendNext("Sorry, but you have to be at least level 8 to use my services.");
status = 98;
} else if (cm.getLevel() < 10) {
cm.sendYesNo("Congratulations of reaching such a high level. Would you like to make the #rFirst Job Advancement#k as a #rMagician#k?");
status = 150;
} else {
cm.sendYesNo("Congratulations on reaching such a high level. Would you like to make the #rFirst Job Advancement#k?");
status = 153;
}
} else if (cm.getLevel() < 30) {
cm.sendNext("Sorry, but you have to be at least level 30 to make the #rSecond Job Advancement#k.");
status = 98;
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.THIEF)) {
cm.sendSimple("Congratulations on reaching such a high level. Which would you like to be? #b\r\n#L0#Assassin#l\r\n#L1#Bandit#l#k");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.WARRIOR)) {
cm.sendSimple("Congratulations on reaching such a high level. Which would you like to be? #b\r\n#L2#Fighter#l\r\n#L3#Page#l\r\n#L4#Spearman#l#k");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.MAGICIAN)) {
cm.sendSimple("Congratulations on reaching such a high level. Which would you like to be? #b\r\n#L5#Ice Lightning Wizard#l\r\n#L6#Fire Poison Wizard#l\r\n#L7#Cleric#l#k");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.BOWMAN)) {
cm.sendSimple("Congratulations on reaching such a high level. Which would you like to be? #b\r\n#L8#Hunter#l\r\n#L9#Crossbowman#l#k");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.PIRATE)) {
cm.sendSimple("Congratulations on reaching such a high level. Which would you like to be? #b\r\n#L10#Brawler#l\r\n#L11#Gunslinger#l#k");
} else if (cm.getLevel() < 70) {
cm.sendNext("Sorry, but you have to be at least level 70 to make the #rThird Job Advancement#k.");
status = 98;
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.ASSASSIN)) {
status = 63;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.BANDIT)) {
status = 66;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.HUNTER)) {
status = 69;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.CROSSBOWMAN)) {
status = 72;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.FP_WIZARD)) {
status = 75;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.IL_WIZARD)) {
status = 78;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.CLERIC)) {
status = 81;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.FIGHTER)) {
status = 84;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.PAGE)) {
status = 87;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.SPEARMAN)) {
status = 90;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.GUNSLINGER)) {
status = 95;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.BRAWLER)) {
status = 92;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getLevel() < 120) {
cm.sendNext("Sorry, but you have to be at least level 120 to make the #rForth Job Advancement#k.");
status = 98;
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.HERMIT)) {
status = 105;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.CHIEFBANDIT)) {
status = 108;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.RANGER)) {
status = 111;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.SNIPER)) {
status = 114;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.FP_MAGE)) {
status = 117;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.IL_MAGE)) {
status = 120;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.PRIEST)) {
status = 123;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.CRUSADER)) {
status = 126;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.WHITEKNIGHT)) {
status = 129;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.DRAGONKNIGHT)) {
status = 132;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.MARAUDER)) {
status = 133;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.OUTLAW)) {
status = 134;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getLevel() < 200) {
cm.sendNext("Sorry, but you have already attained the highest level of your job's mastery. \r\n\r\nHowever, you can #rrebirth#k when you are level 200.");
status = 98;
} else if (cm.getLevel() >= 200) {
cm.sendYesNo("Ahh... It is good to see you again. Your skills have finally reached the maximum of its potential. So, with all my heart, I congratulate you, great hero. \r\n\r\nYou have been through a long and challenging road, and in so doing, have become immensely strong. It is now that I would recommend you do the rebirth quest in [LOCATION]. By rebirthing, you will become a level 1 #bBeginner#k again, but all your abilities, skills, items and mesos, will remain as they are. However, you will only be able to keep the skills that you have placed in your #bkey setting#k. \r\n\r\nSo, tell me, do you wish to be #rreborn#k?");
status = 160;
} else {
cm.dispose();
}
} else if (status == 2) {
switch(selection) {
case 0: jobName = "Assassin"; job = net.sf.odinms.client.MapleJob.ASSASSIN; break;
case 1: jobName = "Bandit"; job = net.sf.odinms.client.MapleJob.BANDIT; break;
case 2: jobName = "Fighter"; job = net.sf.odinms.client.MapleJob.FIGHTER; break;
case 3: jobName = "Page"; job = net.sf.odinms.client.MapleJob.PAGE; break;
case 4: jobName = "Spearman"; job = net.sf.odinms.client.MapleJob.SPEARMAN; break;
case 5: jobName = "Ice Lightning Wizard"; job = net.sf.odinms.client.MapleJob.IL_WIZARD; break;
case 6: jobName = "Fire Poison Wizard"; job = net.sf.odinms.client.MapleJob.FP_WIZARD; break;
case 7: jobName = "Cleric"; job = net.sf.odinms.client.MapleJob.CLERIC; break;
case 8: jobName = "Hunter"; job = net.sf.odinms.client.MapleJob.HUNTER; break;
case 9: jobName = "Crossbowman"; job = net.sf.odinms.client.MapleJob.CROSSBOWMAN; break;
case 10:jobName = "Brawler"; job = net.sf.odinms.client.MapleJob.BRAWLER; break;
case 11:jobName = "Gunslinger"; job = net.sf.odinms.client.MapleJob.GUNSLINGER; break;
}
cm.sendYesNo("Do you want to become a #r" + jobName + "#k?");
} else if (status == 3) {
cm.changeJob(job);
cm.sendOk("There you go. Hope you enjoy it. See you around in the future maybe :)");
cm.dispose();
} else if (status == 61) {
if (cm.getJob().equals(net.sf.odinms.client.MapleJob.ASSASSIN)) {
status = 63;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.BANDIT)) {
status = 66;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.HUNTER)) {
status = 69;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.CROSSBOWMAN)) {
status = 72;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.FP_WIZARD)) {
status = 75;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.IL_WIZARD)) {
status = 78;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.CLERIC)) {
status = 81;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.FIGHTER)) {
status = 84;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.PAGE)) {
status = 87;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.SPEARMAN)) {
status = 90;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.GUNSLINGER)) {
status = 98;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.BRAWLER)) {
status = 93;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else {
cm.dispose();
}
} else if (status == 64) {
cm.changeJob(MapleJob.HERMIT);
cm.sendOk("There you go. Hope you enjoy it. See you around in the future.");
cm.dispose();
} else if (status == 67) {
cm.changeJob(MapleJob.CHIEFBANDIT);
cm.sendOk("There you go. Hope you enjoy it. See you around in the future.");
cm.dispose();
} else if (status == 70) {
cm.changeJob(MapleJob.RANGER);
cm.sendOk("There you go. Hope you enjoy it. See you around in the future.");
cm.dispose();
} else if (status == 73) {
cm.changeJob(MapleJob.SNIPER);
cm.sendOk("There you go. Hope you enjoy it. See you around in the future.");
cm.dispose();
} else if (status == 76) {
cm.changeJob(MapleJob.FP_MAGE);
cm.sendOk("There you go. Hope you enjoy it. See you around in the future.");
cm.dispose();
} else if (status == 79) {
cm.changeJob(MapleJob.IL_MAGE);
cm.sendOk("There you go. Hope you enjoy it. See you around in the future.)");
cm.dispose();
} else if (status == 82) {
cm.changeJob(MapleJob.PRIEST);
cm.sendOk("There you go. Hope you enjoy it. See you around in the future.");
cm.dispose();
} else if (status == 85) {
cm.changeJob(MapleJob.CRUSADER);
cm.sendOk("There you go. Hope you enjoy it. See you around in the future.");
cm.dispose();
} else if (status == 88) {
cm.changeJob(MapleJob.WHITEKNIGHT);
cm.sendOk("There you go. Hope you enjoy it. See you around in the future.");
cm.dispose();
} else if (status == 91) {
cm.changeJob(MapleJob.DRAGONKNIGHT);
cm.sendOk("There you go. Hope you enjoy it. See you around in the future.");
cm.dispose();
} else if (status == 93) {
cm.changeJob(MapleJob.MARAUDER);
cm.sendOk("There you go. Hope you enjoy it. See you around in the future.");
cm.dispose();
} else if (status == 96) {
cm.changeJob(MapleJob.OUTLAW);
cm.sendOk("There you go. Hope you enjoy it. See you around in the future.");
cm.dispose();
} else if (status == 99) {
cm.sendOk("Good luck on your training.");
cm.dispose();
} else if (status == 102) {
if (cm.getJob().equals(net.sf.odinms.client.MapleJob.HERMIT)) {
status = 105;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.CHIEFBANDIT)) {
status = 108;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.RANGER)) {
status = 111;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.SNIPER)) {
status = 114;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.FP_MAGE)) {
status = 117;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.IL_MAGE)) {
status = 120;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.PRIEST)) {
status = 123;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.CRUSADER)) {
status = 126;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.WHITEKNIGHT)) {
status = 129;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.DRAGONKNIGHT)) {
status = 132;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.MARAUDER)) {
status = 134;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else if (cm.getJob().equals(net.sf.odinms.client.MapleJob.OUTLAW)) {
status = 136;
cm.sendYesNo("Congratulations on reaching such a high level. Do you want to Job Advance now?");
} else {
cm.dispose();
}
} else if (status == 106) {
cm.changeJob(MapleJob.NIGHTLORD);
cm.sendOk("There you go. Hope you enjoy it.");
cm.dispose();
} else if (status == 109) {
cm.changeJob(MapleJob.SHADOWER);
cm.sendOk("There you go. Hope you enjoy it.");
cm.dispose();
} else if (status == 112) {
cm.changeJob(MapleJob.BOWMASTER);
cm.sendOk("There you go. Hope you enjoy it.");
cm.dispose();
} else if (status == 115) {
cm.changeJob(MapleJob.MARKSMAN);
cm.sendOk("There you go. Hope you enjoy it.");
cm.dispose();
} else if (status == 118) {
cm.changeJob(MapleJob.FP_ARCHMAGE);
cm.sendOk("There you go. Hope you enjoy it.");
cm.dispose();
} else if (status == 121) {
cm.changeJob(MapleJob.IL_ARCHMAGE);
cm.sendOk("There you go. Hope you enjoy it.");
cm.dispose();
} else if (status == 124) {
cm.changeJob(MapleJob.BISHOP);
cm.sendOk("There you go. Hope you enjoy it.");
cm.dispose();
} else if (status == 127) {
cm.changeJob(MapleJob.HERO);
cm.sendOk("There you go. Hope you enjoy it.");
cm.dispose();
} else if (status == 130) {
cm.changeJob(MapleJob.PALADIN);
cm.sendOk("There you go. Hope you enjoy it.");
cm.dispose();
} else if (status == 133) {
cm.changeJob(MapleJob.DARKKNIGHT);
cm.sendOk("There you go. Hope you enjoy it.");
cm.dispose();
} else if (status == 134) {
cm.changeJob(MapleJob.BUCCANEER);
cm.sendOk("There you go. Hope you enjoy it.");
cm.dispose();
} else if (status == 135) {
cm.changeJob(MapleJob.CORSAIR);
cm.sendOk("There you go. Hope you enjoy it.");
cm.dispose();
} else if (status == 151) {
if (cm.c.getPlayer().getInt() >= 20) {
cm.changeJob(net.sf.odinms.client.MapleJob.MAGICIAN);
cm.sendOk("There you go. Hope you enjoy it. See you around in the future maybe :)");
cm.dispose();
} else {
cm.sendOk("You did not meet the minimum requirement of #r20 INT#k.");
cm.dispose();
}
} else if (status == 154) {
cm.sendSimple("Which would you like to be? #b\r\n#L0#Warrior#l\r\n#L1#Magician#l\r\n#L2#Bowman#l\r\n#L3#Thief#l\r\n#L4#Pirate#l#k");
} else if (status == 155) {
if (selection == 0) {
jobName = "Warrior";
job = net.sf.odinms.client.MapleJob.WARRIOR;
}
if (selection == 1) {
jobName = "Magician";
job = net.sf.odinms.client.MapleJob.MAGICIAN;
}
if (selection == 2) {
jobName = "Bowman";
job = net.sf.odinms.client.MapleJob.BOWMAN;
}
if (selection == 3) {
jobName = "Thief";
job = net.sf.odinms.client.MapleJob.THIEF;
}
if (selection == 4) {
jobName = "Pirate";
job = net.sf.odinms.client.MapleJob.PIRATE;
}
cm.sendYesNo("Do you want to become a #r" + jobName + "#k?");
} else if (status == 156) {
if (job == net.sf.odinms.client.MapleJob.WARRIOR && cm.c.getPlayer().getStr() < 35) {
cm.sendOk("You did not meet the minimum requirement of #r35 STR#k.");
cm.dispose();
} else if (job == net.sf.odinms.client.MapleJob.MAGICIAN && cm.c.getPlayer().getInt() < 20) {
cm.sendOk("You did not meet the minimum requirement of #r20 INT#k.");
cm.dispose();
} else if (job == net.sf.odinms.client.MapleJob.BOWMAN && cm.c.getPlayer().getDex() < 25) {
cm.sendOk("You did not meet the minimum requirement of #r25 DEX#k.");
cm.dispose();
} else if (job == net.sf.odinms.client.MapleJob.THIEF && cm.c.getPlayer().getDex() < 25) {
cm.sendOk("You did not meet the minimum requirement of #r25 DEX#k.");
cm.dispose();
} else if (job == net.sf.odinms.client.MapleJob.PIRATE && cm.c.getPlayer().getDex() < 20) {
cm.sendOk("You did not meet the minimum requirement of #r20 DEX#k.");
cm.dispose();
} else {
cm.changeJob(job);
cm.sendOk("There you go. Hope you enjoy it. See you around in the future maybe :)");
cm.dispose();
}
} else if (status == 161) {
cm.warp(910000000, 0);
cm.sendOk("Good luck then. Talk to the massive stone on the 2nd floor to start the quest.");
cm.dispose();
} else {
cm.dispose();
}
}
}
If we look at the code, the two most important sections are:
Code:
cm.warp(910000000, 0);
cm.sendOk("Good luck then. Talk to the massive stone on the 2nd floor to start the quest.");
cm.dispose();
and
Code:
} else if (cm.getLevel() >= 200) {
cm.sendYesNo("Ahh... It is good to see you again. Your skills have finally reached the maximum of its potential. So, with all my heart, I congratulate you, great hero. \r\n\r\nYou have been through a long and challenging road, and in so doing, have become immensely strong. It is now that I would recommend you do the rebirth quest in [LOCATION]. By rebirthing, you will become a level 1 #bBeginner#k again, but all your abilities, skills, items and mesos, will remain as they are. However, you will only be able to keep the skills that you have placed in your #bkey setting#k. \r\n\r\nSo, tell me, do you wish to be #rreborn#k?");
The most important aspect of the first part is the cm.warp(910000000, 0); function. It'll warp the players to MapID. Hopefully you know this. By default, I put it as FM.
The second part is basically the descritpion. So where you place your NPC.
You can also place the NPC into Shanks, to really make life easier.
So cm.openNpc(ID); If you added that in NPCConversationManager.java