Maplers' Well-known Battlegrounds
Fulfilled merge of Drago's AriantPQ PR #438 into the source! Adjusted MCPQ map limits predicted within battlefield's map info node. Added max number-of-players option when creating a AriantPQ lobby. Added party creation check when trying to create one inside the AriantPQ rooms. Adjusted several AriantPQ mechanics, in order to either improve the existent features or make those that was still unavailable work seamlessly (score update, ariant batlle points).
This commit is contained in:
@@ -72,6 +72,25 @@ public class MapleDataTool {
|
||||
return getInt(data);
|
||||
}
|
||||
}
|
||||
|
||||
public static int getIntConvert(MapleData data, int def) {
|
||||
if (data == null) {
|
||||
return def;
|
||||
}
|
||||
if (data.getType() == MapleDataType.STRING) {
|
||||
String dd = getString(data);
|
||||
if (dd.endsWith("%")) {
|
||||
dd = dd.substring(0, dd.length() - 1);
|
||||
}
|
||||
try {
|
||||
return Integer.parseInt(dd);
|
||||
} catch (NumberFormatException nfe) {
|
||||
return def;
|
||||
}
|
||||
} else {
|
||||
return getInt(data, def);
|
||||
}
|
||||
}
|
||||
|
||||
public static int getIntConvert(String path, MapleData data) {
|
||||
MapleData d = data.getChildByPath(path);
|
||||
|
||||
Reference in New Issue
Block a user