Mercurial > mm7
comparison DecalBuilder.cpp @ 1980:c1c74df0a33e
changing most of auto types to their actual types
author | Grumpy7 |
---|---|
date | Wed, 30 Oct 2013 00:47:37 -0700 |
parents | 2c71fa8913d2 |
children | 28cb79ae2f6f |
comparison
equal
deleted
inserted
replaced
1979:92dfa0cafbe3 | 1980:c1c74df0a33e |
---|---|
452 | 452 |
453 uNumDecals = 0; | 453 uNumDecals = 0; |
454 if (!pBloodsplatContainer->std__vector_pBloodsplats_size) | 454 if (!pBloodsplatContainer->std__vector_pBloodsplats_size) |
455 return true; | 455 return true; |
456 | 456 |
457 auto pFace = &pIndoor->pFaces[uFaceID]; | 457 BLVFace* pFace = &pIndoor->pFaces[uFaceID]; |
458 | 458 |
459 if (pFace->uAttributes & 0x400000) | 459 if (pFace->uAttributes & 0x400000) |
460 return true; | 460 return true; |
461 if (pFace->Fluid()) | 461 if (pFace->Fluid()) |
462 return true; | 462 return true; |
463 for (uint i = 0; i < pBloodsplatContainer->std__vector_pBloodsplats_size; ++i) | 463 for (uint i = 0; i < pBloodsplatContainer->std__vector_pBloodsplats_size; ++i) |
464 { | 464 { |
465 auto pBloodsplat = pBloodsplatContainer->std__vector_pBloodsplats + i; | 465 Bloodsplat* pBloodsplat = &pBloodsplatContainer->std__vector_pBloodsplats[i]; |
466 if (pFace->pBounding.x1 - pBloodsplat->radius < pBloodsplat->x && | 466 if (pFace->pBounding.x1 - pBloodsplat->radius < pBloodsplat->x && |
467 pFace->pBounding.x2 + pBloodsplat->radius > pBloodsplat->x && | 467 pFace->pBounding.x2 + pBloodsplat->radius > pBloodsplat->x && |
468 pFace->pBounding.y1 - pBloodsplat->radius < pBloodsplat->y && | 468 pFace->pBounding.y1 - pBloodsplat->radius < pBloodsplat->y && |
469 pFace->pBounding.y2 + pBloodsplat->radius > pBloodsplat->y && | 469 pFace->pBounding.y2 + pBloodsplat->radius > pBloodsplat->y && |
470 pFace->pBounding.z1 - pBloodsplat->radius < pBloodsplat->z && | 470 pFace->pBounding.z1 - pBloodsplat->radius < pBloodsplat->z && |
739 ErrD3D(pRenderer->pRenderD3D->pDevice->SetRenderState(D3DRENDERSTATE_CULLMODE, D3DCULL_NONE)); | 739 ErrD3D(pRenderer->pRenderD3D->pDevice->SetRenderState(D3DRENDERSTATE_CULLMODE, D3DCULL_NONE)); |
740 ErrD3D(pRenderer->pRenderD3D->pDevice->SetRenderState(D3DRENDERSTATE_SRCBLEND, D3DBLEND_ONE)); | 740 ErrD3D(pRenderer->pRenderD3D->pDevice->SetRenderState(D3DRENDERSTATE_SRCBLEND, D3DBLEND_ONE)); |
741 ErrD3D(pRenderer->pRenderD3D->pDevice->SetRenderState(D3DRENDERSTATE_DESTBLEND, D3DBLEND_ONE)); | 741 ErrD3D(pRenderer->pRenderD3D->pDevice->SetRenderState(D3DRENDERSTATE_DESTBLEND, D3DBLEND_ONE)); |
742 ErrD3D(pRenderer->pRenderD3D->pDevice->SetRenderState(D3DRENDERSTATE_DITHERENABLE, FALSE)); | 742 ErrD3D(pRenderer->pRenderD3D->pDevice->SetRenderState(D3DRENDERSTATE_DITHERENABLE, FALSE)); |
743 | 743 |
744 auto pTex = pGame->pIndoorCameraD3D->LoadTextureAndGetHardwarePtr("hwsplat04"); | 744 IDirect3DTexture2* pTex = pGame->pIndoorCameraD3D->LoadTextureAndGetHardwarePtr("hwsplat04"); |
745 ErrD3D(pRenderer->pRenderD3D->pDevice->SetTexture(0, pTex)); | 745 ErrD3D(pRenderer->pRenderD3D->pDevice->SetTexture(0, pTex)); |
746 | 746 |
747 DrawDecals(0.00039999999); | 747 DrawDecals(0.00039999999); |
748 ErrD3D(pRenderer->pRenderD3D->pDevice->SetRenderState(D3DRENDERSTATE_CULLMODE, D3DCULL_CW)); | 748 ErrD3D(pRenderer->pRenderD3D->pDevice->SetRenderState(D3DRENDERSTATE_CULLMODE, D3DCULL_CW)); |
749 ErrD3D(pRenderer->pRenderD3D->pDevice->SetRenderState(D3DRENDERSTATE_ZWRITEENABLE, TRUE)); | 749 ErrD3D(pRenderer->pRenderD3D->pDevice->SetRenderState(D3DRENDERSTATE_ZWRITEENABLE, TRUE)); |