Skip to content
Browse files

Core: Fix warnings

  • Loading branch information...
1 parent ac45363 commit 7daf69f20c2c7516a382a06aba78315fe6ce4204 @Elron103 committed Mar 24, 2012
View
2 src/server/game/Entities/Pet/Pet.cpp
@@ -912,7 +912,7 @@ bool Guardian::InitStatsForLevel(uint8 petlevel)
SetCreateHealth(40*petlevel);
SetCreateMana(28 + 10*petlevel);
}
- SetBonusDamage(m_owner->SpellBaseDamageBonus(SPELL_SCHOOL_MASK_FIRE) * 0.5f);
+ SetBonusDamage(int32(m_owner->SpellBaseDamageBonus(SPELL_SCHOOL_MASK_FIRE) * 0.5f));
SetBaseWeaponDamage(BASE_ATTACK, MINDAMAGE, float(petlevel * 4 - petlevel));
SetBaseWeaponDamage(BASE_ATTACK, MAXDAMAGE, float(petlevel * 4 + petlevel));
break;
View
10 src/server/game/Entities/Player/Player.cpp
@@ -18507,7 +18507,7 @@ void Player::SaveToDB(bool create /*=false*/)
outDebugValues();
PreparedStatement* stmt = NULL;
- uint16 index = 0;
+ uint8 index = 0;
if (create)
{
@@ -18546,12 +18546,12 @@ void Player::SaveToDB(bool create /*=false*/)
//save, far from tavern/city
//save, but in tavern/city
stmt->setUInt32(index++, m_resetTalentsCost);
- stmt->setUInt32(index++, m_resetTalentsTime);
+ stmt->setUInt32(index++, uint32(m_resetTalentsTime));
stmt->setUInt16(index++, (uint16)m_ExtraFlags);
stmt->setUInt8(index++, m_stableSlots);
stmt->setUInt16(index++, (uint16)m_atLoginFlags);
stmt->setUInt16(index++, GetZoneId());
- stmt->setUInt32(index++, m_deathExpireTime);
+ stmt->setUInt32(index++, uint32(m_deathExpireTime));
ss.str("");
ss << m_taxi.SaveTaxiDestinationsToString();
@@ -18657,12 +18657,12 @@ void Player::SaveToDB(bool create /*=false*/)
//save, far from tavern/city
//save, but in tavern/city
stmt->setUInt32(index++, m_resetTalentsCost);
- stmt->setUInt32(index++, m_resetTalentsTime);
+ stmt->setUInt32(index++, uint32(m_resetTalentsTime));
stmt->setUInt16(index++, (uint16)m_ExtraFlags);
stmt->setUInt8(index++, m_stableSlots);
stmt->setUInt16(index++, (uint16)m_atLoginFlags);
stmt->setUInt16(index++, GetZoneId());
- stmt->setUInt32(index++, m_deathExpireTime);
+ stmt->setUInt32(index++, uint32(m_deathExpireTime));
ss.str("");
ss << m_taxi.SaveTaxiDestinationsToString();
View
2 src/server/game/Instances/InstanceSaveMgr.cpp
@@ -580,7 +580,7 @@ void InstanceSaveManager::_ResetOrWarnAll(uint32 mapid, Difficulty difficulty, b
if (period < DAY)
period = DAY;
- uint32 next_reset = ((resetTime + MINUTE) / DAY * DAY) + period + diff;
+ uint32 next_reset = uint32(((resetTime + MINUTE) / DAY * DAY) + period + diff);
SetResetTimeFor(mapid, difficulty, next_reset);
ScheduleReset(true, time_t(next_reset-3600), InstResetEvent(1, mapid, difficulty, 0));
View
2 src/server/scripts/Outland/blades_edge_mountains.cpp
@@ -774,7 +774,7 @@ class npc_simon_bunny : public CreatureScript
colorSequence.clear();
playableSequence.clear();
playerSequence.clear();
- me->SetFloatValue(OBJECT_FIELD_SCALE_X, large ? 2 : 1);
+ me->SetFloatValue(OBJECT_FIELD_SCALE_X, large ? 2.0f : 1.0f);
std::list<WorldObject*> ClusterList;
Trinity::AllWorldObjectsInRange objects(me, searchDistance);

0 comments on commit 7daf69f

Please sign in to comment.
Something went wrong with that request. Please try again.