Augmentation improvements/fixes.
This commit is contained in:
@ -84,6 +84,7 @@ public class AugmentationData
|
||||
private final List<List<Integer>> _blueSkills = new ArrayList<>();
|
||||
private final List<List<Integer>> _purpleSkills = new ArrayList<>();
|
||||
private final List<List<Integer>> _redSkills = new ArrayList<>();
|
||||
private final List<List<Integer>> _yellowSkills = new ArrayList<>();
|
||||
|
||||
private final List<AugmentationChance> _augmentationChances = new ArrayList<>();
|
||||
private final List<augmentationChanceAcc> _augmentationChancesAcc = new ArrayList<>();
|
||||
@ -97,6 +98,7 @@ public class AugmentationData
|
||||
_blueSkills.add(new ArrayList<>());
|
||||
_purpleSkills.add(new ArrayList<>());
|
||||
_redSkills.add(new ArrayList<>());
|
||||
_yellowSkills.add(new ArrayList<>());
|
||||
}
|
||||
|
||||
load();
|
||||
@ -275,12 +277,7 @@ public class AugmentationData
|
||||
type = attrs.getNamedItem("val").getNodeValue();
|
||||
}
|
||||
}
|
||||
if (skillId == 0)
|
||||
{
|
||||
badAugmantData++;
|
||||
continue;
|
||||
}
|
||||
else if (skillLvL == 0)
|
||||
if ((skillId == 0) || (skillLvL == 0))
|
||||
{
|
||||
badAugmantData++;
|
||||
continue;
|
||||
@ -656,21 +653,30 @@ public class AugmentationData
|
||||
switch (lifeStoneGrade)
|
||||
{
|
||||
case AbstractRefinePacket.GRADE_NONE:
|
||||
{
|
||||
gradeChance = Config.RETAIL_LIKE_AUGMENTATION_NG_CHANCE;
|
||||
break;
|
||||
}
|
||||
case AbstractRefinePacket.GRADE_MID:
|
||||
{
|
||||
gradeChance = Config.RETAIL_LIKE_AUGMENTATION_MID_CHANCE;
|
||||
break;
|
||||
}
|
||||
case AbstractRefinePacket.GRADE_HIGH:
|
||||
{
|
||||
gradeChance = Config.RETAIL_LIKE_AUGMENTATION_HIGH_CHANCE;
|
||||
break;
|
||||
}
|
||||
case AbstractRefinePacket.GRADE_TOP:
|
||||
{
|
||||
gradeChance = Config.RETAIL_LIKE_AUGMENTATION_TOP_CHANCE;
|
||||
break;
|
||||
}
|
||||
default:
|
||||
{
|
||||
gradeChance = Config.RETAIL_LIKE_AUGMENTATION_NG_CHANCE;
|
||||
}
|
||||
}
|
||||
|
||||
int c = Rnd.get(100);
|
||||
if (c < gradeChance[0])
|
||||
{
|
||||
@ -702,7 +708,7 @@ public class AugmentationData
|
||||
{
|
||||
if (s > r)
|
||||
{
|
||||
s -= (ac.getAugmentChance() * 100);
|
||||
s -= ac.getAugmentChance() * 100;
|
||||
stat34 = ac.getAugmentId();
|
||||
}
|
||||
}
|
||||
|
@ -106,13 +106,14 @@ public final class DocumentItem extends DocumentBase implements IGameXmlReader
|
||||
final int itemId = Integer.parseInt(n.getAttributes().getNamedItem("id").getNodeValue());
|
||||
final String className = n.getAttributes().getNamedItem("type").getNodeValue();
|
||||
final String itemName = n.getAttributes().getNamedItem("name").getNodeValue();
|
||||
|
||||
final String additionalName = n.getAttributes().getNamedItem("additionalName") != null ? n.getAttributes().getNamedItem("additionalName").getNodeValue() : null;
|
||||
_currentItem.id = itemId;
|
||||
_currentItem.name = itemName;
|
||||
_currentItem.type = className;
|
||||
_currentItem.set = new StatsSet();
|
||||
_currentItem.set.set("item_id", itemId);
|
||||
_currentItem.set.set("name", itemName);
|
||||
_currentItem.set.set("additionalName", additionalName);
|
||||
|
||||
final Node first = n.getFirstChild();
|
||||
for (n = first; n != null; n = n.getNextSibling())
|
||||
|
@ -126,17 +126,17 @@ public class ItemInfo
|
||||
// Get the action to do clientside
|
||||
switch (item.getLastChange())
|
||||
{
|
||||
case (L2ItemInstance.ADDED):
|
||||
case L2ItemInstance.ADDED:
|
||||
{
|
||||
_change = 1;
|
||||
break;
|
||||
}
|
||||
case (L2ItemInstance.MODIFIED):
|
||||
case L2ItemInstance.MODIFIED:
|
||||
{
|
||||
_change = 2;
|
||||
break;
|
||||
}
|
||||
case (L2ItemInstance.REMOVED):
|
||||
case L2ItemInstance.REMOVED:
|
||||
{
|
||||
_change = 3;
|
||||
break;
|
||||
@ -183,8 +183,8 @@ public class ItemInfo
|
||||
// Get the enchant level of the L2ItemInstance
|
||||
_enchant = item.getEnchant();
|
||||
|
||||
// Get the augmentation boni
|
||||
_augmentation = 0;
|
||||
// Get the augmentation bonus
|
||||
_augmentation = item.getAugmentId();
|
||||
|
||||
// Get the quantity of the L2ItemInstance
|
||||
_count = item.getCount();
|
||||
@ -332,6 +332,16 @@ public class ItemInfo
|
||||
return _augmentation;
|
||||
}
|
||||
|
||||
public int get1stAugmentationId()
|
||||
{
|
||||
return 0x0000FFFF & getAugmentationBonus();
|
||||
}
|
||||
|
||||
public int get2ndAugmentationId()
|
||||
{
|
||||
return getAugmentationBonus() >> 16;
|
||||
}
|
||||
|
||||
public long getCount()
|
||||
{
|
||||
return _count;
|
||||
|
@ -123,6 +123,7 @@ public abstract class L2Item extends ListenersContainer implements IIdentifiable
|
||||
private int _itemId;
|
||||
private int _displayId;
|
||||
private String _name;
|
||||
private String _additionalName;
|
||||
private String _icon;
|
||||
private int _weight;
|
||||
private boolean _stackable;
|
||||
@ -190,6 +191,7 @@ public abstract class L2Item extends ListenersContainer implements IIdentifiable
|
||||
_itemId = set.getInt("item_id");
|
||||
_displayId = set.getInt("displayId", _itemId);
|
||||
_name = set.getString("name");
|
||||
_additionalName = set.getString("additionalName", null);
|
||||
_icon = set.getString("icon", null);
|
||||
_weight = set.getInt("weight", 0);
|
||||
_materialType = set.getEnum("material", MaterialType.class, MaterialType.STEEL);
|
||||
@ -377,12 +379,18 @@ public abstract class L2Item extends ListenersContainer implements IIdentifiable
|
||||
{
|
||||
case S80:
|
||||
case S84:
|
||||
{
|
||||
return CrystalType.S;
|
||||
}
|
||||
case R95:
|
||||
case R99:
|
||||
{
|
||||
return CrystalType.R;
|
||||
}
|
||||
default:
|
||||
{
|
||||
return _crystalType;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -440,6 +448,14 @@ public abstract class L2Item extends ListenersContainer implements IIdentifiable
|
||||
return _name;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the item's additional name.
|
||||
*/
|
||||
public String getAdditionalName()
|
||||
{
|
||||
return _additionalName;
|
||||
}
|
||||
|
||||
public Collection<AttributeHolder> getAttributes()
|
||||
{
|
||||
return _elementals != null ? _elementals.values() : null;
|
||||
@ -601,17 +617,17 @@ public abstract class L2Item extends ListenersContainer implements IIdentifiable
|
||||
|
||||
public boolean isPotion()
|
||||
{
|
||||
return (getItemType() == EtcItemType.POTION);
|
||||
return getItemType() == EtcItemType.POTION;
|
||||
}
|
||||
|
||||
public boolean isElixir()
|
||||
{
|
||||
return (getItemType() == EtcItemType.ELIXIR);
|
||||
return getItemType() == EtcItemType.ELIXIR;
|
||||
}
|
||||
|
||||
public boolean isScroll()
|
||||
{
|
||||
return (getItemType() == EtcItemType.SCROLL);
|
||||
return getItemType() == EtcItemType.SCROLL;
|
||||
}
|
||||
|
||||
public List<FuncTemplate> getFunctionTemplates()
|
||||
|
@ -41,10 +41,33 @@ public abstract class AbstractRefinePacket implements IClientIncomingPacket
|
||||
public static final int GRADE_HIGH = 2;
|
||||
public static final int GRADE_TOP = 3;
|
||||
public static final int GRADE_ACC = 4; // Accessory LS
|
||||
public static final int GRADE_FORGOTTEN = 5; // Forgotten
|
||||
|
||||
protected static final int GEMSTONE_D = 2130;
|
||||
protected static final int GEMSTONE_C = 2131;
|
||||
protected static final int GEMSTONE_B = 2132;
|
||||
protected static final int[] GEMSTONE_D = new int[]
|
||||
{
|
||||
2130
|
||||
};
|
||||
protected static final int[] GEMSTONE_C = new int[]
|
||||
{
|
||||
2131,
|
||||
36719
|
||||
};
|
||||
protected static final int[] GEMSTONE_B = new int[]
|
||||
{
|
||||
2132
|
||||
};
|
||||
protected static final int[] GEMSTONE_A = new int[]
|
||||
{
|
||||
2133
|
||||
};
|
||||
protected static final int[] GEMSTONE_S = new int[]
|
||||
{
|
||||
2134
|
||||
};
|
||||
protected static final int[] GEMSTONE_R = new int[]
|
||||
{
|
||||
19440
|
||||
};
|
||||
|
||||
private static final Map<Integer, LifeStone> _lifeStones = new HashMap<>();
|
||||
|
||||
@ -66,7 +89,9 @@ public abstract class AbstractRefinePacket implements IClientIncomingPacket
|
||||
80,
|
||||
82,
|
||||
84,
|
||||
85
|
||||
85,
|
||||
95,
|
||||
99
|
||||
};
|
||||
private final int _grade;
|
||||
private final int _level;
|
||||
@ -96,6 +121,8 @@ public abstract class AbstractRefinePacket implements IClientIncomingPacket
|
||||
static
|
||||
{
|
||||
// itemId, (LS grade, LS level)
|
||||
_lifeStones.put(36718, new LifeStone(GRADE_NONE, 0));
|
||||
|
||||
_lifeStones.put(8723, new LifeStone(GRADE_NONE, 0));
|
||||
_lifeStones.put(8724, new LifeStone(GRADE_NONE, 1));
|
||||
_lifeStones.put(8725, new LifeStone(GRADE_NONE, 2));
|
||||
@ -195,6 +222,39 @@ public abstract class AbstractRefinePacket implements IClientIncomingPacket
|
||||
_lifeStones.put(16166, new LifeStone(GRADE_HIGH, 13));
|
||||
_lifeStones.put(16167, new LifeStone(GRADE_TOP, 13));
|
||||
_lifeStones.put(16178, new LifeStone(GRADE_ACC, 13));
|
||||
|
||||
_lifeStones.put(18563, new LifeStone(GRADE_NONE, 13));
|
||||
_lifeStones.put(18564, new LifeStone(GRADE_MID, 13));
|
||||
_lifeStones.put(18565, new LifeStone(GRADE_HIGH, 13));
|
||||
_lifeStones.put(18566, new LifeStone(GRADE_TOP, 13));
|
||||
_lifeStones.put(18567, new LifeStone(GRADE_FORGOTTEN, 13));
|
||||
_lifeStones.put(19166, new LifeStone(GRADE_ACC, 13));
|
||||
|
||||
_lifeStones.put(18568, new LifeStone(GRADE_NONE, 14));
|
||||
_lifeStones.put(18569, new LifeStone(GRADE_MID, 14));
|
||||
_lifeStones.put(18570, new LifeStone(GRADE_HIGH, 14));
|
||||
_lifeStones.put(18571, new LifeStone(GRADE_TOP, 14));
|
||||
_lifeStones.put(18572, new LifeStone(GRADE_FORGOTTEN, 14));
|
||||
_lifeStones.put(19167, new LifeStone(GRADE_ACC, 14));
|
||||
|
||||
_lifeStones.put(18573, new LifeStone(GRADE_NONE, 15));
|
||||
_lifeStones.put(18574, new LifeStone(GRADE_MID, 15));
|
||||
_lifeStones.put(18575, new LifeStone(GRADE_HIGH, 15));
|
||||
_lifeStones.put(18576, new LifeStone(GRADE_TOP, 15));
|
||||
_lifeStones.put(18577, new LifeStone(GRADE_FORGOTTEN, 15));
|
||||
_lifeStones.put(19168, new LifeStone(GRADE_ACC, 15));
|
||||
|
||||
_lifeStones.put(36731, new LifeStone(GRADE_NONE, 13));
|
||||
|
||||
_lifeStones.put(45929, new LifeStone(GRADE_NONE, 0));
|
||||
_lifeStones.put(45930, new LifeStone(GRADE_MID, 13));
|
||||
_lifeStones.put(45931, new LifeStone(GRADE_HIGH, 14));
|
||||
_lifeStones.put(45932, new LifeStone(GRADE_TOP, 15));
|
||||
|
||||
_lifeStones.put(45933, new LifeStone(GRADE_ACC, 0));
|
||||
_lifeStones.put(45934, new LifeStone(GRADE_ACC, 13));
|
||||
_lifeStones.put(45935, new LifeStone(GRADE_ACC, 14));
|
||||
_lifeStones.put(45936, new LifeStone(GRADE_ACC, 15));
|
||||
}
|
||||
|
||||
protected static LifeStone getLifeStone(int itemId)
|
||||
@ -232,10 +292,19 @@ public abstract class AbstractRefinePacket implements IClientIncomingPacket
|
||||
final LifeStone ls = _lifeStones.get(refinerItem.getId());
|
||||
|
||||
// Check for item id
|
||||
if (getGemStoneId(grade) != gemStones.getId())
|
||||
boolean gemIdFinded = false;
|
||||
for (int id : getGemStoneId(grade))
|
||||
{
|
||||
if (gemStones.getId() == id)
|
||||
{
|
||||
gemIdFinded = true;
|
||||
}
|
||||
}
|
||||
if (!gemIdFinded)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
// Count must be greater or equal of required number
|
||||
if (getGemStoneCount(grade, ls.getGrade()) > gemStones.getCount())
|
||||
{
|
||||
@ -350,9 +419,13 @@ public abstract class AbstractRefinePacket implements IClientIncomingPacket
|
||||
{
|
||||
case INVENTORY:
|
||||
case PAPERDOLL:
|
||||
{
|
||||
break;
|
||||
}
|
||||
default:
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
if (item.getItem() instanceof L2Weapon)
|
||||
@ -361,9 +434,13 @@ public abstract class AbstractRefinePacket implements IClientIncomingPacket
|
||||
{
|
||||
case NONE:
|
||||
case FISHINGROD:
|
||||
{
|
||||
return false;
|
||||
}
|
||||
default:
|
||||
{
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (item.getItem() instanceof L2Armor)
|
||||
@ -374,9 +451,13 @@ public abstract class AbstractRefinePacket implements IClientIncomingPacket
|
||||
case L2Item.SLOT_LR_FINGER:
|
||||
case L2Item.SLOT_LR_EAR:
|
||||
case L2Item.SLOT_NECK:
|
||||
{
|
||||
break;
|
||||
}
|
||||
default:
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
@ -446,21 +527,35 @@ public abstract class AbstractRefinePacket implements IClientIncomingPacket
|
||||
* @param itemGrade
|
||||
* @return GemStone itemId based on item grade
|
||||
*/
|
||||
protected static int getGemStoneId(CrystalType itemGrade)
|
||||
protected static int[] getGemStoneId(CrystalType itemGrade)
|
||||
{
|
||||
switch (itemGrade)
|
||||
{
|
||||
case C:
|
||||
case B:
|
||||
return GEMSTONE_D;
|
||||
case A:
|
||||
case S:
|
||||
return GEMSTONE_C;
|
||||
case S80:
|
||||
case S84:
|
||||
{
|
||||
return GEMSTONE_B;
|
||||
}
|
||||
case R:
|
||||
{
|
||||
return GEMSTONE_A;
|
||||
}
|
||||
case R95:
|
||||
{
|
||||
return GEMSTONE_S;
|
||||
}
|
||||
case R99:
|
||||
{
|
||||
return GEMSTONE_R;
|
||||
}
|
||||
default:
|
||||
return 0;
|
||||
{
|
||||
return null;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -475,40 +570,67 @@ public abstract class AbstractRefinePacket implements IClientIncomingPacket
|
||||
switch (lifeStoneGrade)
|
||||
{
|
||||
case GRADE_ACC:
|
||||
{
|
||||
switch (itemGrade)
|
||||
{
|
||||
case C:
|
||||
return 200;
|
||||
case B:
|
||||
return 300;
|
||||
case A:
|
||||
return 200;
|
||||
case S:
|
||||
return 250;
|
||||
case S80:
|
||||
return 360;
|
||||
case S84:
|
||||
return 480;
|
||||
default:
|
||||
return 0;
|
||||
}
|
||||
default:
|
||||
switch (itemGrade)
|
||||
{
|
||||
case C:
|
||||
return 20;
|
||||
case B:
|
||||
{
|
||||
return 125;
|
||||
}
|
||||
case R:
|
||||
{
|
||||
return 30;
|
||||
}
|
||||
case R95:
|
||||
{
|
||||
return 18;
|
||||
}
|
||||
case R99:
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
default:
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
default:
|
||||
{
|
||||
switch (itemGrade)
|
||||
{
|
||||
case C:
|
||||
case B:
|
||||
case A:
|
||||
return 20;
|
||||
case S:
|
||||
return 25;
|
||||
case S80:
|
||||
case S84:
|
||||
return 36;
|
||||
{
|
||||
return 25;
|
||||
}
|
||||
case R:
|
||||
{
|
||||
return 20;
|
||||
}
|
||||
case R95:
|
||||
{
|
||||
return 12;
|
||||
}
|
||||
case R99:
|
||||
{
|
||||
return 5;
|
||||
}
|
||||
default:
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -76,6 +76,7 @@ public final class RequestConfirmCancelItem implements IClientIncomingPacket
|
||||
switch (item.getItem().getCrystalType())
|
||||
{
|
||||
case C:
|
||||
{
|
||||
if (item.getCrystalCount() < 1720)
|
||||
{
|
||||
price = 95000;
|
||||
@ -89,7 +90,9 @@ public final class RequestConfirmCancelItem implements IClientIncomingPacket
|
||||
price = 210000;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case B:
|
||||
{
|
||||
if (item.getCrystalCount() < 1746)
|
||||
{
|
||||
price = 240000;
|
||||
@ -99,7 +102,9 @@ public final class RequestConfirmCancelItem implements IClientIncomingPacket
|
||||
price = 270000;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case A:
|
||||
{
|
||||
if (item.getCrystalCount() < 2160)
|
||||
{
|
||||
price = 330000;
|
||||
@ -113,17 +118,59 @@ public final class RequestConfirmCancelItem implements IClientIncomingPacket
|
||||
price = 420000;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case S:
|
||||
price = 480000;
|
||||
{
|
||||
if (item.getCrystalCount() <= 2052)
|
||||
{
|
||||
price = 480000;
|
||||
}
|
||||
else
|
||||
{
|
||||
price = 920000;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case S80:
|
||||
case S84:
|
||||
price = 920000;
|
||||
{
|
||||
if (item.getCrystalCount() <= 4965)
|
||||
{
|
||||
price = 920000;
|
||||
}
|
||||
else if (item.getCrystalCount() <= 7050)
|
||||
{
|
||||
price = 2800000;
|
||||
}
|
||||
else if (item.getCrystalCount() <= 8233)
|
||||
{
|
||||
price = 2800000;
|
||||
}
|
||||
else
|
||||
{
|
||||
price = 3200000;
|
||||
}
|
||||
break;
|
||||
// TODO: S84 TOP price 3.2M
|
||||
// any other item type is not augmentable
|
||||
}
|
||||
case R:
|
||||
{
|
||||
price = 3492800;
|
||||
break;
|
||||
}
|
||||
case R95:
|
||||
{
|
||||
price = 2943200;
|
||||
break;
|
||||
}
|
||||
case R99:
|
||||
{
|
||||
price = 6485800;
|
||||
break;
|
||||
}
|
||||
default:
|
||||
{
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
activeChar.sendPacket(new ExPutItemResultForVariationCancel(item, price));
|
||||
|
@ -71,9 +71,18 @@ public class RequestConfirmRefinerItem extends AbstractRefinePacket
|
||||
final int refinerItemId = refinerItem.getItem().getId();
|
||||
final CrystalType grade = targetItem.getItem().getCrystalType();
|
||||
final LifeStone ls = getLifeStone(refinerItemId);
|
||||
final int gemStoneId = getGemStoneId(grade);
|
||||
final int gemStoneCount = getGemStoneCount(grade, ls.getGrade());
|
||||
|
||||
activeChar.sendPacket(new ExPutIntensiveResultForVariationMake(_refinerItemObjId, refinerItemId, gemStoneId, gemStoneCount));
|
||||
int gemStoneId = 0;
|
||||
if (getGemStoneId(grade) != null)
|
||||
{
|
||||
for (int id : getGemStoneId(grade))
|
||||
{
|
||||
if (activeChar.getInventory().getAllItemsByItemId(id) != null)
|
||||
{
|
||||
gemStoneId = id;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
activeChar.sendPacket(new ExPutIntensiveResultForVariationMake(_refinerItemObjId, refinerItemId, gemStoneId, getGemStoneCount(grade, ls.getGrade())));
|
||||
}
|
||||
}
|
||||
|
@ -131,6 +131,7 @@ public class RequestExRemoveItemAttribute implements IClientIncomingPacket
|
||||
switch (item.getItem().getCrystalType())
|
||||
{
|
||||
case S:
|
||||
{
|
||||
if (item.getItem() instanceof L2Weapon)
|
||||
{
|
||||
_price = 50000;
|
||||
@ -140,7 +141,9 @@ public class RequestExRemoveItemAttribute implements IClientIncomingPacket
|
||||
_price = 40000;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case S80:
|
||||
{
|
||||
if (item.getItem() instanceof L2Weapon)
|
||||
{
|
||||
_price = 100000;
|
||||
@ -150,7 +153,9 @@ public class RequestExRemoveItemAttribute implements IClientIncomingPacket
|
||||
_price = 80000;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case S84:
|
||||
{
|
||||
if (item.getItem() instanceof L2Weapon)
|
||||
{
|
||||
_price = 200000;
|
||||
@ -160,6 +165,43 @@ public class RequestExRemoveItemAttribute implements IClientIncomingPacket
|
||||
_price = 160000;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case R:
|
||||
{
|
||||
if (item.getItem() instanceof L2Weapon)
|
||||
{
|
||||
_price = 400000;
|
||||
}
|
||||
else
|
||||
{
|
||||
_price = 320000;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case R95:
|
||||
{
|
||||
if (item.getItem() instanceof L2Weapon)
|
||||
{
|
||||
_price = 800000;
|
||||
}
|
||||
else
|
||||
{
|
||||
_price = 640000;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case R99:
|
||||
{
|
||||
if (item.getItem() instanceof L2Weapon)
|
||||
{
|
||||
_price = 3200000;
|
||||
}
|
||||
else
|
||||
{
|
||||
_price = 2560000;
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
return _price;
|
||||
|
@ -74,6 +74,7 @@ public final class RequestRefineCancel implements IClientIncomingPacket
|
||||
switch (targetItem.getItem().getCrystalType())
|
||||
{
|
||||
case C:
|
||||
{
|
||||
if (targetItem.getCrystalCount() < 1720)
|
||||
{
|
||||
price = 95000;
|
||||
@ -87,7 +88,9 @@ public final class RequestRefineCancel implements IClientIncomingPacket
|
||||
price = 210000;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case B:
|
||||
{
|
||||
if (targetItem.getCrystalCount() < 1746)
|
||||
{
|
||||
price = 240000;
|
||||
@ -97,7 +100,9 @@ public final class RequestRefineCancel implements IClientIncomingPacket
|
||||
price = 270000;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case A:
|
||||
{
|
||||
if (targetItem.getCrystalCount() < 2160)
|
||||
{
|
||||
price = 330000;
|
||||
@ -111,17 +116,39 @@ public final class RequestRefineCancel implements IClientIncomingPacket
|
||||
price = 420000;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case S:
|
||||
{
|
||||
price = 480000;
|
||||
break;
|
||||
}
|
||||
case S80:
|
||||
case S84:
|
||||
{
|
||||
price = 920000;
|
||||
break;
|
||||
}
|
||||
case R:
|
||||
{
|
||||
price = 1560000;
|
||||
break;
|
||||
}
|
||||
case R95:
|
||||
{
|
||||
price = 5400000;
|
||||
break;
|
||||
}
|
||||
case R99:
|
||||
{
|
||||
price = 14160000;
|
||||
break;
|
||||
}
|
||||
// any other item type is not augmentable
|
||||
default:
|
||||
{
|
||||
client.sendPacket(new ExVariationCancelResult(0));
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
// try to reduce the players adena
|
||||
|
@ -98,7 +98,8 @@ public abstract class AbstractItemPacket extends AbstractMaskPacket<ItemListType
|
||||
packet.writeC(0x01); // GOD Item enabled = 1 disabled (red) = 0
|
||||
if (containsMask(mask, ItemListType.AUGMENT_BONUS))
|
||||
{
|
||||
packet.writeQ(item.getAugmentationBonus());
|
||||
packet.writeD(item.get1stAugmentationId());
|
||||
packet.writeD(item.get2ndAugmentationId());
|
||||
}
|
||||
if (containsMask(mask, ItemListType.ELEMENTAL_ATTRIBUTE))
|
||||
{
|
||||
|
Reference in New Issue
Block a user