summaryrefslogtreecommitdiffstats
path: root/src/core/main.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/main.cpp')
-rw-r--r--src/core/main.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/core/main.cpp b/src/core/main.cpp
index f1346fc0..af0d556a 100644
--- a/src/core/main.cpp
+++ b/src/core/main.cpp
@@ -201,6 +201,9 @@ DoRWStuffStartOfFrame(int16 TopRed, int16 TopGreen, int16 TopBlue, int16 BottomR
if(!RsCameraBeginUpdate(Scene.camera))
return false;
+#ifdef FIX_BUGS
+ CSprite2d::SetRecipNearClip();
+#endif
CSprite2d::InitPerFrame();
if(Alpha != 0)
@@ -1107,8 +1110,13 @@ DisplayGameDebugText()
#endif // #ifdef DRAW_GAME_VERSION_TEXT
FrameSamples++;
+#ifdef FIX_BUGS
+ FramesPerSecondCounter += frameTime / 1000.f; // convert to seconds
+ FramesPerSecond = FrameSamples / FramesPerSecondCounter;
+#else
FramesPerSecondCounter += 1000.0f / (CTimer::GetTimeStepNonClippedInSeconds() * 1000.0f);
FramesPerSecond = FramesPerSecondCounter / FrameSamples;
+#endif
if ( FrameSamples > 30 )
{