mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2026-04-27 04:21:47 +00:00
Wait until fully loaded before using framerate cap
This commit is contained in:
parent
35b1a0d63f
commit
23b0a5fcaf
1 changed files with 6 additions and 0 deletions
|
|
@ -20,6 +20,7 @@
|
||||||
#include "r_plane.h"
|
#include "r_plane.h"
|
||||||
#include "p_spec.h"
|
#include "p_spec.h"
|
||||||
#include "r_state.h"
|
#include "r_state.h"
|
||||||
|
#include "console.h" // con_startup_loadprogress
|
||||||
#ifdef HWRENDER
|
#ifdef HWRENDER
|
||||||
#include "hardware/hw_main.h" // for cv_glshearing
|
#include "hardware/hw_main.h" // for cv_glshearing
|
||||||
#endif
|
#endif
|
||||||
|
|
@ -51,6 +52,11 @@ consvar_t cv_fpscap = CVAR_INIT ("fpscap", "Match refresh rate", CV_SAVE, fpscap
|
||||||
|
|
||||||
UINT32 R_GetFramerateCap(void)
|
UINT32 R_GetFramerateCap(void)
|
||||||
{
|
{
|
||||||
|
if (con_startup_loadprogress != LOADED_ALLDONE)
|
||||||
|
{
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
if (cv_fpscap.value < 0)
|
if (cv_fpscap.value < 0)
|
||||||
{
|
{
|
||||||
return I_GetRefreshRate();
|
return I_GetRefreshRate();
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue