Core/Items
* Updated ItemTemplate structure to 4.x * Calculate armor, damage and disenchant loot from dbc files TODO: Use dbc disenchant ids in disenchant_loot_template
This commit is contained in:
1 parent
8d3bc5e8b9
commit
e8c3a3ac9c
24 files changed
+788
-807
No files matched your search
@@ -2715,7 +2715,7 @@ float Unit::GetUnitBlockChance() const
|
||||
if (player->CanBlock())
|
||||
{
|
||||
Item* tmpitem = player->GetUseableItemByPos(INVENTORY_SLOT_BAG_0, EQUIPMENT_SLOT_OFFHAND);
|
||||
if (tmpitem && !tmpitem->IsBroken() && tmpitem->GetTemplate()->Block)
|
||||
if (tmpitem && !tmpitem->IsBroken())
|
||||
return GetFloatValue(PLAYER_BLOCK_PERCENTAGE);
|
||||
}
|
||||
// is player but has no block ability or no not broken shield equipped
|
||||
@@ -8674,7 +8674,7 @@ bool Unit::HandleProcTriggerSpell(Unit* victim, uint32 damage, AuraEffect* trigg
|
||||
|
||||
ItemTemplate const* weapon = item->GetTemplate();
|
||||
|
||||
float weaponDPS = weapon->getDPS();
|
||||
float weaponDPS = weapon->DPS;
|
||||
float attackPower = GetTotalAttackPowerValue(BASE_ATTACK) / 14.0f;
|
||||
float weaponSpeed = float(weapon->Delay) / 1000.0f;
|
||||
basepoints0 = int32((weaponDPS + attackPower) * weaponSpeed);
|
||||
|
||||
Reference in new issue
Block a user