Minor changes and fixes around tick warping
When warping and frozen the game will now run at 20 (frozen) TPS instead of as fast as possible around a loop Frozen ticks will no longer count towards tick warping TPS logger will now display `TPS: 0.0` when the game is frozen
This commit is contained in:
2 files changed
+12
-11
No files matched your search
@@ -176,6 +176,8 @@ public class TickSpeed
|
||||
|
||||
public static boolean continueWarp()
|
||||
{
|
||||
if (!process_entities)
|
||||
return false;
|
||||
if (time_bias > 0)
|
||||
{
|
||||
if (time_bias == time_warp_scheduled_ticks) //first call after previous tick, adjust start time
|
||||
@@ -194,25 +196,21 @@ public class TickSpeed
|
||||
|
||||
public static void tick()
|
||||
{
|
||||
process_entities = true;
|
||||
if (player_active_timeout > 0)
|
||||
{
|
||||
player_active_timeout--;
|
||||
}
|
||||
if (is_paused)
|
||||
{
|
||||
if (player_active_timeout < PLAYER_GRACE)
|
||||
{
|
||||
process_entities = false;
|
||||
}
|
||||
process_entities = player_active_timeout < PLAYER_GRACE;
|
||||
}
|
||||
else if (is_superHot)
|
||||
{
|
||||
if (player_active_timeout <= 0)
|
||||
{
|
||||
process_entities = false;
|
||||
|
||||
}
|
||||
process_entities = player_active_timeout <= 0;
|
||||
}
|
||||
else
|
||||
{
|
||||
process_entities = true;
|
||||
}
|
||||
}
|
||||
//unused - mod compat reasons
|
||||
@@ -227,7 +225,7 @@ public class TickSpeed
|
||||
tickrate = 1000.0f;
|
||||
}
|
||||
|
||||
TickSpeed.mspt = (float)mspt;
|
||||
TickSpeed.mspt = mspt;
|
||||
|
||||
if (update) notifyTickrateListeners("carpet");
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user