From 8ee37484ca0831d16f7e5c84187eea4a1df777ea Mon Sep 17 00:00:00 2001 From: MSWS Date: Wed, 5 Mar 2025 20:13:58 -0800 Subject: [PATCH] Make timer smaller --- src/Player/PlayerOnTick.cs | 18 +++++++++--------- src/Plugin/Globals.cs | 3 ++- 2 files changed, 11 insertions(+), 10 deletions(-) diff --git a/src/Player/PlayerOnTick.cs b/src/Player/PlayerOnTick.cs index a82e7cd..3dd7bf3 100644 --- a/src/Player/PlayerOnTick.cs +++ b/src/Player/PlayerOnTick.cs @@ -302,16 +302,16 @@ namespace SharpTimer string playerTime = FormatTime(timerTicks); string playerBonusTime = FormatTime(playerTimer.BonusTimerTicks); string timerLine = isBonusTimerRunning - ? $" Bonus #{playerTimer.BonusStage} Timer: {playerBonusTime}
" + ? $" Time: {playerBonusTime}
" : isTimerRunning - ? $" Timer: {playerTime} ({GetPlayerPlacement(player)}){((playerTimer.CurrentMapStage != 0 && useStageTriggers == true) ? $" {playerTimer.CurrentMapStage}/{stageTriggerCount}" : "")}
" + ? $" Time: {playerTime} ({GetPlayerPlacement(player)}){((playerTimer.CurrentMapStage != 0 && useStageTriggers == true) ? $" {playerTimer.CurrentMapStage}/{stageTriggerCount}" : "")}
" : playerTimer.IsReplaying ? $" ◉ REPLAY {FormatTime(playerReplays[playerSlot].CurrentPlaybackFrame)}
" : ""; - string veloLine = $" {(playerTimer.IsTester ? playerTimer.TesterSmolGif : "")}Speed: {(playerTimer.IsReplaying ? "{formattedPlayerVel} ({formattedPlayerPre}){(playerTimer.IsTester ? playerTimer.TesterSmolGif : "")}
"; + string veloLine = $" {(playerTimer.IsTester ? playerTimer.TesterSmolGif : "")}Speed: {(playerTimer.IsReplaying ? "{formattedPlayerVel} ({formattedPlayerPre}){(playerTimer.IsTester ? playerTimer.TesterSmolGif : "")} "; - string syncLine = $"Sync: {playerTimer.Sync:F2}%
";//2f + string syncLine = $"Sync: {playerTimer.Sync:F2}%
";//2f string infoLine = ""; if (playerTimer.CurrentZoneInfo.InBonusStartZone) @@ -364,7 +364,7 @@ namespace SharpTimer $"({playerTimer.CachedMapPlacement})" + $"{(RankIconsEnabled ? $" | " : "")}" + $"{(enableStyles ? $" | {GetNamedStyle(playerTimer.currentStyle)}" : "")}" + - $"{((MapTierHudEnabled && currentMapTier != null) ? $" | Tier: {currentMapTier}" : "")}" + + $"{((MapTierHudEnabled && currentMapTier != null) ? $" | Tier {currentMapTier}" : "")}" + $"{((MapTypeHudEnabled && currentMapType != null) ? $" | {currentMapType}" : "")}" + $"{((MapNameHudEnabled && currentMapType == null && currentMapTier == null) ? $" | {currentMapName}" : "")}" + $"" @@ -418,16 +418,16 @@ namespace SharpTimer string playerTime = FormatTime(timerTicks); string playerBonusTime = FormatTime(playerTimer.BonusTimerTicks); string timerLine = isBonusTimerRunning - ? $" Bonus #{playerTimer.BonusStage} Timer: {playerBonusTime}
" + ? $" Time: {playerBonusTime}
" : isTimerRunning - ? $" Timer: {playerTime} ({GetPlayerPlacement(target)}){((playerTimer.CurrentMapStage != 0 && useStageTriggers == true) ? $" {playerTimer.CurrentMapStage}/{stageTriggerCount}" : "")}
" + ? $" Time: {playerTime} ({GetPlayerPlacement(target)}){((playerTimer.CurrentMapStage != 0 && useStageTriggers == true) ? $" {playerTimer.CurrentMapStage}/{stageTriggerCount}" : "")}
" : playerTimer.IsReplaying ? $" ◉ REPLAY {FormatTime(playerReplays[target.Slot].CurrentPlaybackFrame)}
" : ""; - string veloLine = $" {(playerTimer.IsTester ? playerTimer.TesterSmolGif : "")}Speed: {(playerTimer.IsReplaying ? "{formattedPlayerVel} u/s ({formattedPlayerPre} u/s){(playerTimer.IsTester ? playerTimer.TesterSmolGif : "")}
"; + string veloLine = $" {(playerTimer.IsTester ? playerTimer.TesterSmolGif : "")}Speed: {(playerTimer.IsReplaying ? "{formattedPlayerVel} u/s ({formattedPlayerPre} u/s){(playerTimer.IsTester ? playerTimer.TesterSmolGif : "")} "; - string syncLine = $"Sync: {playerTimer.Sync:F2}%
";//2f + string syncLine = $"Sync: {playerTimer.Sync:F2}%
";//2f string infoLine = ""; if (playerTimer.CurrentZoneInfo.InBonusStartZone) diff --git a/src/Plugin/Globals.cs b/src/Plugin/Globals.cs index 02d0264..17e30d4 100644 --- a/src/Plugin/Globals.cs +++ b/src/Plugin/Globals.cs @@ -163,7 +163,6 @@ namespace SharpTimer public double group4 = 25; public double group5 = 50; - public bool globalChecksPassed = false; public bool globalDisabled = false; public bool displayChatTags = true; @@ -306,6 +305,8 @@ namespace SharpTimer public bool discordWebhookSteamLink = true; public bool discordWebhookDisableStyleRecords = false; + public string timerSize = "fontSize-l", velocitySize = "fontSize-ml", labelSize = "fontSize-s", syncSize = "fontSize-ml"; + public string? remoteBhopDataSource = "https://raw.githubusercontent.com/Letaryat/poor-SharpTimer/main/remote_data/bhop_.json"; public string? remoteKZDataSource = "https://raw.githubusercontent.com/Letaryat/poor-SharpTimer/main/remote_data/kz_.json"; public string? remoteSurfDataSource = "https://raw.githubusercontent.com/Letaryat/poor-SharpTimer/main/remote_data/surf_.json";