forked from MagicBane/Server
combat_health_full used from json
This commit is contained in:
@@ -86,7 +86,7 @@ public class RepairMsgHandler extends AbstractClientMsgHandler {
|
||||
//make sure item is damaged and not destroyed
|
||||
|
||||
short dur = (short) toRepair.combat_health_current;
|
||||
short max = (short) toRepair.template.item_health_full;
|
||||
short max = (short) toRepair.template.combat_health_full;
|
||||
|
||||
//account for durability modifications
|
||||
|
||||
|
||||
@@ -108,7 +108,7 @@ public class VendorSellMsgHandler extends AbstractClientMsgHandler {
|
||||
cost = sell.template.item_value;
|
||||
|
||||
//apply damaged value reduction
|
||||
float damagedModifier = sell.combat_health_current / sell.template.item_health_full;
|
||||
float damagedModifier = sell.combat_health_current / sell.template.combat_health_full;
|
||||
cost *= damagedModifier;
|
||||
|
||||
float bargain = player.getBargain();
|
||||
|
||||
Reference in New Issue
Block a user