mirror of
https://github.com/EQEmu/Server.git
synced 2026-05-31 04:56:20 +00:00
Fix mod rods
This commit is contained in:
@@ -1223,6 +1223,8 @@ bool Mob::SpellEffect(Mob* caster, uint16 spell_id, float partial)
|
|||||||
int charges;
|
int charges;
|
||||||
if (item->Stackable)
|
if (item->Stackable)
|
||||||
charges = (spell.formula[i] > item->StackSize) ? item->StackSize : spell.formula[i];
|
charges = (spell.formula[i] > item->StackSize) ? item->StackSize : spell.formula[i];
|
||||||
|
else if (item->MaxCharges) // mod rods etc
|
||||||
|
charges = (spell.formula[i] > item->MaxCharges) ? item->MaxCharges : spell.formula[i];
|
||||||
else
|
else
|
||||||
charges = 1;
|
charges = 1;
|
||||||
|
|
||||||
@@ -1263,6 +1265,8 @@ bool Mob::SpellEffect(Mob* caster, uint16 spell_id, float partial)
|
|||||||
|
|
||||||
if (item->Stackable)
|
if (item->Stackable)
|
||||||
charges = (spell.formula[i] > item->StackSize) ? item->StackSize : spell.formula[i];
|
charges = (spell.formula[i] > item->StackSize) ? item->StackSize : spell.formula[i];
|
||||||
|
else if (item->MaxCharges) // mod rods, not sure if there are actual examples of this for IntoBag
|
||||||
|
charges = (spell.formula[i] > item->MaxCharges) ? item->MaxCharges : spell.formula[i];
|
||||||
else
|
else
|
||||||
charges = 1;
|
charges = 1;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user