diff options
Diffstat (limited to 'src/game/GameEventMgr.cpp')
-rw-r--r-- | src/game/GameEventMgr.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/game/GameEventMgr.cpp b/src/game/GameEventMgr.cpp index 53d01529fb9..5af64d805ed 100644 --- a/src/game/GameEventMgr.cpp +++ b/src/game/GameEventMgr.cpp @@ -1377,17 +1377,17 @@ void GameEventMgr::ChangeEquipOrModel(int16 event_id, bool activate) } else // If not spawned { - CreatureData const* data = objmgr.GetCreatureData(itr->first); - if (data && activate) + CreatureData const* data2 = objmgr.GetCreatureData(itr->first); + if (data2 && activate) { - CreatureInfo const *cinfo = objmgr.GetCreatureTemplate(data->id); - uint32 display_id = objmgr.ChooseDisplayId(0,cinfo,data); + CreatureInfo const *cinfo = objmgr.GetCreatureTemplate(data2->id); + uint32 display_id = objmgr.ChooseDisplayId(0,cinfo,data2); CreatureModelInfo const *minfo = objmgr.GetCreatureModelRandomGender(display_id); if (minfo) display_id = minfo->modelid; - if (data->equipmentId == 0) + if (data2->equipmentId == 0) itr->second.equipement_id_prev = cinfo->equipmentId; - else if (data->equipmentId != -1) + else if (data2->equipmentId != -1) itr->second.equipement_id_prev = data->equipmentId; itr->second.modelid_prev = display_id; } |