Instant sell NPC + new features
Donation Box NPC sells instantly items from inventory. Minor patches.
This commit is contained in:
@@ -11,9 +11,14 @@ function action(mode, type, selection) {
|
||||
return;
|
||||
}
|
||||
if (cm.c.getPlayer().getMapId() == 103000100 || cm.c.getPlayer().getMapId() == 600010001){
|
||||
if(cm.getMeso() >= 5000){
|
||||
var item = 4031711 + parseInt(cm.c.getPlayer().getMapId() / 300000000);
|
||||
|
||||
if(!cm.canHold(item)) {
|
||||
cm.sendNext("You don't have a etc. slot available.");
|
||||
}
|
||||
else if(cm.getMeso() >= 5000){
|
||||
cm.gainMeso(-5000);
|
||||
cm.gainItem(4031711 + parseInt(cm.c.getPlayer().getMapId() / 300000000), 1);
|
||||
cm.gainItem(item, 1);
|
||||
cm.sendNext("There you go.");
|
||||
}else
|
||||
cm.sendNext("You don't have enough mesos.");
|
||||
|
||||
Reference in New Issue
Block a user