diff --git a/src/core/application.cpp b/src/core/application.cpp index 8450dfb8..d169b156 100644 --- a/src/core/application.cpp +++ b/src/core/application.cpp @@ -3712,8 +3712,8 @@ void Application::loadOnlineWorldTerrain(uint32_t mapId, float x, float y, float } if (!m2Model.isValid()) continue; - glm::quat fixedRotation(doodad.rotation.w, doodad.rotation.y, - doodad.rotation.x, doodad.rotation.z); + glm::quat fixedRotation(doodad.rotation.w, doodad.rotation.x, + doodad.rotation.y, doodad.rotation.z); glm::mat4 doodadLocal(1.0f); doodadLocal = glm::translate(doodadLocal, doodad.position); doodadLocal *= glm::mat4_cast(fixedRotation); @@ -3724,7 +3724,7 @@ void Application::loadOnlineWorldTerrain(uint32_t mapId, float x, float y, float uint32_t doodadModelId = static_cast(std::hash{}(m2Path)); m2Renderer->loadModel(m2Model, doodadModelId); - uint32_t doodadInstId = m2Renderer->createInstance(doodadModelId, worldPos, glm::vec3(0.0f), doodad.scale); + uint32_t doodadInstId = m2Renderer->createInstanceWithMatrix(doodadModelId, worldMatrix, worldPos); if (doodadInstId) m2Renderer->setSkipCollision(doodadInstId, true); loadedDoodads++; } diff --git a/src/rendering/terrain_manager.cpp b/src/rendering/terrain_manager.cpp index 9ecd3df9..5fbca940 100644 --- a/src/rendering/terrain_manager.cpp +++ b/src/rendering/terrain_manager.cpp @@ -567,8 +567,7 @@ std::shared_ptr TerrainManager::prepareTile(int x, int y) { // Build doodad's local transform (WoW coordinates) // WMO doodads use quaternion rotation - // Fix: WoW quaternions need X/Y swap for correct orientation - glm::quat fixedRotation(doodad.rotation.w, doodad.rotation.y, doodad.rotation.x, doodad.rotation.z); + glm::quat fixedRotation(doodad.rotation.w, doodad.rotation.x, doodad.rotation.y, doodad.rotation.z); glm::mat4 doodadLocal(1.0f); doodadLocal = glm::translate(doodadLocal, doodad.position);