Core/Misc: Fixed rotation of many gameobjects summoned in garrison and various scripts

This commit is contained in:
hondacrx
2018-05-08 15:36:23 -04:00
parent 9b40067017
commit f26f7a4348
14 changed files with 44 additions and 27 deletions
+4 -4
View File
@@ -2849,7 +2849,7 @@ namespace Game.Spells
Map map = target.GetMap();
Position pos = new Position(x, y, z, target.GetOrientation());
Quaternion rotation = new Quaternion(Matrix3.fromEulerAnglesZYX(target.GetOrientation(), 0.0f, 0.0f));
Quaternion rotation = Quaternion.fromEulerAnglesZYX(target.GetOrientation(), 0.0f, 0.0f);
GameObject go = GameObject.CreateGameObject((uint)effectInfo.MiscValue, map, pos, rotation, 255, GameObjectState.Ready);
if (!go)
return;
@@ -3509,7 +3509,7 @@ namespace Game.Spells
posZ = m_caster.GetPositionZ(),
Orientation = m_caster.GetOrientation()
};
Quaternion rotation = new Quaternion(Matrix3.fromEulerAnglesZYX(pos.GetOrientation(), 0.0f, 0.0f));
Quaternion rotation = Quaternion.fromEulerAnglesZYX(pos.GetOrientation(), 0.0f, 0.0f);
GameObject go = GameObject.CreateGameObject((uint)effectInfo.MiscValue, map, pos, rotation, 0, GameObjectState.Ready);
if (!go)
@@ -3850,7 +3850,7 @@ namespace Game.Spells
Map map = m_caster.GetMap();
Position pos = new Position(x, y, z, m_caster.GetOrientation());
Quaternion rotation = new Quaternion(Matrix3.fromEulerAnglesZYX(m_caster.GetOrientation(), 0.0f, 0.0f));
Quaternion rotation = Quaternion.fromEulerAnglesZYX(m_caster.GetOrientation(), 0.0f, 0.0f);
GameObject go = GameObject.CreateGameObject((uint)effectInfo.MiscValue, map, pos, rotation, 255, GameObjectState.Ready);
if (!go)
return;
@@ -4537,7 +4537,7 @@ namespace Game.Spells
m_caster.GetPosition(out fx, out fy, out fz);
Position pos = new Position(fx, fy, fz, m_caster.GetOrientation());
Quaternion rotation = new Quaternion(Matrix3.fromEulerAnglesZYX(m_caster.GetOrientation(), 0.0f, 0.0f));
Quaternion rotation = Quaternion.fromEulerAnglesZYX(m_caster.GetOrientation(), 0.0f, 0.0f);
GameObject go = GameObject.CreateGameObject(name_id, cMap, pos, rotation, 255, GameObjectState.Ready);
if (!go)
return;