Initialised some data in Mob/Merc constructors to stop valgrind complaining.

This commit is contained in:
Derision 2013-03-19 20:44:22 +00:00
parent f32a277643
commit 6ae8fbc0e4
2 changed files with 4 additions and 2 deletions

View File

@ -37,9 +37,11 @@ Merc::Merc(const NPCType* d, float x, float y, float z, float heading)
_baseFR = d->FR;
_basePR = d->PR;
_baseCorrup = d->Corrup;
_OwnerClientVersion = EQClientTitanium;
RestRegenHP = 0;
RestRegenMana = 0;
RestRegenEndurance = 0;
cur_end = 0;
_medding = false;
_suspended = false;
@ -2749,7 +2751,7 @@ int16 Merc::GetFocusEffect(focusType type, uint16 spell_id) {
int16 focus_max_real = 0;
//item focus
for(int x=0; x<=MAX_WORN_INVENTORY; x++)
for(int x =0; x < MAX_WORN_INVENTORY; ++x)
{
TempItem = NULL;
if (equipment[x] == 0)

View File

@ -274,7 +274,7 @@ Mob::Mob(const char* in_name,
memset(&itembonuses, 0, sizeof(StatBonuses));
memset(&spellbonuses, 0, sizeof(StatBonuses));
//memset(&aabonuses, 0, sizeof(StatBonuses)); //don't need this until we start using Client::CalcAABonuses()
memset(&aabonuses, 0, sizeof(StatBonuses));
spellbonuses.AggroRange = -1;
spellbonuses.AssistRange = -1;
pLastChange = 0;