From 1519ec0b755296b555ae096bc780329233e242b4 Mon Sep 17 00:00:00 2001 From: tomrus88 Date: Fri, 31 Oct 2008 23:37:32 +0300 Subject: [PATCH] Updated THANKS file --- THANKS | 3 +++ src/game/GameObject.cpp | 15 +++++++++++---- 2 files changed, 14 insertions(+), 4 deletions(-) diff --git a/THANKS b/THANKS index 5d5e8fded..46ed80e44 100644 --- a/THANKS +++ b/THANKS @@ -21,6 +21,9 @@ similar to this one: community with a great server. We have not gained too much help from them, but we have recieved some. + Thanks to WCell team (especially Ralek) for reseach on realm reconnect sequence, + item scaling stats algorithm, gameobject rotation issues. + The easiest policy with this file is to thank everyone who contributes to the project, without judging the value of the contribution. diff --git a/src/game/GameObject.cpp b/src/game/GameObject.cpp index 874088db3..795a95988 100644 --- a/src/game/GameObject.cpp +++ b/src/game/GameObject.cpp @@ -124,11 +124,18 @@ bool GameObject::Create(uint32 guidlow, uint32 name_id, Map *map, float x, float SetFloatValue(GAMEOBJECT_FACING, ang); //this is not facing angle int64 rotation = 0; - float f_rot = sin(ang / 2.0f); - int64 i_rot = f_rot / atan(pow(2.0f, -20.0f)); - rotation |= (i_rot << 43 >> 43) & 0x00000000001FFFFF; - sLog.outDebug("go_create: ang: %f, rot: " SI64FMTD, ang, rotation); + float f_rot1 = sin(ang / 2.0f); + int64 i_rot1 = f_rot1 / atan(pow(2.0f, -20.0f)); + rotation |= (i_rot1 << 43 >> 43) & 0x00000000001FFFFF; + + //float f_rot2 = sin(0.0f / 2.0f); + //int64 i_rot2 = f_rot2 / atan(pow(2.0f, -20.0f)); + //rotation |= (((i_rot2 << 22) >> 32) >> 11) & 0x000003FFFFE00000; + + //float f_rot3 = sin(0.0f / 2.0f); + //int64 i_rot3 = f_rot3 / atan(pow(2.0f, -21.0f)); + //rotation |= (i_rot3 >> 42) & 0x7FFFFC0000000000; SetUInt64Value(GAMEOBJECT_ROTATION, rotation);