mirror of
https://github.com/mangosfour/server.git
synced 2025-12-17 07:37:03 +00:00
[11527] Check rotation0 and rotation1 fields at gameobject data loading
This commit is contained in:
parent
f98144e89d
commit
7d889c0821
2 changed files with 13 additions and 1 deletions
|
|
@ -1514,6 +1514,18 @@ void ObjectMgr::LoadGameobjects()
|
||||||
int16 GuidPoolId = fields[17].GetInt16();
|
int16 GuidPoolId = fields[17].GetInt16();
|
||||||
int16 EntryPoolId = fields[18].GetInt16();
|
int16 EntryPoolId = fields[18].GetInt16();
|
||||||
|
|
||||||
|
if (data.rotation0 < -1.0f || data.rotation0 > 1.0f)
|
||||||
|
{
|
||||||
|
sLog.outErrorDb("Table `gameobject` have gameobject (GUID: %u Entry: %u) with invalid rotation0 (%f) value, skip", guid, data.id, data.rotation0);
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (data.rotation1 < -1.0f || data.rotation1 > 1.0f)
|
||||||
|
{
|
||||||
|
sLog.outErrorDb("Table `gameobject` have gameobject (GUID: %u Entry: %u) with invalid rotation1 (%f) value, skip", guid, data.id, data.rotation1);
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
if (data.rotation2 < -1.0f || data.rotation2 > 1.0f)
|
if (data.rotation2 < -1.0f || data.rotation2 > 1.0f)
|
||||||
{
|
{
|
||||||
sLog.outErrorDb("Table `gameobject` have gameobject (GUID: %u Entry: %u) with invalid rotation2 (%f) value, skip", guid, data.id, data.rotation2);
|
sLog.outErrorDb("Table `gameobject` have gameobject (GUID: %u Entry: %u) with invalid rotation2 (%f) value, skip", guid, data.id, data.rotation2);
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
#ifndef __REVISION_NR_H__
|
#ifndef __REVISION_NR_H__
|
||||||
#define __REVISION_NR_H__
|
#define __REVISION_NR_H__
|
||||||
#define REVISION_NR "11526"
|
#define REVISION_NR "11527"
|
||||||
#endif // __REVISION_NR_H__
|
#endif // __REVISION_NR_H__
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue