Turn item id magic numbers into constants
This commit is contained in:
@@ -24,6 +24,7 @@ import client.Job;
|
||||
import client.creator.CharacterFactory;
|
||||
import client.creator.CharacterFactoryRecipe;
|
||||
import client.inventory.InventoryType;
|
||||
import constants.id.ItemId;
|
||||
|
||||
/**
|
||||
* @author RonanLana
|
||||
@@ -32,7 +33,7 @@ public class BeginnerCreator extends CharacterFactory {
|
||||
|
||||
private static CharacterFactoryRecipe createRecipe(Job job, int level, int map, int top, int bottom, int shoes, int weapon) {
|
||||
CharacterFactoryRecipe recipe = new CharacterFactoryRecipe(job, level, map, top, bottom, shoes, weapon);
|
||||
giveItem(recipe, 4161001, 1, InventoryType.ETC);
|
||||
giveItem(recipe, ItemId.BEGINNERS_GUIDE, 1, InventoryType.ETC);
|
||||
return recipe;
|
||||
}
|
||||
|
||||
|
||||
@@ -24,6 +24,7 @@ import client.Job;
|
||||
import client.creator.CharacterFactory;
|
||||
import client.creator.CharacterFactoryRecipe;
|
||||
import client.inventory.InventoryType;
|
||||
import constants.id.ItemId;
|
||||
|
||||
/**
|
||||
* @author RonanLana
|
||||
@@ -32,7 +33,7 @@ public class LegendCreator extends CharacterFactory {
|
||||
|
||||
private static CharacterFactoryRecipe createRecipe(Job job, int level, int map, int top, int bottom, int shoes, int weapon) {
|
||||
CharacterFactoryRecipe recipe = new CharacterFactoryRecipe(job, level, map, top, bottom, shoes, weapon);
|
||||
giveItem(recipe, 4161048, 1, InventoryType.ETC);
|
||||
giveItem(recipe, ItemId.LEGENDS_GUIDE, 1, InventoryType.ETC);
|
||||
return recipe;
|
||||
}
|
||||
|
||||
|
||||
@@ -24,6 +24,7 @@ import client.Job;
|
||||
import client.creator.CharacterFactory;
|
||||
import client.creator.CharacterFactoryRecipe;
|
||||
import client.inventory.InventoryType;
|
||||
import constants.id.ItemId;
|
||||
|
||||
/**
|
||||
* @author RonanLana
|
||||
@@ -32,7 +33,7 @@ public class NoblesseCreator extends CharacterFactory {
|
||||
|
||||
private static CharacterFactoryRecipe createRecipe(Job job, int level, int map, int top, int bottom, int shoes, int weapon) {
|
||||
CharacterFactoryRecipe recipe = new CharacterFactoryRecipe(job, level, map, top, bottom, shoes, weapon);
|
||||
giveItem(recipe, 4161047, 1, InventoryType.ETC);
|
||||
giveItem(recipe, ItemId.NOBLESSE_GUIDE, 1, InventoryType.ETC);
|
||||
return recipe;
|
||||
}
|
||||
|
||||
|
||||
@@ -25,14 +25,16 @@ import client.creator.CharacterFactory;
|
||||
import client.creator.CharacterFactoryRecipe;
|
||||
import client.inventory.InventoryType;
|
||||
import client.inventory.Item;
|
||||
import constants.id.ItemId;
|
||||
import server.ItemInformationProvider;
|
||||
|
||||
/**
|
||||
* @author RonanLana
|
||||
*/
|
||||
public class BowmanCreator extends CharacterFactory {
|
||||
private static final int[] equips = {1040067, 1041054, 1060056, 1061050, 1072081};
|
||||
private static final int[] weapons = {1452005, 1462000};
|
||||
private static final int[] equips = {ItemId.GREEN_HUNTERS_ARMOR, ItemId.GREEN_HUNTRESS_ARMOR,
|
||||
ItemId.GREEN_HUNTERS_PANTS, ItemId.GREEN_HUNTRESS_PANTS, ItemId.GREEN_HUNTER_BOOTS};
|
||||
private static final int[] weapons = {ItemId.RYDEN, ItemId.MOUNTAIN_CROSSBOW};
|
||||
private static final int[] startingHpMp = {797, 404};
|
||||
|
||||
private static CharacterFactoryRecipe createRecipe(Job job, int level, int map, int top, int bottom, int shoes, int weapon) {
|
||||
@@ -52,9 +54,9 @@ public class BowmanCreator extends CharacterFactory {
|
||||
giveEquipment(recipe, ii, weapons[i]);
|
||||
}
|
||||
|
||||
giveItem(recipe, 2000002, 100, InventoryType.USE);
|
||||
giveItem(recipe, 2000003, 100, InventoryType.USE);
|
||||
giveItem(recipe, 3010000, 1, InventoryType.SETUP);
|
||||
giveItem(recipe, ItemId.WHITE_POTION, 100, InventoryType.USE);
|
||||
giveItem(recipe, ItemId.BLUE_POTION, 100, InventoryType.USE);
|
||||
giveItem(recipe, ItemId.RELAXER, 1, InventoryType.SETUP);
|
||||
|
||||
return recipe;
|
||||
}
|
||||
|
||||
@@ -27,6 +27,7 @@ import client.creator.CharacterFactory;
|
||||
import client.creator.CharacterFactoryRecipe;
|
||||
import client.inventory.InventoryType;
|
||||
import client.inventory.Item;
|
||||
import constants.id.ItemId;
|
||||
import constants.skills.Magician;
|
||||
import server.ItemInformationProvider;
|
||||
|
||||
@@ -34,8 +35,8 @@ import server.ItemInformationProvider;
|
||||
* @author RonanLana
|
||||
*/
|
||||
public class MagicianCreator extends CharacterFactory {
|
||||
private static final int[] equips = {0, 1041041, 0, 1061034, 1072075};
|
||||
private static final int[] weapons = {1372003, 1382017};
|
||||
private static final int[] equips = {0, ItemId.PURPLE_FAIRY_TOP, 0, ItemId.PURPLE_FAIRY_SKIRT, ItemId.RED_MAGICSHOES};
|
||||
private static final int[] weapons = {ItemId.MITHRIL_WAND, ItemId.CIRCLE_WINDED_STAFF};
|
||||
private static final int[] startingHpMp = {405, 729};
|
||||
private static final int[] mpGain = {0, 40, 80, 118, 156, 194, 230, 266, 302, 336, 370};
|
||||
|
||||
@@ -53,16 +54,16 @@ public class MagicianCreator extends CharacterFactory {
|
||||
recipe.setMeso(100000);
|
||||
|
||||
if (gender == 0) {
|
||||
giveEquipment(recipe, ii, 1050003);
|
||||
giveEquipment(recipe, ii, ItemId.BLUE_WIZARD_ROBE);
|
||||
}
|
||||
|
||||
for (int i = 1; i < weapons.length; i++) {
|
||||
giveEquipment(recipe, ii, weapons[i]);
|
||||
}
|
||||
|
||||
giveItem(recipe, 2000001, 100, InventoryType.USE);
|
||||
giveItem(recipe, 2000006, 100, InventoryType.USE);
|
||||
giveItem(recipe, 3010000, 1, InventoryType.SETUP);
|
||||
giveItem(recipe, ItemId.ORANGE_POTION, 100, InventoryType.USE);
|
||||
giveItem(recipe, ItemId.MANA_ELIXIR, 100, InventoryType.USE);
|
||||
giveItem(recipe, ItemId.RELAXER, 1, InventoryType.SETUP);
|
||||
|
||||
if (improveSp > 0) {
|
||||
improveSp += 5;
|
||||
|
||||
@@ -25,14 +25,15 @@ import client.creator.CharacterFactory;
|
||||
import client.creator.CharacterFactoryRecipe;
|
||||
import client.inventory.InventoryType;
|
||||
import client.inventory.Item;
|
||||
import constants.id.ItemId;
|
||||
import server.ItemInformationProvider;
|
||||
|
||||
/**
|
||||
* @author RonanLana
|
||||
*/
|
||||
public class PirateCreator extends CharacterFactory {
|
||||
private static final int[] equips = {0, 0, 0, 0, 1072294};
|
||||
private static final int[] weapons = {1482004, 1492004};
|
||||
private static final int[] equips = {0, 0, 0, 0, ItemId.BROWN_PAULIE_BOOTS};
|
||||
private static final int[] weapons = {ItemId.PRIME_HANDS, ItemId.COLD_MIND};
|
||||
private static final int[] startingHpMp = {846, 503};
|
||||
|
||||
private static CharacterFactoryRecipe createRecipe(Job job, int level, int map, int top, int bottom, int shoes, int weapon) {
|
||||
@@ -48,17 +49,17 @@ public class PirateCreator extends CharacterFactory {
|
||||
|
||||
recipe.setMeso(100000);
|
||||
|
||||
giveEquipment(recipe, ii, 1052107);
|
||||
giveEquipment(recipe, ii, ItemId.BROWN_POLLARD);
|
||||
|
||||
for (int i = 1; i < weapons.length; i++) {
|
||||
giveEquipment(recipe, ii, weapons[i]);
|
||||
}
|
||||
|
||||
giveItem(recipe, 2330000, 800, InventoryType.USE);
|
||||
giveItem(recipe, ItemId.BULLET, 800, InventoryType.USE);
|
||||
|
||||
giveItem(recipe, 2000002, 100, InventoryType.USE);
|
||||
giveItem(recipe, 2000003, 100, InventoryType.USE);
|
||||
giveItem(recipe, 3010000, 1, InventoryType.SETUP);
|
||||
giveItem(recipe, ItemId.WHITE_POTION, 100, InventoryType.USE);
|
||||
giveItem(recipe, ItemId.BLUE_POTION, 100, InventoryType.USE);
|
||||
giveItem(recipe, ItemId.RELAXER, 1, InventoryType.SETUP);
|
||||
|
||||
return recipe;
|
||||
}
|
||||
|
||||
@@ -25,14 +25,16 @@ import client.creator.CharacterFactory;
|
||||
import client.creator.CharacterFactoryRecipe;
|
||||
import client.inventory.InventoryType;
|
||||
import client.inventory.Item;
|
||||
import constants.id.ItemId;
|
||||
import server.ItemInformationProvider;
|
||||
|
||||
/**
|
||||
* @author RonanLana
|
||||
*/
|
||||
public class ThiefCreator extends CharacterFactory {
|
||||
private static final int[] equips = {1040057, 1041047, 1060043, 1061043, 1072032};
|
||||
private static final int[] weapons = {1472008, 1332012};
|
||||
private static final int[] equips = {ItemId.DARK_BROWN_STEALER, ItemId.RED_STEAL, ItemId.DARK_BROWN_STEALER_PANTS,
|
||||
ItemId.RED_STEAL_PANTS, ItemId.BRONZE_CHAIN_BOOTS};
|
||||
private static final int[] weapons = {ItemId.STEEL_GUARDS, ItemId.REEF_CLAW};
|
||||
private static final int[] startingHpMp = {794, 407};
|
||||
|
||||
private static CharacterFactoryRecipe createRecipe(Job job, int level, int map, int top, int bottom, int shoes, int weapon) {
|
||||
@@ -52,11 +54,11 @@ public class ThiefCreator extends CharacterFactory {
|
||||
giveEquipment(recipe, ii, weapons[i]);
|
||||
}
|
||||
|
||||
giveItem(recipe, 2070000, 500, InventoryType.USE);
|
||||
giveItem(recipe, ItemId.SUBI_THROWING_STARS, 500, InventoryType.USE);
|
||||
|
||||
giveItem(recipe, 2000002, 100, InventoryType.USE);
|
||||
giveItem(recipe, 2000003, 100, InventoryType.USE);
|
||||
giveItem(recipe, 3010000, 1, InventoryType.SETUP);
|
||||
giveItem(recipe, ItemId.WHITE_POTION, 100, InventoryType.USE);
|
||||
giveItem(recipe, ItemId.BLUE_POTION, 100, InventoryType.USE);
|
||||
giveItem(recipe, ItemId.RELAXER, 1, InventoryType.SETUP);
|
||||
|
||||
return recipe;
|
||||
}
|
||||
|
||||
@@ -27,6 +27,7 @@ import client.creator.CharacterFactory;
|
||||
import client.creator.CharacterFactoryRecipe;
|
||||
import client.inventory.InventoryType;
|
||||
import client.inventory.Item;
|
||||
import constants.id.ItemId;
|
||||
import constants.skills.Warrior;
|
||||
import server.ItemInformationProvider;
|
||||
|
||||
@@ -34,8 +35,8 @@ import server.ItemInformationProvider;
|
||||
* @author RonanLana
|
||||
*/
|
||||
public class WarriorCreator extends CharacterFactory {
|
||||
private static final int[] equips = {1040021, 0, 1060016, 0, 1072039};
|
||||
private static final int[] weapons = {1302008, 1442001, 1422001, 1312005};
|
||||
private static final int[] equips = {ItemId.RED_HWARANG_SHIRT, 0, ItemId.BLACK_MARTIAL_ARTS_PANTS, 0, ItemId.MITHRIL_BATTLE_GRIEVES};
|
||||
private static final int[] weapons = {ItemId.GLADIUS, ItemId.MITHRIL_POLE_ARM, ItemId.MITHRIL_MAUL, ItemId.FIREMANS_AXE};
|
||||
private static final int[] startingHpMp = {905, 208};
|
||||
private static final int[] hpGain = {0, 72, 144, 212, 280, 348, 412, 476, 540, 600, 660};
|
||||
|
||||
@@ -53,7 +54,7 @@ public class WarriorCreator extends CharacterFactory {
|
||||
recipe.setMeso(100000);
|
||||
|
||||
if (gender == 1) {
|
||||
giveEquipment(recipe, ii, 1051010);
|
||||
giveEquipment(recipe, ii, ItemId.DARK_ENGRIT);
|
||||
}
|
||||
|
||||
for (int i = 1; i < weapons.length; i++) {
|
||||
@@ -75,9 +76,9 @@ public class WarriorCreator extends CharacterFactory {
|
||||
}
|
||||
}
|
||||
|
||||
giveItem(recipe, 2000002, 100, InventoryType.USE);
|
||||
giveItem(recipe, 2000003, 100, InventoryType.USE);
|
||||
giveItem(recipe, 3010000, 1, InventoryType.SETUP);
|
||||
giveItem(recipe, ItemId.WHITE_POTION, 100, InventoryType.USE);
|
||||
giveItem(recipe, ItemId.BLUE_POTION, 100, InventoryType.USE);
|
||||
giveItem(recipe, ItemId.RELAXER, 1, InventoryType.SETUP);
|
||||
|
||||
return recipe;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user