cleanup: use primitive type instead of wrapper type

This commit is contained in:
P0nk
2021-04-08 17:45:50 +02:00
parent 202f2d8bc5
commit a5b42b8a43
10 changed files with 20 additions and 23 deletions

View File

@@ -41,7 +41,7 @@ public class CheckDmgCommand extends Command {
int maxBase = victim.calculateMaxBaseDamage(victim.getTotalWatk());
Integer watkBuff = victim.getBuffedValue(MapleBuffStat.WATK);
Integer matkBuff = victim.getBuffedValue(MapleBuffStat.MATK);
Integer blessing = victim.getSkillLevel(10000000 * player.getJobType() + 12);
int blessing = victim.getSkillLevel(10000000 * player.getJobType() + 12);
if (watkBuff == null) watkBuff = 0;
if (matkBuff == null) matkBuff = 0;

View File

@@ -25,15 +25,16 @@ import client.MapleClient;
import config.YamlConfig;
import constants.game.ExpTable;
import constants.inventory.ItemConstants;
import java.util.HashMap;
import java.util.LinkedList;
import java.util.List;
import java.util.Map;
import server.MapleItemInformationProvider;
import tools.MaplePacketCreator;
import tools.Pair;
import tools.Randomizer;
import java.util.HashMap;
import java.util.LinkedList;
import java.util.List;
import java.util.Map;
public class Equip extends Item {
public static enum ScrollResult {
@@ -383,7 +384,7 @@ public class Equip extends Item {
public Pair<String, Pair<Boolean, Boolean>> gainStats(List<Pair<StatUpgrade, Integer>> stats) {
boolean gotSlot = false, gotVicious = false;
String lvupStr = "";
Integer statUp, maxStat = YamlConfig.config.server.MAX_EQUIPMNT_STAT;
int statUp, maxStat = YamlConfig.config.server.MAX_EQUIPMNT_STAT;
for (Pair<StatUpgrade, Integer> stat : stats) {
switch (stat.getLeft()) {
case incDEX: