Updated DB2 structs

This commit is contained in:
hondacrx
2018-02-26 13:13:54 -05:00
parent 0a3dfaba37
commit 82dca6de94
61 changed files with 2639 additions and 2517 deletions
+3 -3
View File
@@ -3046,7 +3046,7 @@ namespace Game.Entities
float bubble0 = 0.031f;
//speed collect rest bonus in offline, in logout, in tavern, city (section/in hour)
float bubble1 = 0.125f;
float bubble = result.Read<byte>(32) > 0
float bubble = result.Read<byte>(33) > 0
? bubble1 * WorldConfig.GetFloatValue(WorldCfg.RateRestOfflineInTavernOrCity)
: bubble0 * WorldConfig.GetFloatValue(WorldCfg.RateRestOfflineInWilderness);
@@ -3125,7 +3125,7 @@ namespace Game.Entities
stmt.AddValue(index++, transLowGUID);
StringBuilder ss = new StringBuilder();
for (byte i = 0; i < PlayerConst.TaxiMaskSize; ++i)
for (int i = 0; i < PlayerConst.TaxiMaskSize; ++i)
ss.Append(m_taxi.m_taximask[i] + " ");
stmt.AddValue(index++, ss.ToString());
@@ -3274,7 +3274,7 @@ namespace Game.Entities
stmt.AddValue(index++, transLowGUID);
StringBuilder ss = new StringBuilder();
for (byte i = 0; i < PlayerConst.TaxiMaskSize; ++i)
for (int i = 0; i < PlayerConst.TaxiMaskSize; ++i)
ss.Append(m_taxi.m_taximask[i] + " ");
stmt.AddValue(index++, ss.ToString());
+3 -3
View File
@@ -1476,7 +1476,7 @@ namespace Game.Entities
if (Convert.ToBoolean(proto.GetFlags2() & ItemFlags2.FactionAlliance) && GetTeam() != Team.Alliance)
return InventoryResult.CantEquipEver;
if ((proto.GetAllowableClass() & getClassMask()) == 0 || (proto.GetAllowableRace() & getRaceMask()) == 0)
if ((proto.GetAllowableClass() & getClassMask()) == 0 || (proto.GetAllowableRace() & (long)getRaceMask()) == 0)
return InventoryResult.CantEquipEver;
if (proto.GetRequiredSkill() != 0)
@@ -3323,7 +3323,7 @@ namespace Game.Entities
return InventoryResult.ItemNotFound;
// Used by group, function GroupLoot, to know if a prototype can be used by a player
if ((proto.GetAllowableClass() & getClassMask()) == 0 || (proto.GetAllowableRace() & getRaceMask()) == 0)
if ((proto.GetAllowableClass() & getClassMask()) == 0 || (proto.GetAllowableRace() & (long)getRaceMask()) == 0)
return InventoryResult.CantEquipEver;
if (proto.GetRequiredSpell() != 0 && !HasSpell(proto.GetRequiredSpell()))
@@ -6320,7 +6320,7 @@ namespace Game.Entities
switch (loot_type)
{
case LootType.Disenchanting:
loot.FillLoot(item.GetTemplate().DisenchantID, LootStorage.Disenchant, this, true);
loot.FillLoot(item.GetDisenchantLoot(this).Id, LootStorage.Disenchant, this, true);
break;
case LootType.Prospecting:
loot.FillLoot(item.GetEntry(), LootStorage.Prospecting, this, true);
+1 -1
View File
@@ -1382,7 +1382,7 @@ namespace Game.Entities
if (reqraces == -1)
return true;
if ((reqraces & getRaceMask()) == 0)
if ((reqraces & (long)getRaceMask()) == 0)
{
if (msg)
{
+1 -1
View File
@@ -1573,7 +1573,7 @@ namespace Game.Entities
void LearnSkillRewardedSpells(uint skillId, uint skillValue)
{
uint raceMask = getRaceMask();
ulong raceMask = getRaceMask();
uint classMask = getClassMask();
foreach (var ability in CliDB.SkillLineAbilityStorage.Values)
{
+2 -2
View File
@@ -5330,7 +5330,7 @@ namespace Game.Entities
if (pet)
pet.SynchronizeLevelWithOwner();
MailLevelReward mailReward = Global.ObjectMgr.GetMailLevelReward(level, getRaceMask());
MailLevelReward mailReward = Global.ObjectMgr.GetMailLevelReward(level, (uint)getRaceMask());
if (mailReward != null)
{
//- TODO: Poor design of mail system
@@ -7057,7 +7057,7 @@ namespace Game.Entities
}
public bool IsSpellFitByClassAndRace(uint spell_id)
{
uint racemask = getRaceMask();
ulong racemask = getRaceMask();
uint classmask = getClassMask();
var bounds = Global.SpellMgr.GetSkillLineAbilityMapBounds(spell_id);