Fixed CreateCopy being broken on HexenArmor

This commit is contained in:
Boondorl 2024-11-08 17:34:26 -05:00 committed by Ricardo Luís Vaz Silva
parent 220200d836
commit 04cdbd1898

View file

@ -468,11 +468,12 @@ class HexenArmor : Armor
override Inventory CreateCopy (Actor other)
{
// Like BasicArmor, HexenArmor is used in the inventory but not the map.
// health is the slot this armor occupies.
// Unlike BasicArmor, Hexen's armor pieces directly inherit from this class.
// Health is the slot this armor occupies.
// Amount is the quantity to give (0 = normal max).
let copy = HexenArmor(Spawn(GetHexenArmorClass()));
copy.AddArmorToSlot (health, Amount);
let copy = HexenArmor(Spawn(GetClass()));
copy.Health = Health;
copy.Amount = Amount;
GoAwayAndDie ();
return copy;
}