changeset 2147:4393b60cd9e2

FACE_PRESSURE_PLATE
author Ritor1
date Mon, 06 Jan 2014 22:46:11 +0600
parents 6ed6ad15995d
children af349bd395ff
files Outdoor.cpp
diffstat 1 files changed, 12 insertions(+), 12 deletions(-) [+]
line wrap: on
line diff
--- a/Outdoor.cpp	Mon Jan 06 20:01:21 2014 +0600
+++ b/Outdoor.cpp	Mon Jan 06 22:46:11 2014 +0600
@@ -3650,9 +3650,9 @@
   BSPModel *v54; // eax@215
   int v55; // eax@217
   BSPModel *v58; // eax@228
-  unsigned __int64 v59; // qax@228
+  //unsigned __int64 v59; // qax@228
   BSPModel *v60; // eax@228
-  unsigned __int64 v61; // qax@228
+  //unsigned __int64 v61; // qax@228
   int v62; // eax@241
   unsigned int v66; // esi@263
   signed int v68; // ecx@263
@@ -3810,7 +3810,7 @@
             pParty->field_6F4_packedid = PID(OBJECT_BModel,v108);
             v103 = *(short *)(v7->pFacePlane.vNormal.x + 308 * v6 + 292);
           }*/
-		  if ( BYTE3(face[v6].uAttributes) & 4 )
+          if ( face[v6].uAttributes & FACE_PRESSURE_PLATE )
           {
             pParty->floor_face_pid = PID(OBJECT_BModel, bmodel_standing_on_pid);
             v103 = face[v6].sCogTriggeredID; //
@@ -4333,15 +4333,15 @@
       //v118 = integer_sqrt(v2 * v2 + v128 * v128);
       v129 = stru_5C6E00->Atan2(_angle_x - pLevelDecorations[(signed int)stru_721530.uFaceID >> 3].vPosition.x,
                                _angle_y - pLevelDecorations[(signed int)stru_721530.uFaceID >> 3].vPosition.y);
-      v59 = (signed int)stru_5C6E00->Cos(v129) * (signed __int64)integer_sqrt(v2 * v2 + v128 * v128);
-      v122 = v59 >> 16;
-      v2 = v59 >> 16;
-      v61 = (signed int)stru_5C6E00->Sin(v129) * (signed __int64)integer_sqrt(v2 * v2 + v128 * v128);
-      v122 = v61 >> 16;
-      v128 = v61 >> 16;
+      //v59 = (signed int)stru_5C6E00->Cos(v129) * (signed __int64)integer_sqrt(v2 * v2 + v128 * v128);
+      //v122 = ((signed int)stru_5C6E00->Cos(v129) * (signed __int64)integer_sqrt(v2 * v2 + v128 * v128)) >> 16;
+      v2 = ((signed int)stru_5C6E00->Cos(v129) * (signed __int64)integer_sqrt(v2 * v2 + v128 * v128)) >> 16;
+      //v61 = (signed int)stru_5C6E00->Sin(v129) * (signed __int64)integer_sqrt(v2 * v2 + v128 * v128);
+      v122 = ((signed int)stru_5C6E00->Sin(v129) * (signed __int64)integer_sqrt(v2 * v2 + v128 * v128)) >> 16;
+      v128 = ((signed int)stru_5C6E00->Sin(v129) * (signed __int64)integer_sqrt(v2 * v2 + v128 * v128)) >> 16;
     }
-    else
-    {
+    //else
+    //{
       if ( PID_TYPE(stru_721530.uFaceID) == OBJECT_BModel)
       {
         pParty->bFlying = false;
@@ -4436,7 +4436,7 @@
         pParty->uFallSpeed = 0;
         *(float *)&v128 = 0.0;
       }
-    }
+    //}
     v2 = (unsigned __int64)(58500i64 * v2) >> 16;
     pModel = (BSPModel *)58500;
     v128 = (unsigned __int64)(58500i64 * v128) >> 16;