Core/Refactor: Part 5
This commit is contained in:
@@ -4023,7 +4023,7 @@ namespace Game.Entities
|
||||
if (keepDays == 0)
|
||||
return;
|
||||
|
||||
Player.DeleteOldCharacters(keepDays);
|
||||
DeleteOldCharacters(keepDays);
|
||||
}
|
||||
|
||||
public static void DeleteOldCharacters(int keepDays)
|
||||
|
||||
@@ -6276,7 +6276,7 @@ namespace Game.Entities
|
||||
if (groupRules)
|
||||
group.UpdateLooterGuid(go, true);
|
||||
|
||||
loot.FillLoot(lootid, LootManager.Gameobject, this, !groupRules, false, go.GetLootMode());
|
||||
loot.FillLoot(lootid, LootStorage.Gameobject, this, !groupRules, false, go.GetLootMode());
|
||||
|
||||
// get next RR player (for next loot)
|
||||
if (groupRules)
|
||||
|
||||
@@ -1973,7 +1973,7 @@ namespace Game.Entities
|
||||
PlayerSpell spell = m_spells.LookupByKey(spellId);
|
||||
|
||||
bool disabled = (spell != null) ? spell.Disabled : false;
|
||||
bool active = disabled ? spell.Active : true;
|
||||
bool active = !disabled || spell.Active;
|
||||
|
||||
bool learning = AddSpell(spellId, active, true, dependent, false, false, fromSkill);
|
||||
|
||||
@@ -2525,7 +2525,7 @@ namespace Game.Entities
|
||||
|
||||
// needs to be when spell is already learned, to prevent infinite recursion crashes
|
||||
if (Global.DB2Mgr.GetMount(spellId) != null)
|
||||
GetSession().GetCollectionMgr().AddMount(spellId, MountStatusFlags.None, false, IsInWorld ? false : true);
|
||||
GetSession().GetCollectionMgr().AddMount(spellId, MountStatusFlags.None, false, !IsInWorld);
|
||||
|
||||
// need to add Battle pets automatically into pet journal
|
||||
foreach (BattlePetSpeciesRecord entry in CliDB.BattlePetSpeciesStorage.Values)
|
||||
|
||||
@@ -5204,6 +5204,9 @@ namespace Game.Entities
|
||||
}
|
||||
|
||||
//Target
|
||||
// Used for serverside target changes, does not apply to players
|
||||
public override void SetTarget(ObjectGuid guid) { }
|
||||
|
||||
public void SetSelection(ObjectGuid guid)
|
||||
{
|
||||
SetGuidValue(UnitFields.Target, guid);
|
||||
|
||||
@@ -1403,7 +1403,7 @@ namespace Game.Entities
|
||||
loot.clear();
|
||||
uint lootid = creature.GetCreatureTemplate().LootId;
|
||||
if (lootid != 0)
|
||||
loot.FillLoot(lootid, LootManager.Creature, looter, false, false, creature.GetLootMode());
|
||||
loot.FillLoot(lootid, LootStorage.Creature, looter, false, false, creature.GetLootMode());
|
||||
|
||||
loot.generateMoneyLoot(creature.GetCreatureTemplate().MinGold, creature.GetCreatureTemplate().MaxGold);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user