Commands overhaul + Selective loot + Antimulticlient Coordinator
Completely overhauled commands layout, each command splitted in Java classes. Optimized "ranks" command, no more calling the DB to get ranking info. Implemented a mechanic where mobs only spawns loots that are visible/collectable by the player's party. Implemented a server flag which sets whether explorers, cygnus and legends are allowed to share the cash shop inventory or not. Implemented support for dynamic server rates at bootup. Rates can now be assigned at the configuration.ini file. Devised the anti-multiclient login coordinator feature. Besides multiclient attempts by the same machine, it also prevents unauthorized login attempts into an account. Fixed PQ instances being forcefully closed even when party leader reassignment upon logout is available. Fixed mob statis not concurrently protected.
This commit is contained in:
@@ -77,8 +77,12 @@ import tools.StringUtil;
|
||||
*
|
||||
*/
|
||||
public class MapleItemInformationProvider {
|
||||
|
||||
private static MapleItemInformationProvider instance = null;
|
||||
private final static MapleItemInformationProvider instance = new MapleItemInformationProvider();
|
||||
|
||||
public static MapleItemInformationProvider getInstance() {
|
||||
return instance;
|
||||
}
|
||||
|
||||
protected MapleDataProvider itemData;
|
||||
protected MapleDataProvider equipData;
|
||||
protected MapleDataProvider stringData;
|
||||
@@ -142,13 +146,6 @@ public class MapleItemInformationProvider {
|
||||
isPartyQuestItemCache.put(0, false);
|
||||
}
|
||||
|
||||
public static MapleItemInformationProvider getInstance() {
|
||||
if (instance == null) {
|
||||
instance = new MapleItemInformationProvider();
|
||||
}
|
||||
return instance;
|
||||
}
|
||||
|
||||
// public MapleInventoryType getInventoryType(int itemId) {
|
||||
// if (inventoryTypeCache.containsKey(itemId)) {
|
||||
// return inventoryTypeCache.get(itemId);
|
||||
@@ -1224,14 +1221,19 @@ public class MapleItemInformationProvider {
|
||||
if (dropRestrictionCache.containsKey(itemId)) {
|
||||
return dropRestrictionCache.get(itemId);
|
||||
}
|
||||
MapleData data = getItemData(itemId);
|
||||
boolean bRestricted = MapleDataTool.getIntConvert("info/tradeBlock", data, 0) == 1;
|
||||
if (!bRestricted) {
|
||||
bRestricted = MapleDataTool.getIntConvert("info/accountSharable", data, 0) == 1;
|
||||
}
|
||||
if (!bRestricted) {
|
||||
bRestricted = MapleDataTool.getIntConvert("info/quest", data, 0) == 1;
|
||||
|
||||
boolean bRestricted = false;
|
||||
if(itemId != 0) {
|
||||
MapleData data = getItemData(itemId);
|
||||
bRestricted = MapleDataTool.getIntConvert("info/tradeBlock", data, 0) == 1;
|
||||
if (!bRestricted) {
|
||||
bRestricted = MapleDataTool.getIntConvert("info/accountSharable", data, 0) == 1;
|
||||
}
|
||||
if (!bRestricted) {
|
||||
bRestricted = MapleDataTool.getIntConvert("info/quest", data, 0) == 1;
|
||||
}
|
||||
}
|
||||
|
||||
dropRestrictionCache.put(itemId, bRestricted);
|
||||
return bRestricted;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user