Meso patch + Swift Dmg Reflect buff + GPQ Rewards + Starting Q. items

Fixed several RNG pool issues within several handler classes.
Fixed an overflow issue with mesos, that would cause players to lose all amount on inventory.
Changed the code coupon SQL structure. Now nxcode_items.quantity is to be specified for both nx values and item quantities alike, instead of the use of "quantity" only when items are being provided.
Bob Snail now appears each 4 hours, instead of any time.
Removed duplicate command Warpto. Warpto merged with Reach command.
Fixed solo expeditions being disposed for "lack of personnel" after changing maps (normal limitations should not apply when USE_ENABLE_SOLO_EXPEDITIONS is enabled).
Fixed mobskills "Weapon/Magic Reflect" taking too long to show the active status over the mob's head.
Fixed a case with clean slate scroll not working as expected.
Improved reward contents for the GPQ.
Fixed loot manager not acting properly when verifying one-of-a-kind contents.
Implemented quest item requirement checkups to start quests. Items required to start a quest now should appear if the player did not start it yet, e.g.: SOS letter.
Fixed an issue with server message/boss HPbar switch interaction that would not work the moment after a player changed channels/entered Cash Shop.
Improved Victoria Island worldmap design, at the Kerning subway area.
This commit is contained in:
ronancpl
2018-12-05 02:52:14 -02:00
parent 0910dc2428
commit a17c233693
53 changed files with 625 additions and 343 deletions

View File

@@ -1583,7 +1583,6 @@ public class MapleCharacter extends AbstractMapleCharacterObject {
this.unregisterChairBuff();
this.clearBanishPlayerData();
this.closePlayerInteractions();
this.resetPlayerAggro();
client.announce(warpPacket);
map.removePlayer(this);
@@ -2001,7 +2000,7 @@ public class MapleCharacter extends AbstractMapleCharacterObject {
public static boolean deleteCharFromDB(MapleCharacter player, int senderAccId) {
int cid = player.getId();
if(!Server.getInstance().haveCharacterEntry(senderAccId, cid)) {
if(!Server.getInstance().haveCharacterEntry(senderAccId, cid)) { // thanks zera (EpiphanyMS) for pointing a critical exploit with non-authored character deletion request
return false;
}
@@ -2979,7 +2978,7 @@ public class MapleCharacter extends AbstractMapleCharacterObject {
long nextMeso;
petLock.lock();
try {
nextMeso = meso.get() + gain;
nextMeso = (long) meso.get() + gain; // thanks Thora for pointing integer overflow here
if (nextMeso > Integer.MAX_VALUE) {
gain -= (nextMeso - Integer.MAX_VALUE);
} else if (nextMeso < 0) {
@@ -4933,6 +4932,7 @@ public class MapleCharacter extends AbstractMapleCharacterObject {
closePlayerMessenger();
client.closePlayerScriptInteractions();
resetPlayerAggro();
}
public void closeNpcShop() {
@@ -5140,10 +5140,17 @@ public class MapleCharacter extends AbstractMapleCharacterObject {
public boolean needQuestItem(int questid, int itemid) {
if (questid <= 0) return true; //For non quest items :3
if (this.getQuestStatus(questid) != 1) return false;
MapleQuest quest = MapleQuest.getInstance(questid);
return getInventory(ItemConstants.getInventoryType(itemid)).countById(itemid) < quest.getItemAmountNeeded(itemid);
int amountNeeded, questStatus = this.getQuestStatus(questid);
if (questStatus == 0) {
amountNeeded = MapleQuest.getInstance(questid).getStartItemAmountNeeded(itemid);
} else if (questStatus != 1) {
return false;
} else {
amountNeeded = MapleQuest.getInstance(questid).getCompleteItemAmountNeeded(itemid);
}
return amountNeeded > 0 && getInventory(ItemConstants.getInventoryType(itemid)).countById(itemid) < amountNeeded;
}
public int getRank() {