Index: trunk/src/game/Object.cpp
===================================================================
--- trunk/src/game/Object.cpp (revision 122)
+++ trunk/src/game/Object.cpp (revision 123)
@@ -602,7 +602,7 @@
                     {
                         if(target->isGameMaster())
-                            *data << cinfo->DisplayID_A;
+                            *data << cinfo->Modelid1;
                         else
-                            *data << cinfo->DisplayID_H;
+                            *data << cinfo->Modelid3;
                     }
                     else
Index: trunk/src/game/Creature.h
===================================================================
--- trunk/src/game/Creature.h (revision 102)
+++ trunk/src/game/Creature.h (revision 123)
@@ -141,8 +141,8 @@
     uint32  Entry;
     uint32  HeroicEntry;
-    uint32  DisplayID_A;
-    uint32  DisplayID_A2;
-    uint32  DisplayID_H;
-    uint32  DisplayID_H2;
+    uint32  Modelid1;
+    uint32  Modelid2;
+    uint32  Modelid3;
+    uint32  Modelid4;
     char*   Name;
     char*   SubName;
@@ -204,4 +204,6 @@
     uint32  flags_extra;
     char const* ScriptName;
+    uint32 GetRandomValidModelId() const;
+    uint32 GetFirstValidModelId() const;
 };
 
Index: trunk/src/game/QueryHandler.cpp
===================================================================
--- trunk/src/game/QueryHandler.cpp (revision 102)
+++ trunk/src/game/QueryHandler.cpp (revision 123)
@@ -188,8 +188,8 @@
         data << (uint32)0;                                  // unknown        wdbFeild11
         data << (uint32)ci->PetSpellDataId;                 // Id from CreatureSpellData.dbc    wdbField12
-        data << (uint32)ci->DisplayID_A;                    // modelid_male1
-        data << (uint32)ci->DisplayID_H;                    // modelid_female1 ?
-        data << (uint32)ci->DisplayID_A2;                   // modelid_male2 ?
-        data << (uint32)ci->DisplayID_H2;                   // modelid_femmale2 ?
+        data << (uint32)ci->Modelid1;                       // Modelid1
+        data << (uint32)ci->Modelid2;                       // Modelid2
+        data << (uint32)ci->Modelid3;                       // Modelid3
+        data << (uint32)ci->Modelid4;                       // Modelid4
         data << (float)1.0f;                                // unk
         data << (float)1.0f;                                // unk
Index: trunk/src/game/Totem.cpp
===================================================================
--- trunk/src/game/Totem.cpp (revision 111)
+++ trunk/src/game/Totem.cpp (revision 123)
@@ -57,18 +57,20 @@
 void Totem::Summon(Unit* owner)
 {
+    CreatureInfo const *cinfo = GetCreatureInfo();
+    if (owner->GetTypeId()==TYPEID_PLAYER && cinfo)
+    {
+        if (uint32 modelid = cinfo->GetRandomValidModelId()) 
+            SetDisplayId(modelid);
+        else
+        {
+            sLog.outErrorDb("No displayid found for the totem with the entry %u! Can't summon it!", GetEntry());
+            return;
+        }
+    }
+
+    // Only add if a display exists.
     sLog.outDebug("AddObject at Totem.cpp line 49");
-
     SetInstanceId(owner->GetInstanceId());
     owner->GetMap()->Add((Creature*)this);
-
-    // select totem model in dependent from owner team
-    CreatureInfo const *cinfo = GetCreatureInfo();
-    if(owner->GetTypeId()==TYPEID_PLAYER && cinfo)
-    {
-        if(((Player*)owner)->GetTeam()==HORDE)
-            SetDisplayId(cinfo->DisplayID_H);
-        else
-            SetDisplayId(cinfo->DisplayID_A);
-    }
 
     WorldPacket data(SMSG_GAMEOBJECT_SPAWN_ANIM_OBSOLETE, 8);
Index: trunk/src/game/SpellAuras.cpp
===================================================================
--- trunk/src/game/SpellAuras.cpp (revision 104)
+++ trunk/src/game/SpellAuras.cpp (revision 123)
@@ -2697,6 +2697,5 @@
             else
             {
-                                                            // Will use the default model here
-                m_target->SetDisplayId(ci->DisplayID_A);
+                if (uint32 modelid = ci->GetRandomValidModelId()) m_target->SetDisplayId(modelid);
 
                 // Dragonmaw Illusion (set mount model also)
Index: trunk/src/game/Creature.cpp
===================================================================
--- trunk/src/game/Creature.cpp (revision 102)
+++ trunk/src/game/Creature.cpp (revision 123)
@@ -95,4 +95,26 @@
 }
 
+uint32 CreatureInfo::GetRandomValidModelId() const
+{
+    uint32 c = 0;
+    uint32 modelIDs[4];
+
+    if (Modelid1) modelIDs[c++] = Modelid1;
+    if (Modelid2) modelIDs[c++] = Modelid2;
+    if (Modelid3) modelIDs[c++] = Modelid3;
+    if (Modelid4) modelIDs[c++] = Modelid4;
+
+    return ((c>0) ? modelIDs[urand(0,c-1)] : 0);
+}
+
+uint32 CreatureInfo::GetFirstValidModelId() const
+{
+    if(Modelid1) return Modelid1;
+    if(Modelid2) return Modelid2;
+    if(Modelid3) return Modelid3;
+    if(Modelid4) return Modelid4;
+    return 0;
+}
+
 Creature::Creature() :
 Unit(), i_AI(NULL),
@@ -188,7 +210,8 @@
     m_creatureInfo = cinfo;                                 // map mode related always
 
-    if (cinfo->DisplayID_A == 0 || cinfo->DisplayID_H == 0) // Cancel load if no model defined
-    {
-        sLog.outErrorDb("Creature (Entry: %u) has no model defined for Horde or Alliance in table `creature_template`, can't load. ",Entry);
+    // Cancel load if no model defined
+    if (!(cinfo->GetFirstValidModelId()))
+    {
+        sLog.outErrorDb("Creature (Entry: %u) has no model defined in table `creature_template`, can't load. ",Entry);
         return false;
     }
@@ -1117,18 +1140,6 @@
     if(cinfo)
     {
-        if(displayId != cinfo->DisplayID_A && displayId != cinfo->DisplayID_H)
-        {
-            CreatureModelInfo const *minfo = objmgr.GetCreatureModelInfo(cinfo->DisplayID_A);
-            if(!minfo || displayId != minfo->modelid_other_gender)
-            {
-                minfo = objmgr.GetCreatureModelInfo(cinfo->DisplayID_H);
-                if(minfo && displayId == minfo->modelid_other_gender)
-                    displayId = 0;
-            }
-            else
-                displayId = 0;
-        }
-        else
-            displayId = 0;
+        if(displayId == cinfo->Modelid1 || displayId == cinfo->Modelid2 ||
+            displayId == cinfo->Modelid3 || displayId == cinfo->Modelid4) displayId = 0;
     }
 
Index: trunk/src/game/ObjectMgr.cpp
===================================================================
--- trunk/src/game/ObjectMgr.cpp (revision 102)
+++ trunk/src/game/ObjectMgr.cpp (revision 123)
@@ -711,10 +711,25 @@
             sLog.outErrorDb("Creature (Entry: %u) has non-existing faction_H template (%u)", cInfo->Entry, cInfo->faction_H);
 
-        CreatureModelInfo const* minfo = sCreatureModelStorage.LookupEntry<CreatureModelInfo>(cInfo->DisplayID_A);
-        if (!minfo)
-            sLog.outErrorDb("Creature (Entry: %u) has non-existing modelId_A (%u)", cInfo->Entry, cInfo->DisplayID_A);
-        minfo = sCreatureModelStorage.LookupEntry<CreatureModelInfo>(cInfo->DisplayID_H);
-        if (!minfo)
-            sLog.outErrorDb("Creature (Entry: %u) has non-existing modelId_H (%u)", cInfo->Entry, cInfo->DisplayID_H);
+        // check model ids, supplying and sending non-existent ids to the client might crash them
+        if(!sCreatureModelStorage.LookupEntry<CreatureModelInfo>(cInfo->Modelid1))
+        {
+            sLog.outErrorDb("Creature (Entry: %u) has non-existing modelId_A (%u), setting it to 0", cInfo->Entry, cInfo->Modelid1);
+            const_cast<CreatureInfo*>(cInfo)->Modelid1 = 0;
+        }
+        if(!sCreatureModelStorage.LookupEntry<CreatureModelInfo>(cInfo->Modelid2))
+        {
+            sLog.outErrorDb("Creature (Entry: %u) has non-existing modelId_A2 (%u), setting it to 0", cInfo->Entry, cInfo->Modelid2);
+            const_cast<CreatureInfo*>(cInfo)->Modelid2 = 0;
+        }
+        if(!sCreatureModelStorage.LookupEntry<CreatureModelInfo>(cInfo->Modelid3))
+        {
+            sLog.outErrorDb("Creature (Entry: %u) has non-existing modelId_H (%u), setting it to 0", cInfo->Entry, cInfo->Modelid3);
+            const_cast<CreatureInfo*>(cInfo)->Modelid3 = 0;
+        }
+        if(!sCreatureModelStorage.LookupEntry<CreatureModelInfo>(cInfo->Modelid4))
+        {
+            sLog.outErrorDb("Creature (Entry: %u) has non-existing modelId_H2 (%u), setting it to 0", cInfo->Entry, cInfo->Modelid4);
+            const_cast<CreatureInfo*>(cInfo)->Modelid4 = 0;
+        }
 
         if(cInfo->dmgschool >= MAX_SPELL_SCHOOL)
@@ -764,5 +779,6 @@
         if(cInfo->scale <= 0.0f)
         {
-            CreatureDisplayInfoEntry const* ScaleEntry = sCreatureDisplayInfoStore.LookupEntry(cInfo->DisplayID_A);
+            uint32 modelid = cInfo->GetFirstValidModelId();
+            CreatureDisplayInfoEntry const* ScaleEntry = sCreatureDisplayInfoStore.LookupEntry(modelid);
             const_cast<CreatureInfo*>(cInfo)->scale = ScaleEntry ? ScaleEntry->scale : 1.0f;
         }
@@ -905,15 +921,10 @@
 {
     // Load creature model (display id)
-    uint32 display_id;
-    if (!data || data->displayid == 0)                      // use defaults from the template
-    {
-        // DisplayID_A is used if no team is given
-        if (team == HORDE)
-            display_id = (cinfo->DisplayID_H2 != 0 && urand(0,1) == 0) ? cinfo->DisplayID_H2 : cinfo->DisplayID_H;
-        else
-            display_id = (cinfo->DisplayID_A2 != 0 && urand(0,1) == 0) ? cinfo->DisplayID_A2 : cinfo->DisplayID_A;
-    }
-    else                                                    // overriden in creature data
-        display_id = data->displayid;
+    uint32 display_id = 0;
+
+    if (!data || data->displayid == 0) // use defaults from the template
+    {
+        display_id = cinfo->GetRandomValidModelId();
+    } else display_id = data->displayid; // overwritten from creature data        
 
     return display_id;
@@ -4600,23 +4611,21 @@
 uint16 ObjectMgr::GetTaxiMount( uint32 id, uint32 team )
 {
-    uint16 mount_entry = 0;
-    uint16 mount_id = 0;
+    uint32 mount_entry = 0;
+    uint32 mount_id = 0;
 
     TaxiNodesEntry const* node = sTaxiNodesStore.LookupEntry(id);
-    if(node)
-    {
-        if (team == ALLIANCE)
-        {
-            mount_entry = node->alliance_mount_type;
-            CreatureInfo const *ci = GetCreatureTemplate(mount_entry);
-            if(ci)
-                mount_id = ci->DisplayID_A;
-        }
-        if (team == HORDE)
-        {
-            mount_entry = node->horde_mount_type;
-            CreatureInfo const *ci = GetCreatureTemplate(mount_entry);
-            if(ci)
-                mount_id = ci->DisplayID_H;
+    if (node)
+    {
+        if (team == ALLIANCE) mount_entry = node->alliance_mount_type;
+        else mount_entry = node->horde_mount_type;
+
+        CreatureInfo const *cinfo = GetCreatureTemplate(mount_entry);
+        if (cinfo)
+        {
+            if(! (mount_id = cinfo->GetRandomValidModelId()))
+            {
+                sLog.outErrorDb("No displayid found for the taxi mount with the entry %u! Can't load it!", mount_entry);
+                return false;
+            }
         }
     }
