diff Indoor.cpp @ 1441:b67a3e0d6fc3

Слияние
author Ritor1
date Sat, 27 Jul 2013 09:36:55 +0600
parents 468f434a8d8a 38df78aba732
children 934074e7fcc1
line wrap: on
line diff
--- a/Indoor.cpp	Sat Jul 27 09:36:29 2013 +0600
+++ b/Indoor.cpp	Sat Jul 27 09:36:55 2013 +0600
@@ -62,7 +62,6 @@
 
 stru320 stru_F8AD28; // idb
 stru337 stru_F81018;
-stru167_wrap array_5118E8;
 BspRenderer_PortalViewportData stru_F8A590;
 BspRenderer *pBspRenderer = new BspRenderer; // idb
 stru141 stru_721530;
@@ -412,7 +411,7 @@
   sub_440BED(&_this);
   pParty->uFlags &= ~2;
   pGame->DrawParticles();
-  array_5118E8._440F07();
+  trail_particle_generator.UpdateParticles();
 }
 
 //----- (004C0EF2) --------------------------------------------------------
@@ -4011,8 +4010,8 @@
       if ( pDest )
       {
         qword_A750D8 = 256i64;
-        word_A750E0 = 46;
-        word_A750E2 = LOWORD(v34[rand() % v30]);
+        PlayerSpeechID = SPEECH_46;
+        uSpeakingCharacter = LOWORD(v34[rand() % v30]);
       }
     }
   }
@@ -6908,4 +6907,51 @@
     PortalFace._screen_space_y[bottom_num_vertices] = PortalFace._screen_space_y[0];
   }
   return bottom_num_vertices;
+}
+
+//----- (004AAEA6) --------------------------------------------------------
+int __fastcall sub_4AAEA6_transform(RenderVertexSoft *a1)
+{
+  double v4; // st5@2
+  double v5; // st4@3
+  float v11; // [sp+8h] [bp-8h]@2
+  float v12; // [sp+8h] [bp-8h]@6
+  float v13; // [sp+Ch] [bp-4h]@2
+  float v14; // [sp+Ch] [bp-4h]@6
+
+  if ( pBLVRenderParams->sPartyRotX )
+  {
+    v13 = a1->vWorldPosition.x - (double)pParty->vPosition.x;
+    v11 = a1->vWorldPosition.y - (double)pParty->vPosition.y;
+    v4 = a1->vWorldPosition.z - (double)pParty->vPosition.z;
+    if ( pRenderer->pRenderD3D )
+    {
+      v5 = v11 * pBLVRenderParams->fSineY + v13 * pBLVRenderParams->fCosineY;
+      a1->vWorldViewPosition.y = v13 * pBLVRenderParams->fSineY - v11 * pBLVRenderParams->fCosineY;
+    }
+    else
+    {
+      v5 = v13 * pBLVRenderParams->fCosineY - v11 * pBLVRenderParams->fSineY;
+      a1->vWorldViewPosition.y = v13 * pBLVRenderParams->fSineY + v11 * pBLVRenderParams->fCosineY;
+    }
+    a1->vWorldViewPosition.x = v5 * pBLVRenderParams->fCosineNegX - v4 * pBLVRenderParams->fSineNegX;
+    a1->vWorldViewPosition.z = v5 * pBLVRenderParams->fSineNegX + v4 * pBLVRenderParams->fCosineNegX;
+  }
+  else
+  {
+    v14 = a1->vWorldPosition.x - (double)pParty->vPosition.x;
+    v12 = a1->vWorldPosition.y - (double)pParty->vPosition.y;
+    a1->vWorldViewPosition.z = a1->vWorldPosition.z - (double)pParty->vPosition.z;
+    if ( pRenderer->pRenderD3D )
+    {
+      a1->vWorldViewPosition.x = v12 * pBLVRenderParams->fSineY + v14 * pBLVRenderParams->fCosineY;
+      a1->vWorldViewPosition.y = v14 * pBLVRenderParams->fSineY - v12 * pBLVRenderParams->fCosineY;
+    }
+    else
+    {
+      a1->vWorldViewPosition.x = v14 * pBLVRenderParams->fCosineY - v12 * pBLVRenderParams->fSineY;
+      a1->vWorldViewPosition.y = v14 * pBLVRenderParams->fSineY + v12 * pBLVRenderParams->fCosineY;
+    }
+  }
+  return 0;
 }
\ No newline at end of file