cleanup: use primitive type instead of wrapper type
This commit is contained in:
@@ -873,7 +873,7 @@ public class Server {
|
||||
}
|
||||
|
||||
try {
|
||||
Integer worldCount = Math.min(GameConstants.WORLD_NAMES.length, YamlConfig.config.server.WORLDS);
|
||||
int worldCount = Math.min(GameConstants.WORLD_NAMES.length, YamlConfig.config.server.WORLDS);
|
||||
|
||||
for (int i = 0; i < worldCount; i++) {
|
||||
initWorld();
|
||||
|
||||
@@ -258,7 +258,7 @@ public abstract class AbstractDealDamageHandler extends AbstractMaplePacketHandl
|
||||
eachd += Integer.MAX_VALUE;
|
||||
|
||||
if (pickpocket.getEffect(picklv).makeChanceResult()) {
|
||||
final Integer eachdf;
|
||||
final int eachdf;
|
||||
if(eachd < 0)
|
||||
eachdf = eachd + Integer.MAX_VALUE;
|
||||
else
|
||||
@@ -280,7 +280,7 @@ public abstract class AbstractDealDamageHandler extends AbstractMaplePacketHandl
|
||||
MapleMonsterInformationProvider mi = MapleMonsterInformationProvider.getInstance();
|
||||
List<Integer> dropPool = mi.retrieveDropPool(monster.getId());
|
||||
if(!dropPool.isEmpty()) {
|
||||
Integer rndPool = (int) Math.floor(Math.random() * dropPool.get(dropPool.size() - 1));
|
||||
int rndPool = (int) Math.floor(Math.random() * dropPool.get(dropPool.size() - 1));
|
||||
|
||||
int i = 0;
|
||||
while(rndPool >= dropPool.get(i)) i++;
|
||||
|
||||
@@ -1445,7 +1445,7 @@ public class World {
|
||||
MapleCharacter chr = this.getPlayerStorage().getCharacterById(dp.getKey() / 4);
|
||||
if(chr == null || !chr.isLoggedinWorld()) continue;
|
||||
|
||||
Integer dpVal = dp.getValue() + 1;
|
||||
int dpVal = dp.getValue() + 1;
|
||||
if(dpVal == YamlConfig.config.server.PET_EXHAUST_COUNT) {
|
||||
chr.runFullnessSchedule(dp.getKey() % 4);
|
||||
dpVal = 0;
|
||||
|
||||
Reference in New Issue
Block a user