Mercurial > mm7
changeset 66:653fdf29c654
23.01.13 (work)
author | Ritor1 |
---|---|
date | Wed, 23 Jan 2013 17:29:00 +0600 |
parents | 31feb3432bbd |
children | 3b4f8bd48e3b |
files | Game.cpp Party.h mm7_4.cpp |
diffstat | 3 files changed, 17 insertions(+), 14 deletions(-) [+] |
line wrap: on
line diff
--- a/Game.cpp Wed Jan 23 13:21:04 2013 +0600 +++ b/Game.cpp Wed Jan 23 17:29:00 2013 +0600 @@ -58,11 +58,9 @@ uFlags2 |= 2u; pIndoorCamera->sRotationX = pParty->sRotationX; pIndoorCamera->sRotationY = pParty->sRotationY; - pIndoorCamera->pos.x = pParty->vPosition.x - ((unsigned __int64)(stru_5C6E00->SinCos(pParty->sRotationY) - * (signed __int64)pParty->field_18) >> 16); - pIndoorCamera->pos.y = pParty->vPosition.y - ((unsigned __int64)(stru_5C6E00->SinCos(pParty->sRotationY - stru_5C6E00->uIntegerHalfPi) - * (signed __int64)pParty->field_18) >> 16); - pIndoorCamera->pos.z = pParty->vPosition.z + pParty->sEyelevel; + pIndoorCamera->pos.x = pParty->vPosition.x - pParty->field_18 * (stru_5C6E00->SinCos(pIndoorCamera->sRotationY) / 2048.0);//12552 + pIndoorCamera->pos.y = pParty->vPosition.y - pParty->field_18 * (stru_5C6E00->SinCos(pIndoorCamera->sRotationY) / 2048.0);//800 + pIndoorCamera->pos.z = pParty->vPosition.z + pParty->sEyelevel;//193, but real 353 pIndoorCamera->Initialize2(); pIndoorCameraD3D->CreateWorldMatrixAndSomeStuff(); pIndoorCameraD3D->_4374E8_ProllyBuildFrustrum(); @@ -76,14 +74,14 @@ } else { - if ( pParty->vPosition.x != pParty->vPrevPosition.x | pParty->sRotationY != pParty->sPrevRotationY | pParty->vPosition.y != pParty->vPrevPosition.z - | pParty->sRotationX != pParty->sPrevRotationX | pParty->vPosition.z != pParty->vPrevPosition.y | pParty->sEyelevel != pParty->sPrevEyelevel ) + if ( pParty->vPosition.x != pParty->vPrevPosition.x | pParty->sRotationY != pParty->sPrevRotationY | pParty->vPosition.y != pParty->vPrevPosition.y + | pParty->sRotationX != pParty->sPrevRotationX | pParty->vPosition.z != pParty->vPrevPosition.z | pParty->sEyelevel != pParty->sPrevEyelevel ) pParty->uFlags |= 2u; - pParty->vPrevPosition.x = pParty->vPosition.x; - pParty->vPrevPosition.y = pParty->vPosition.z; + pParty->vPrevPosition = pParty->vPosition; + //pParty->vPrevPosition.y = pParty->vPosition.y; //v0 = &pRenderer; pParty->sPrevRotationY = pParty->sRotationY; - pParty->vPrevPosition.z = pParty->vPosition.y; + //pParty->vPrevPosition.z = pParty->vPosition.y; pParty->sPrevRotationX = pParty->sRotationX; pParty->sPrevEyelevel = pParty->sEyelevel; pRenderer->BeginSceneD3D(); @@ -139,7 +137,7 @@ { if ( !sub_4226C2() && pRenderer->pRenderD3D) pRenderer->FillRectFast(pViewport->uViewportX, pViewport->uViewportY, pViewport->uViewportZ - pViewport->uViewportX, - pViewport->uViewportW - pViewport->uViewportY + 1, pRenderer->uTargetGMask | pRenderer->uTargetBMask); + pViewport->uViewportW - pViewport->uViewportY + 1, pRenderer->uTargetGMask | pRenderer->uTargetBMask);//0x0000FFFF/*pRenderer->uTargetGMask | pRenderer->uTargetBMask*/ - white window viewparams->field_48 = 0; } }
--- a/Party.h Wed Jan 23 13:21:04 2013 +0600 +++ b/Party.h Wed Jan 23 17:29:00 2013 +0600 @@ -273,4 +273,5 @@ extern Party *pParty; // idb -extern struct ActionQueue *pPartyActionQueue; \ No newline at end of file +extern struct ActionQueue *pPartyActionQueue; +
--- a/mm7_4.cpp Wed Jan 23 13:21:04 2013 +0600 +++ b/mm7_4.cpp Wed Jan 23 17:29:00 2013 +0600 @@ -3080,11 +3080,15 @@ { v23 = 0; v22 = 0; - for (uint i = 0; i < 2; ++i) + /*for (uint i = 0; i < 2; ++i) { if (pParty->pHirelings[i].pName) pTmpBuf[v22++] = i; - } + }*/ + if (pParty->pHirelings[0].pName) + pTmpBuf[v22++] = 0; + if (pParty->pHirelings[1].pName) + pTmpBuf[v22++] = 1; for (uint i = 0; i < pNPCStats->uNumNewNPCs; ++i) {