|
|
|
@ -1146,11 +1146,11 @@ void FaceBall::RenderWorld() { |
|
|
|
|
for (auto& bullet : bullets) { |
|
|
|
|
RenderBulletMesh(matView, vecTrianglesToRasterTranslucent, bullet); |
|
|
|
|
} |
|
|
|
|
RenderMesh(matView, vecTrianglesToRaster, walls); |
|
|
|
|
RenderMesh(matView, vecTrianglesToRasterTranslucent, walls, true); |
|
|
|
|
for (auto& powerup : powerups) { |
|
|
|
|
RenderPowerupMesh(matView, vecTrianglesToRasterTranslucent, powerup); |
|
|
|
|
} |
|
|
|
|
RenderMesh(matView, vecTrianglesToRaster, walls); |
|
|
|
|
RenderMesh(matView, vecTrianglesToRasterTranslucent, walls, true); |
|
|
|
|
|
|
|
|
|
//std::sort(vecTrianglesToRaster.begin(),vecTrianglesToRaster.end(),[](triangle&t1,triangle&t2){return (t1.p[0].z+t1.p[1].z+t1.p[2].z)/3.0f>(t2.p[0].z+t2.p[1].z+t2.p[2].z)/3.0f;});
|
|
|
|
|
ClearBuffer(BLACK, true); |
|
|
|
@ -2055,7 +2055,7 @@ void FaceBall::RunEnemyAI(Enemy& e,float fElapsedTime,int myIndex) { |
|
|
|
|
|
|
|
|
|
bool FaceBall::OnUserUpdate(float fElapsedTime) |
|
|
|
|
{ |
|
|
|
|
fElapsedTime = std::min(0.1667f, fElapsedTime); |
|
|
|
|
fElapsedTime = std::min(0.01667f, fElapsedTime); |
|
|
|
|
gameTimer += fElapsedTime; |
|
|
|
|
switch (mode) { |
|
|
|
|
case GAME: { |
|
|
|
|