@@ -276,7 +276,7 @@ namespace Game
|
||||
_itemsByGuid[item.GetGUID()] = item;
|
||||
}
|
||||
|
||||
public bool RemoveAItem(ObjectGuid guid, bool deleteItem = false)
|
||||
public bool RemoveAItem(ObjectGuid guid, bool deleteItem = false, SQLTransaction trans = null)
|
||||
{
|
||||
var item = _itemsByGuid.LookupByKey(guid);
|
||||
if (item == null)
|
||||
@@ -285,7 +285,7 @@ namespace Game
|
||||
if (deleteItem)
|
||||
{
|
||||
item.FSetState(ItemUpdateState.Removed);
|
||||
item.SaveToDB(null);
|
||||
item.SaveToDB(trans);
|
||||
}
|
||||
|
||||
_itemsByGuid.Remove(guid);
|
||||
@@ -1418,7 +1418,7 @@ namespace Game
|
||||
{
|
||||
// bidder doesn't exist, delete the item
|
||||
foreach (Item item in auction.Items)
|
||||
Global.AuctionHouseMgr.RemoveAItem(item.GetGUID(), true);
|
||||
Global.AuctionHouseMgr.RemoveAItem(item.GetGUID(), true, trans);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1470,7 +1470,7 @@ namespace Game
|
||||
{
|
||||
// owner doesn't exist, delete the item
|
||||
foreach (Item item in auction.Items)
|
||||
Global.AuctionHouseMgr.RemoveAItem(item.GetGUID(), true);
|
||||
Global.AuctionHouseMgr.RemoveAItem(item.GetGUID(), true, trans);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -2426,7 +2426,7 @@ namespace Game.Entities
|
||||
victimResistance = Math.Max(victimResistance, 0.0f);
|
||||
|
||||
// level-based resistance does not apply to binary spells, and cannot be overcome by spell penetration
|
||||
if (!spellInfo.HasAttribute(SpellCustomAttributes.BinarySpell))
|
||||
if (spellInfo == null || !spellInfo.HasAttribute(SpellCustomAttributes.BinarySpell))
|
||||
victimResistance += Math.Max((victim.GetLevelForTarget(this) - GetLevelForTarget(victim)) * 5.0f, 0.0f);
|
||||
|
||||
uint bossLevel = 83;
|
||||
|
||||
@@ -97,7 +97,7 @@ namespace Game.Movement
|
||||
}
|
||||
|
||||
if (targetMoved)
|
||||
SetTargetLocation(owner, targetMoved);
|
||||
SetTargetLocation(owner, true);
|
||||
else if (_speedChanged)
|
||||
SetTargetLocation(owner, false);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user