This commit is contained in:
Rochet2
2016-10-11 21:17:47 +03:00
parent dec6c45d35
commit 8aad5257f0
2 changed files with 4 additions and 2 deletions

View File

@@ -1705,7 +1705,8 @@ namespace LuaGlobalFunctions
GameObject* object = new GameObject; GameObject* object = new GameObject;
uint32 guidLow = map->GenerateLowGuid<HighGuid::GameObject>(); uint32 guidLow = map->GenerateLowGuid<HighGuid::GameObject>();
if (!object->Create(guidLow, objectInfo->entry, map, phase, Position(x, y, z, o), G3D::Quat(), 0, GO_STATE_READY)) G3D::Quat rot = G3D::Matrix3::fromEulerAnglesZYX(o, 0.f, 0.f);
if (!object->Create(guidLow, objectInfo->entry, map, phase, Position(x, y, z, o), rot, 0, GO_STATE_READY))
{ {
delete object; delete object;
Eluna::Push(L); Eluna::Push(L);

View File

@@ -682,7 +682,8 @@ namespace LuaWorldObject
#ifndef TRINITY #ifndef TRINITY
Eluna::Push(L, obj->SummonGameObject(entry, x, y, z, o, respawnDelay)); Eluna::Push(L, obj->SummonGameObject(entry, x, y, z, o, respawnDelay));
#else #else
Eluna::Push(L, obj->SummonGameObject(entry, Position(x, y, z, o), G3D::Quat(), respawnDelay)); G3D::Quat rot = G3D::Matrix3::fromEulerAnglesZYX(o, 0.f, 0.f);
Eluna::Push(L, obj->SummonGameObject(entry, Position(x, y, z, o), rot, respawnDelay));
#endif #endif
return 1; return 1;
} }