mirror of
https://github.com/mangosfour/server.git
synced 2025-12-12 10:37:03 +00:00
[12104] Fix some bugs, thanks to LordPsyan for pointing
* Fix an inconsistence between comment and code for model selection * Improve the macro from recent commit to work with stricter gcc preprocessors * Fix a bug that caused a crash for not loaded outdoorPvp scripts
This commit is contained in:
parent
104881706b
commit
7e70e39b9b
3 changed files with 5 additions and 4 deletions
|
|
@ -438,7 +438,7 @@ uint32 Creature::ChooseDisplayId(const CreatureInfo* cinfo, const CreatureData*
|
|||
// Where it's expected to select one of two, model must have a alternative model defined (alternative model is normally the same as defined in ModelId1).
|
||||
// Same pattern is used in the above model selection, but the result may be ModelId3 and not ModelId2 as here.
|
||||
uint32 modelid_tmp = sObjectMgr.GetCreatureModelAlternativeModel(cinfo->ModelId[1]);
|
||||
display_id = modelid_tmp ? modelid_tmp : cinfo->ModelId[1];
|
||||
display_id = modelid_tmp ? cinfo->ModelId[urand(0, 1)] : cinfo->ModelId[1];
|
||||
}
|
||||
else if (cinfo->ModelId[0])
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue