shithub: cstory

Download patch

ref: 7cff8914528c0f0ba4360c2e9f32cb0a7dc0ff86
parent: 0c367cecf7ff5236dc8e2005fffae254c400a1fc
author: Clownacy <Clownacy@users.noreply.github.com>
date: Thu Sep 3 17:31:49 EDT 2020

Remove that FRAMERATE thing

--- a/src/Draw.cpp
+++ b/src/Draw.cpp
@@ -56,8 +56,6 @@
 static int client_x;
 static int client_y;
 
-#define FRAMERATE 20
-
 void SetClientOffset(int width, int height)
 {
 	client_x = width;
@@ -78,7 +76,7 @@
 		// Framerate limiter
 		timeNow = GetTickCount();
 
-		if (timeNow >= timePrev + FRAMERATE)
+		if (timeNow >= timePrev + 20)
 			break;
 
 		Sleep(1);
@@ -87,7 +85,7 @@
 	if (timeNow >= timePrev + 100)
 		timePrev = timeNow;	// If the timer is freakishly out of sync, panic and reset it, instead of spamming frames for who-knows how long
 	else
-		timePrev += FRAMERATE;
+		timePrev += 20;
 
 	static RECT dst_rect;	// TODO - Not the original vaiable name
 	GetWindowRect(hWnd, &dst_rect);