Mercurial > mm7
comparison mm7_3.cpp @ 868:6759478c2f14
m
author | Ritor1 |
---|---|
date | Mon, 01 Apr 2013 09:05:31 +0600 |
parents | 2825b5a9b562 |
children | 715064ae1792 |
comparison
equal
deleted
inserted
replaced
842:2825b5a9b562 | 868:6759478c2f14 |
---|---|
5986 //double v26; // [sp+120h] [bp-44h]@4 | 5986 //double v26; // [sp+120h] [bp-44h]@4 |
5987 //float v27; // [sp+128h] [bp-3Ch]@4 | 5987 //float v27; // [sp+128h] [bp-3Ch]@4 |
5988 float v28; // [sp+12Ch] [bp-38h]@2 | 5988 float v28; // [sp+12Ch] [bp-38h]@2 |
5989 int v29; // [sp+130h] [bp-34h]@4 | 5989 int v29; // [sp+130h] [bp-34h]@4 |
5990 int v30; // [sp+134h] [bp-30h]@1 | 5990 int v30; // [sp+134h] [bp-30h]@1 |
5991 //int v31; // [sp+138h] [bp-2Ch]@2 | 5991 float v31; // [sp+138h] [bp-2Ch]@2 |
5992 int v32; // [sp+13Ch] [bp-28h]@6 | 5992 int v32; // [sp+13Ch] [bp-28h]@6 |
5993 int v33; // [sp+140h] [bp-24h]@2 | 5993 int v33; // [sp+140h] [bp-24h]@2 |
5994 int v34; // [sp+144h] [bp-20h]@1 | 5994 int v34; // [sp+144h] [bp-20h]@1 |
5995 int v35; // [sp+148h] [bp-1Ch]@4 | 5995 int v35; // [sp+148h] [bp-1Ch]@4 |
5996 int v36; // [sp+14Ch] [bp-18h]@2 | 5996 int v36; // [sp+14Ch] [bp-18h]@2 |
5997 int v37; // [sp+154h] [bp-10h]@8 | 5997 int v37; // [sp+154h] [bp-10h]@8 |
5998 int v38; // [sp+158h] [bp-Ch]@1 | 5998 int v38; // [sp+158h] [bp-Ch]@1 |
5999 int v39; // [sp+15Ch] [bp-8h]@4 | 5999 int v39; // [sp+15Ch] [bp-8h]@4 |
6000 int v40; // [sp+160h] [bp-4h]@7 | 6000 int v40; // [sp+160h] [bp-4h]@7 |
6001 float v41; | |
6001 | 6002 |
6002 extern bool new_sky; | 6003 extern bool new_sky; |
6003 if (new_sky) | 6004 if (new_sky) |
6004 { | 6005 { |
6005 if (DrawSkyD3D_Skybox()) | 6006 if (DrawSkyD3D_Skybox()) |
6039 | 6040 |
6040 array_50AC10[3].vWorldViewProjX = pViewport->uViewportBR_X; | 6041 array_50AC10[3].vWorldViewProjX = pViewport->uViewportBR_X; |
6041 array_50AC10[3].vWorldViewProjY = pViewport->uViewportTL_Y; | 6042 array_50AC10[3].vWorldViewProjY = pViewport->uViewportTL_Y; |
6042 | 6043 |
6043 v36 = (double)(pViewport->uViewportBR_X - pViewport->uViewportTL_X) * 0.5; | 6044 v36 = (double)(pViewport->uViewportBR_X - pViewport->uViewportTL_X) * 0.5; |
6044 v33 = 65536 / (signed int)(v36 / tan(0.6457717418670654) + 0.5); | 6045 v31 = (signed int)(v36 / tan(0.6457717418670654) + 0.5); |
6046 //v41 = v31 + 6.7553994e15; | |
6047 v33 = 65536 / v31; | |
6045 | 6048 |
6046 for (int i = 0; i < _this.uNumVertices; ++i) | 6049 for (int i = 0; i < _this.uNumVertices; ++i) |
6047 { | 6050 { |
6048 v29 = floorf(array_50AC10[i].vWorldViewProjY + 0.5f); | 6051 v29 = floorf(array_50AC10[i].vWorldViewProjY + 0.5f); |
6049 v39 = (unsigned __int64)(_this.ptr_38->field_14 * v33 * (v30 - v29)) / 65536; | 6052 v39 = (unsigned __int64)(_this.ptr_38->field_14 * v33 * (v30 - v29)) / 65536; |
6104 if ( v18 < 0 ) | 6107 if ( v18 < 0 ) |
6105 v18 = pOutdoorCamera->shading_dist_mist; | 6108 v18 = pOutdoorCamera->shading_dist_mist; |
6106 | 6109 |
6107 v37 += ((unsigned __int64)(_this.ptr_38->field_10 * v13) >> 16); | 6110 v37 += ((unsigned __int64)(_this.ptr_38->field_10 * v13) >> 16); |
6108 v36 += ((unsigned __int64)(_this.ptr_38->field_1C * v13) >> 16); | 6111 v36 += ((unsigned __int64)(_this.ptr_38->field_1C * v13) >> 16); |
6109 v35 = 224 * pMiscTimer->uTotalGameTimeElapsed + (signed int)((unsigned __int64)(v37 * v18) >> 16) / 8; | 6112 v35 = 224 * pMiscTimer->uTotalGameTimeElapsed + fixpoint_mul(v37, v18) / 8; |
6110 v36 = 224 * pMiscTimer->uTotalGameTimeElapsed + (signed int)((unsigned __int64)(v36 * v18) >> 16) / 8; | 6113 v36 = 224 * pMiscTimer->uTotalGameTimeElapsed + fixpoint_mul(v37, v18) / 8; |
6111 | 6114 |
6112 //array_50AC10[i].vWorldViewPosition.x = pOutdoorCamera->shading_dist_mist; | 6115 //array_50AC10[i].vWorldViewPosition.x = pOutdoorCamera->shading_dist_mist; |
6113 //array_50AC10[i].vWorldPosition.x = v36 / (_this.pTexture->uTextureHeight * 65536.0); | 6116 //array_50AC10[i].vWorldPosition.x = v36 / (_this.pTexture->uTextureHeight * 65536.0); |
6114 //array_50AC10[i].vWorldPosition.y = 1.0 / (pOutdoorCamera->shading_dist_mist >> 16); | 6117 //array_50AC10[i].vWorldPosition.y = 1.0 / (pOutdoorCamera->shading_dist_mist >> 16); |
6115 //array_50AC10[i].vWorldPosition.z = v35 / (_this.pTexture->uTextureWidth * 65536.0); | 6118 //array_50AC10[i].vWorldPosition.z = v35 / (_this.pTexture->uTextureWidth * 65536.0); |
6116 array_50AC10[i]._rhw = 1; | 6119 array_50AC10[i]._rhw = 1; |
6117 //array_50AC10[i].u = (double)v35 / (65536.0 * _this.pTexture->uTextureWidth); | 6120 array_50AC10[i].u += 1.0 / 224 * pMiscTimer->uTotalGameTimeElapsed; |
6118 //array_50AC10[i].v = (double)v36 / (65536.0 * _this.pTexture->uTextureHeight); | 6121 array_50AC10[i].v += 1.0 / 224 * pMiscTimer->uTotalGameTimeElapsed; |
6119 float t = (GetTickCount() % 96000) / 96000.0f; | 6122 //float t = (GetTickCount() % 96000) / 96000.0f; |
6120 array_50AC10[i].u += t; | 6123 //array_50AC10[i].u += t; |
6121 if ( i == _this.uNumVertices - 1 ) | 6124 if ( i == _this.uNumVertices - 1 ) |
6122 { | 6125 { |
6123 pRenderer->DrawFan(_this.uNumVertices, &_this, pBitmaps_LOD->pHardwareTextures[_this.uTileBitmapID]); | 6126 pRenderer->DrawFan(_this.uNumVertices, &_this, pBitmaps_LOD->pHardwareTextures[_this.uTileBitmapID]); |
6124 | 6127 |
6125 //array_50AC10[0].vWorldViewProjY = v38; | 6128 //array_50AC10[0].vWorldViewProjY = v38; |