In MapleIsland.cpp
Add anywhere:
Add:
Above:
In NPCs.h
Add:
Below:
In NPCsScripts.h
Add where it belongs:
Text is taken from the official GMS Shanks NPC on Maple Island.
Credits: Firon, xSLaYaHx for the bolded text.
Add anywhere:
Code:
void NPCsScripts::npc_22000(NPC* npc){
int state = npc->getState();
if(state == 0){
npc->addText("Take this ship and you'll head off to a bigger continent.#e For 150 mesos#n, I'll take you to #bVictoria Island#k");
npc->addText(". The thing is, once you leave this place, you can't ever come back. What do you think? Do you want to go to Victoria Island?");
npc->sendYesNo();
}
else if(state == 1){
if(npc->getSelected() == YES){
npc->addText("Bored of this place? Here... Give me 150 mesos first...");
npc->sendNext();
}
else{
npc->addText("Hmm... I guess you still have things to do here?");
npc->sendOK();
}
}
else if(state == 2){
if(npc->getSelected() == YES){
if(npc->getLevel() > 6){
if(npc->getMesos() > 149){
npc->giveMesos(-150);
npc->addText("Awesome! #e150 mesos#n accepted! Alright, off to Victoria Island!");
npc->sendNext();
}
else{
npc->addText("What? You're telling me you wanted to go without any money? You're one weirdo...");
npc->setSelected(NO);
npc->sendOK();
}
}
else{
npc->addText("Let's see... I don't think you are strong enough. You'll have to be at least #bLevel 7#k ");
npc->addText("to go to Victoria Island.");
npc->setSelected(NO);
npc->sendOK();
}
}
else{
npc->end();
}
}
else if(state == 3){
if(npc->getSelected() == YES){
npc->teleport(104000000);
}
npc->end();
}
}
Add:
Code:
char NPC::getLevel(){
return player->getLevel();
}
Above:
Code:
void NPC::setStyle(int id){
if(id/10000 == 0){
player->setSkin((char)id);
}
else if(id/10000 == 2){
player->setEyes(id);
}
else if(id/10000 == 3){
player->setHair(id);
}
InventoryPacket::updatePlayer(player);
}
In NPCs.h
Add:
Code:
char getLevel();
Below:
Code:
void giveEXP(int exp);
In NPCsScripts.h
Add where it belongs:
Code:
case 22000: npc_22000(npc); break;
Code:
static void npc_22000(NPC* npc);
Text is taken from the official GMS Shanks NPC on Maple Island.
Credits: Firon, xSLaYaHx for the bolded text.