From 106a74589e5c78be3c91ea9eed2319a0bbc1c846 Mon Sep 17 00:00:00 2001 From: noobour Date: Thu, 20 Aug 2026 21:54:32 -0400 Subject: [PATCH 1/4] chore: hide video button on map info container its not used so --- prefabs/map_info_container.tscn | 1 + 1 file changed, 1 insertion(+) diff --git a/prefabs/map_info_container.tscn b/prefabs/map_info_container.tscn index 23f39bb..db3771d 100644 --- a/prefabs/map_info_container.tscn +++ b/prefabs/map_info_container.tscn @@ -382,6 +382,7 @@ icon = ExtResource("5_1m5pv") icon_alignment = 1 [node name="Video" type="Button" parent="Info/ScrollContainer/HBoxContainer/Subholder/Buttons" unique_id=1985048325] +visible = false layout_mode = 2 tooltip_text = "Add Video" focus_mode = 0 From 1c7bdae1a86b8f5f3d838d36f888585960efd21b Mon Sep 17 00:00:00 2001 From: noobour Date: Fri, 28 Aug 2026 13:46:22 -0400 Subject: [PATCH 2/4] fix: PHXM import duplicates and metadata failing Weird potential side effect of this is that it caches duplicate maps now, oh and it MAY not be able to update maps by just dragging in newer copies, you might have to delete it, but idk i havent tested that someone else can --- scripts/map/Map.cs | 2 +- scripts/map/MapParser.cs | 13 +++++++------ 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/scripts/map/Map.cs b/scripts/map/Map.cs index 15218a2..22374ce 100644 --- a/scripts/map/Map.cs +++ b/scripts/map/Map.cs @@ -147,7 +147,7 @@ public Map(string folderPath, Note[] data = null, string id = null, string artis VideoBuffer = videoBuffer; Notes = data ?? []; Length = length ?? Notes[^1].Millisecond; - Name = id?.Replace(" ", "_") ?? new Regex("[^a-zA-Z0-9_-]").Replace($"{Mappers.Stringify()}_{PrettyTitle}".Replace(" ", "_"), ""); + Name = Path.GetFileNameWithoutExtension(FolderPath); AudioExt = (AudioBuffer != null && Encoding.UTF8.GetString(AudioBuffer[0..4]) == "OggS") ? "ogg" : "mp3"; MapManager.Sanitize(this); diff --git a/scripts/map/MapParser.cs b/scripts/map/MapParser.cs index f1a2b32..66325a6 100644 --- a/scripts/map/MapParser.cs +++ b/scripts/map/MapParser.cs @@ -70,12 +70,12 @@ await Task.Run(() => public static void ExportEncode(Map map) { /* - The reason we re-decode it is because the cut down map cache's map list does not - have the buffers to save time and memory. So if we decode it, we can get the - buffers without having to deal with other annoying shit + The reason we re-decode it is because the cut down map cache's map list does not + have the buffers to save time and memory. So if we decode it, we can get the + buffers without having to deal with other annoying shit - -fog - */ + -fog + */ Map decodedMap = Decode(map.FolderPath); string exportPath = $"{Constants.USER_FOLDER}/export/"; @@ -157,7 +157,6 @@ public static void Encode(Map map, bool logBenchmark = false) 1 byte OR int32; y */ - File.WriteAllText(Path.Combine(mapFolderPath, "metadata.json"), map.EncodeMeta()); using var stream = File.Create(Path.Combine(mapFolderPath, "objects.phxmo")); // using BinaryWriter bw = new BinaryWriter(stream); @@ -209,6 +208,8 @@ void addAsset(string name, byte[] buffer) if (map.CoverBuffer != null) addAsset($"cover.png", map.CoverBuffer); if (map.VideoBuffer != null) addAsset($"video.mp4", map.VideoBuffer); + File.WriteAllText(Path.Combine(mapFolderPath, "metadata.json"), map.EncodeMeta()); + byte[] hash = Misc.HashFiles([Path.Combine(mapFolderPath, "metadata.json"), Path.Combine(mapFolderPath, "objects.phxmo")]); map.MetadataObjectHash = BitConverter.ToString(hash).Replace("-", "").ToLower(); From 796d352de98e7124c680178b2bd6e2ee14cdd183 Mon Sep 17 00:00:00 2001 From: noobour Date: Tue, 1 Sep 2026 17:02:37 -0400 Subject: [PATCH 3/4] Feat: Replay UI touch up, orthonogal camera in replay yup --- scenes/game.tscn | 77 ++++++++++++++++++++++++-- scripts/PlayerInputController.cs | 7 ++- scripts/game/managers/ReplayManager.cs | 21 ++++++- scripts/scenes/Game.cs | 9 +++ 4 files changed, 108 insertions(+), 6 deletions(-) diff --git a/scenes/game.tscn b/scenes/game.tscn index 4d2f421..4f971de 100644 --- a/scenes/game.tscn +++ b/scenes/game.tscn @@ -216,7 +216,16 @@ font_size = 18 font_color = Color(1, 1, 1, 0.8) [sub_resource type="StyleBoxFlat" id="StyleBoxFlat_sijr0"] -bg_color = Color(0.1072, 0.0896, 0.16, 0.25098) +bg_color = Color(0, 0, 0, 0.8784314) +border_width_left = 2 +border_width_top = 2 +border_width_right = 2 +border_width_bottom = 2 +border_color = Color(0, 0, 0, 0.6) +corner_radius_top_left = 12 +corner_radius_top_right = 12 +corner_radius_bottom_right = 12 +corner_radius_bottom_left = 12 [sub_resource type="LabelSettings" id="LabelSettings_a70tm"] font_color = Color(1, 1, 1, 0.25098) @@ -756,7 +765,7 @@ size = Vector2i(1280, 720) render_target_update_mode = 0 [node name="ReplayViewer" type="Panel" parent="." unique_id=1117476839] -visible = false +self_modulate = Color(1, 1, 1, 0) anchors_preset = 12 anchor_top = 1.0 anchor_right = 1.0 @@ -770,12 +779,56 @@ grow_vertical = 2 mouse_filter = 2 theme_override_styles/panel = SubResource("StyleBoxFlat_sijr0") -[node name="Label" type="Label" parent="ReplayViewer" unique_id=919285545] +[node name="OrthogonalPanel" type="Panel" parent="ReplayViewer" unique_id=816223519] +light_mask = 512 +visibility_layer = 512 +z_index = -1 +z_as_relative = false +layout_mode = 1 +offset_left = -5.0 +offset_top = -283.0 +offset_right = 259.0 +offset_bottom = -19.0 +offset_transform_enabled = true +offset_transform_pivot_ratio = Vector2(1, 1) +offset_transform_visual_only = false +mouse_filter = 2 +theme_override_styles/panel = SubResource("StyleBoxFlat_sijr0") + +[node name="OrthogonalCamera" type="SubViewportContainer" parent="ReplayViewer/OrthogonalPanel" unique_id=468959325] +layout_mode = 1 +anchors_preset = 8 +anchor_left = 0.5 +anchor_top = 0.5 +anchor_right = 0.5 +anchor_bottom = 0.5 +offset_left = -128.0 +offset_top = -128.0 +offset_right = 128.0 +offset_bottom = 128.0 +grow_horizontal = 2 +grow_vertical = 2 +offset_transform_enabled = true + +[node name="SubViewport" type="SubViewport" parent="ReplayViewer/OrthogonalPanel/OrthogonalCamera" unique_id=559747074] +transparent_bg = true +handle_input_locally = false +scaling_3d_mode = 5 +size = Vector2i(256, 256) +render_target_update_mode = 4 + +[node name="Camera3D" type="Camera3D" parent="ReplayViewer/OrthogonalPanel/OrthogonalCamera/SubViewport" unique_id=1970241273] +transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0.44182658) +top_level = true +projection = 1 +size = 3.1727066 + +[node name="Tip" type="Label" parent="ReplayViewer" unique_id=919285545] layout_mode = 1 anchors_preset = -1 offset_right = 40.0 grow_vertical = 0 -text = "Press F2 to toggle" +text = "Press F2 to hide replay UI, F3 to hide orthogonal camera" label_settings = SubResource("LabelSettings_a70tm") [node name="Time" type="Label" parent="ReplayViewer" unique_id=1277133470] @@ -818,6 +871,21 @@ max_value = 1.0 step = 0.0 ticks_position = 3 +[node name="Background" type="Panel" parent="ReplayViewer" unique_id=375982619] +light_mask = 512 +visibility_layer = 512 +z_index = -1 +layout_mode = 1 +anchors_preset = 12 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_top = -52.0 +grow_horizontal = 2 +grow_vertical = 0 +mouse_filter = 2 +theme_override_styles/panel = SubResource("StyleBoxFlat_sijr0") + [node name="NotificationHolder" type="VBoxContainer" parent="." unique_id=1425635507] anchors_preset = 3 anchor_left = 1.0 @@ -961,6 +1029,7 @@ theme_override_font_sizes/font_size = 28 text = "GIVE UP" [node name="Transition" type="ColorRect" parent="." unique_id=784178581] +visible = false self_modulate = Color(1, 1, 1, 0) anchors_preset = 15 anchor_right = 1.0 diff --git a/scripts/PlayerInputController.cs b/scripts/PlayerInputController.cs index cb952d4..6cd1fe5 100644 --- a/scripts/PlayerInputController.cs +++ b/scripts/PlayerInputController.cs @@ -1,4 +1,4 @@ -using System; +using System; using Godot; public partial class PlayerInputController : Node @@ -18,6 +18,7 @@ public partial class PlayerInputController : Node public event Action OnTogglePaused; public event Action OnRestartPressed; public event Action OnToggleReplayViewerVisibility; + public event Action OnToggleShowOrthonogalCamera; public event Action OnPauseOrSkipPressed; public event Action OnPauseOrSkipReleased; public event Action OnToggleFade; @@ -42,6 +43,7 @@ private void handleInput(InputEvent @event) break; case InputEventKey { PhysicalKeycode: Key.Escape }: case InputEventKey { PhysicalKeycode: Key.F2 }: + case InputEventKey { PhysicalKeycode: Key.F3 }: case InputEventKey { PhysicalKeycode: Key.Space }: case InputEventKey { PhysicalKeycode: Key.F }: case InputEventKey { PhysicalKeycode: Key.P }: @@ -101,6 +103,9 @@ private void handleKeyboardInput(InputEvent @event) case { PhysicalKeycode: Key.F2 }: OnToggleReplayViewerVisibility?.Invoke(); break; + case { PhysicalKeycode: Key.F3 }: + OnToggleShowOrthonogalCamera?.Invoke(); + break; case { PhysicalKeycode: Key.F }: OnToggleFade?.Invoke(); break; diff --git a/scripts/game/managers/ReplayManager.cs b/scripts/game/managers/ReplayManager.cs index ac6b855..7bce3d6 100644 --- a/scripts/game/managers/ReplayManager.cs +++ b/scripts/game/managers/ReplayManager.cs @@ -19,10 +19,14 @@ public enum Mode [Export] public CursorManager CursorManager { get; private set; } public bool ViewerVisible; + public bool CanShow; // only public variable because of Game public static TextureButton SeekerPause; + private static Panel orthogonalPanel; private static Label seekerTime; + private static Label tip; + private static Panel background; private static HSlider seekerTimeline; private static bool seekerHovered; public float ReplayLength; @@ -148,8 +152,11 @@ public override void _Ready() base._Ready(); // this entire code lowkey sucks, so i am just copy and pasting it because i am lazy -fog + orthogonalPanel = ReplayViewer.GetNode("OrthogonalPanel"); SeekerPause = ReplayViewer.GetNode("Pause"); seekerTime = ReplayViewer.GetNode