-
Notifications
You must be signed in to change notification settings - Fork 0
Remap menu #76
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remap menu #76
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -60,6 +60,7 @@ public enum Stages | |
| Boss, | ||
| Quit, | ||
| Map, | ||
| Controls, | ||
| } | ||
|
|
||
| public class MapGrid | ||
|
|
||
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -56,6 +56,33 @@ private void InitializeArrowCheckers() | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| public override void _Ready() | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| InitializeArrowCheckers(); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| LoadControlScheme(); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| private void LoadControlScheme() | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| string scheme = ProjectSettings.HasSetting("game/input_scheme") | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ? (string)ProjectSettings.GetSetting("game/input_scheme") | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| : "ARROWS"; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| foreach (var arrow in Arrows) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| var events = InputMap.ActionGetEvents(arrow.Key); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| foreach (var inputEvent in events) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| InputMap.ActionEraseEvent(arrow.Key, inputEvent); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| var selectedScheme = ControlSchemes.Schemes[scheme]; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| foreach (var arrow in Arrows) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| if (selectedScheme.ContainsKey(arrow.Key)) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| InputEventKey eventKey = new InputEventKey(); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| eventKey.Keycode = (Key)Enum.Parse(typeof(Key), selectedScheme[arrow.Key]); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| InputMap.ActionAddEvent(arrow.Key, eventKey); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Comment on lines
+76
to
+85
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Add null safety and error handling. The code should handle cases where:
- var selectedScheme = ControlSchemes.Schemes[scheme];
+ if (!ControlSchemes.Schemes.TryGetValue(scheme, out var selectedScheme))
+ {
+ GD.PrintErr($"Control scheme '{scheme}' not found, defaulting to ARROWS");
+ selectedScheme = ControlSchemes.Schemes["ARROWS"];
+ }
foreach (var arrow in Arrows)
{
if (selectedScheme.ContainsKey(arrow.Key))
{
- InputEventKey eventKey = new InputEventKey();
- eventKey.Keycode = (Key)Enum.Parse(typeof(Key), selectedScheme[arrow.Key]);
- InputMap.ActionAddEvent(arrow.Key, eventKey);
+ try
+ {
+ InputEventKey eventKey = new InputEventKey();
+ eventKey.Keycode = (Key)Enum.Parse(typeof(Key), selectedScheme[arrow.Key]);
+ InputMap.ActionAddEvent(arrow.Key, eventKey);
+ }
+ catch (ArgumentException ex)
+ {
+ GD.PrintErr($"Invalid key value '{selectedScheme[arrow.Key]}' for {arrow.Key}: {ex.Message}");
+ }
}📝 Committable suggestion
Suggested change
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| public override void _Process(double delta) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,79 @@ | ||
| using System.Collections.Generic; | ||
| using Godot; | ||
|
|
||
| public static class ControlSchemes | ||
| { | ||
| public static Dictionary<string, Dictionary<string, string>> Schemes = new Dictionary< | ||
| string, | ||
| Dictionary<string, string> | ||
| >() | ||
| { | ||
| { | ||
| "WASD", | ||
| new Dictionary<string, string>() | ||
| { | ||
| { "arrowUp", "W" }, | ||
| { "arrowDown", "S" }, | ||
| { "arrowLeft", "A" }, | ||
| { "arrowRight", "D" }, | ||
| } | ||
| }, | ||
| { | ||
| "ARROWS", | ||
| new Dictionary<string, string>() | ||
| { | ||
| { "arrowUp", "Up" }, | ||
| { "arrowDown", "Down" }, | ||
| { "arrowLeft", "Left" }, | ||
| { "arrowRight", "Right" }, | ||
| } | ||
| }, | ||
| { | ||
| "QWERT", | ||
| new Dictionary<string, string>() | ||
| { | ||
| { "arrowUp", "E" }, | ||
| { "arrowDown", "W" }, | ||
| { "arrowLeft", "Q" }, | ||
| { "arrowRight", "R" }, | ||
| } | ||
| }, | ||
| }; | ||
|
|
||
| public static Dictionary<string, Dictionary<string, string>> SpriteMappings = new Dictionary< | ||
| string, | ||
| Dictionary<string, string> | ||
| >() | ||
| { | ||
| { | ||
| "WASD", | ||
| new Dictionary<string, string>() | ||
| { | ||
| { "left", "res://scenes/Remapping/assets/A_Key_Light.png" }, | ||
| { "right", "res://scenes/Remapping/assets/D_Key_Light.png" }, | ||
| { "up", "res://scenes/Remapping/assets/W_Key_Light.png" }, | ||
| { "down", "res://scenes/Remapping/assets/S_Key_Light.png" }, | ||
| } | ||
| }, | ||
| { | ||
| "ARROWS", | ||
| new Dictionary<string, string>() | ||
| { | ||
| { "left", "res://scenes/Remapping/assets/Arrow_Left_Key_Light.png" }, | ||
| { "right", "res://scenes/Remapping/assets/Arrow_Right_Key_Light.png" }, | ||
| { "up", "res://scenes/Remapping/assets/Arrow_Up_Key_Light.png" }, | ||
| { "down", "res://scenes/Remapping/assets/Arrow_Down_Key_Light.png" }, | ||
| } | ||
| }, | ||
| { | ||
| "QWERT", | ||
| new Dictionary<string, string>() | ||
| { | ||
| { "left", "res://scenes/Remapping/assets/Q_Key_Light.png" }, | ||
| { "right", "res://scenes/Remapping/assets/R_Key_Light.png" }, | ||
| { "up", "res://scenes/Remapping/assets/E_Key_Light.png" }, | ||
| { "down", "res://scenes/Remapping/assets/W_Key_Light.png" }, | ||
| } | ||
| }, | ||
| }; | ||
| } |
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,65 @@ | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| using System; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| using Godot; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||
| public partial class ControlSettings : Node2D | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| [Export] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| public Sprite2D leftKey; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||
| [Export] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| public Sprite2D rightKey; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||
| [Export] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| public Sprite2D upKey; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||
| [Export] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| public Sprite2D downKey; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||
| public override void _Ready() | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| GetNode<Button>("Panel/WASDButton").Connect("pressed", Callable.From(OnWASDButtonPressed)); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| GetNode<Button>("Panel/ArrowButton") | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| .Connect("pressed", Callable.From(OnArrowButtonPressed)); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| GetNode<Button>("Panel/QWERTButton") | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| .Connect("pressed", Callable.From(OnQWERTButtonPressed)); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||
| string scheme = ProjectSettings.HasSetting("game/input_scheme") | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ? (string)ProjectSettings.GetSetting("game/input_scheme") | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| : "ARROWS"; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ChangeKeySprites(scheme); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||
| private void OnWASDButtonPressed() | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| GetNode<Label>("Panel/Label").Text = "WASD Selected"; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ProjectSettings.SetSetting("game/input_scheme", "WASD"); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ProjectSettings.Save(); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ChangeKeySprites("WASD"); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||
| private void OnArrowButtonPressed() | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| GetNode<Label>("Panel/Label").Text = "Arrow Selected"; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ProjectSettings.SetSetting("game/input_scheme", "ARROWS"); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ProjectSettings.Save(); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ChangeKeySprites("ARROWS"); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||
| private void OnQWERTButtonPressed() | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| GetNode<Label>("Panel/Label").Text = "QWERT Selected"; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ProjectSettings.SetSetting("game/input_scheme", "QWERT"); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ProjectSettings.Save(); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ChangeKeySprites("QWERT"); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||
| private void ChangeKeySprites(string scheme) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| var selectedScheme = ControlSchemes.SpriteMappings[scheme]; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| GD.Print(scheme); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| leftKey.Texture = GD.Load<Texture2D>(selectedScheme["left"]); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| rightKey.Texture = GD.Load<Texture2D>(selectedScheme["right"]); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| upKey.Texture = GD.Load<Texture2D>(selectedScheme["up"]); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| downKey.Texture = GD.Load<Texture2D>(selectedScheme["down"]); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Comment on lines
+58
to
+63
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🛠️ Refactor suggestion Add error handling for sprite mappings. The code assumes the scheme exists in Add error handling: private void ChangeKeySprites(string scheme)
{
+ if (!ControlSchemes.SpriteMappings.ContainsKey(scheme))
+ {
+ GD.PrintErr($"Unknown control scheme: {scheme}");
+ return;
+ }
var selectedScheme = ControlSchemes.SpriteMappings[scheme];
- GD.Print(scheme);
+ try
+ {
leftKey.Texture = GD.Load<Texture2D>(selectedScheme["left"]);
rightKey.Texture = GD.Load<Texture2D>(selectedScheme["right"]);
upKey.Texture = GD.Load<Texture2D>(selectedScheme["up"]);
downKey.Texture = GD.Load<Texture2D>(selectedScheme["down"]);
+ }
+ catch (Exception e)
+ {
+ GD.PrintErr($"Failed to load textures for scheme {scheme}: {e.Message}");
+ }
}📝 Committable suggestion
Suggested change
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,140 @@ | ||||||||||||||||||||||||||||||
| [gd_scene load_steps=9 format=3 uid="uid://bew23sumjs0fg"] | ||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||
| [ext_resource type="Script" path="res://scenes/Remapping/ControlSettings.cs" id="1_ir12b"] | ||||||||||||||||||||||||||||||
| [ext_resource type="Script" path="res://scenes/Remapping/ControlSchemes.cs" id="1_n6sxo"] | ||||||||||||||||||||||||||||||
| [ext_resource type="Script" path="res://scenes/SceneTransitions/scripts/SceneChange.cs" id="2_oippk"] | ||||||||||||||||||||||||||||||
| [ext_resource type="Texture2D" uid="uid://xtygvpk7s8e4" path="res://scenes/NoteManager/assets/outline_white.png" id="4_se2m3"] | ||||||||||||||||||||||||||||||
| [ext_resource type="Texture2D" uid="uid://cr6wtf6j6dcfg" path="res://scenes/Remapping/assets/Arrow_Left_Key_Light.png" id="5_xn13c"] | ||||||||||||||||||||||||||||||
| [ext_resource type="Texture2D" uid="uid://q14p8ypgc43t" path="res://scenes/Remapping/assets/Arrow_Down_Key_Light.png" id="6_qrl0g"] | ||||||||||||||||||||||||||||||
| [ext_resource type="Texture2D" uid="uid://p06451gq2ujc" path="res://scenes/Remapping/assets/Arrow_Up_Key_Light.png" id="7_1a2jy"] | ||||||||||||||||||||||||||||||
| [ext_resource type="Texture2D" uid="uid://dvlekute37smy" path="res://scenes/Remapping/assets/Arrow_Right_Key_Light.png" id="8_o7swo"] | ||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||
| [node name="Remap" type="Node2D" node_paths=PackedStringArray("leftKey", "rightKey", "upKey", "downKey")] | ||||||||||||||||||||||||||||||
| script = ExtResource("1_ir12b") | ||||||||||||||||||||||||||||||
| leftKey = NodePath("Panel/Control/LeftRemap") | ||||||||||||||||||||||||||||||
| rightKey = NodePath("Panel/Control/RightRemap") | ||||||||||||||||||||||||||||||
| upKey = NodePath("Panel/Control/UpRemap") | ||||||||||||||||||||||||||||||
| downKey = NodePath("Panel/Control/DownRemap") | ||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||
| [node name="Panel" type="Panel" parent="."] | ||||||||||||||||||||||||||||||
| offset_left = 4.0 | ||||||||||||||||||||||||||||||
| offset_top = 4.0 | ||||||||||||||||||||||||||||||
| offset_right = 638.0 | ||||||||||||||||||||||||||||||
| offset_bottom = 346.0 | ||||||||||||||||||||||||||||||
| script = ExtResource("1_n6sxo") | ||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||
| [node name="Label" type="Label" parent="Panel"] | ||||||||||||||||||||||||||||||
| layout_mode = 2 | ||||||||||||||||||||||||||||||
| offset_top = 9.0 | ||||||||||||||||||||||||||||||
| offset_right = 642.0 | ||||||||||||||||||||||||||||||
| offset_bottom = 32.0 | ||||||||||||||||||||||||||||||
| text = "Choose Control Scheme" | ||||||||||||||||||||||||||||||
| horizontal_alignment = 1 | ||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||
| [node name="WASDButton" type="Button" parent="Panel"] | ||||||||||||||||||||||||||||||
| layout_mode = 2 | ||||||||||||||||||||||||||||||
| offset_left = 453.0 | ||||||||||||||||||||||||||||||
| offset_top = 66.0 | ||||||||||||||||||||||||||||||
| offset_right = 558.0 | ||||||||||||||||||||||||||||||
| offset_bottom = 97.0 | ||||||||||||||||||||||||||||||
| text = "WASD" | ||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||
| [node name="ArrowButton" type="Button" parent="Panel"] | ||||||||||||||||||||||||||||||
| layout_mode = 0 | ||||||||||||||||||||||||||||||
| offset_left = 458.0 | ||||||||||||||||||||||||||||||
| offset_top = 111.0 | ||||||||||||||||||||||||||||||
| offset_right = 554.0 | ||||||||||||||||||||||||||||||
| offset_bottom = 142.0 | ||||||||||||||||||||||||||||||
| text = "Arrow Keys" | ||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||
| [node name="QWERTButton" type="Button" parent="Panel"] | ||||||||||||||||||||||||||||||
| layout_mode = 0 | ||||||||||||||||||||||||||||||
| offset_left = 459.0 | ||||||||||||||||||||||||||||||
| offset_top = 152.0 | ||||||||||||||||||||||||||||||
| offset_right = 555.0 | ||||||||||||||||||||||||||||||
| offset_bottom = 183.0 | ||||||||||||||||||||||||||||||
| text = "QWER" | ||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||
|
Comment on lines
+50
to
+57
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Fix inconsistent button label. The button is labeled as "QWER" but the code in Either update the button text to match the scheme or update the scheme identifier in the code: -text = "QWER"
+text = "QWERT"📝 Committable suggestion
Suggested change
|
||||||||||||||||||||||||||||||
| [node name="TitleButton" type="Button" parent="Panel"] | ||||||||||||||||||||||||||||||
| layout_mode = 0 | ||||||||||||||||||||||||||||||
| offset_left = 431.0 | ||||||||||||||||||||||||||||||
| offset_top = 291.0 | ||||||||||||||||||||||||||||||
| offset_right = 607.0 | ||||||||||||||||||||||||||||||
| offset_bottom = 322.0 | ||||||||||||||||||||||||||||||
| text = "Return to Title Screen" | ||||||||||||||||||||||||||||||
| script = ExtResource("2_oippk") | ||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||
| [node name="Control" type="Control" parent="Panel"] | ||||||||||||||||||||||||||||||
| layout_mode = 3 | ||||||||||||||||||||||||||||||
| anchors_preset = 0 | ||||||||||||||||||||||||||||||
| offset_left = -4.0 | ||||||||||||||||||||||||||||||
| offset_top = -4.0 | ||||||||||||||||||||||||||||||
| offset_right = 36.0 | ||||||||||||||||||||||||||||||
| offset_bottom = 36.0 | ||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||
| [node name="Right" type="Sprite2D" parent="Panel/Control"] | ||||||||||||||||||||||||||||||
| position = Vector2(67, 85) | ||||||||||||||||||||||||||||||
| rotation = -3.14159 | ||||||||||||||||||||||||||||||
| texture = ExtResource("4_se2m3") | ||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||
| [node name="Left" type="Sprite2D" parent="Panel/Control"] | ||||||||||||||||||||||||||||||
| position = Vector2(67, 139) | ||||||||||||||||||||||||||||||
| rotation = 1.5708 | ||||||||||||||||||||||||||||||
| texture = ExtResource("4_se2m3") | ||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||
| [node name="Up" type="Sprite2D" parent="Panel/Control"] | ||||||||||||||||||||||||||||||
| position = Vector2(67, 196) | ||||||||||||||||||||||||||||||
| rotation = -1.5708 | ||||||||||||||||||||||||||||||
| texture = ExtResource("4_se2m3") | ||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||
| [node name="Down" type="Sprite2D" parent="Panel/Control"] | ||||||||||||||||||||||||||||||
| position = Vector2(68, 249) | ||||||||||||||||||||||||||||||
| texture = ExtResource("4_se2m3") | ||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||
| [node name="Label" type="Label" parent="Panel/Control"] | ||||||||||||||||||||||||||||||
| offset_left = 95.0 | ||||||||||||||||||||||||||||||
| offset_top = 74.0 | ||||||||||||||||||||||||||||||
| offset_right = 108.0 | ||||||||||||||||||||||||||||||
| offset_bottom = 97.0 | ||||||||||||||||||||||||||||||
| text = "=" | ||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||
| [node name="Label2" type="Label" parent="Panel/Control"] | ||||||||||||||||||||||||||||||
| offset_left = 94.0 | ||||||||||||||||||||||||||||||
| offset_top = 128.0 | ||||||||||||||||||||||||||||||
| offset_right = 107.0 | ||||||||||||||||||||||||||||||
| offset_bottom = 151.0 | ||||||||||||||||||||||||||||||
| text = "=" | ||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||
| [node name="Label3" type="Label" parent="Panel/Control"] | ||||||||||||||||||||||||||||||
| offset_left = 96.0 | ||||||||||||||||||||||||||||||
| offset_top = 187.0 | ||||||||||||||||||||||||||||||
| offset_right = 109.0 | ||||||||||||||||||||||||||||||
| offset_bottom = 210.0 | ||||||||||||||||||||||||||||||
| text = "=" | ||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||
| [node name="Label4" type="Label" parent="Panel/Control"] | ||||||||||||||||||||||||||||||
| offset_left = 96.0 | ||||||||||||||||||||||||||||||
| offset_top = 239.0 | ||||||||||||||||||||||||||||||
| offset_right = 109.0 | ||||||||||||||||||||||||||||||
| offset_bottom = 262.0 | ||||||||||||||||||||||||||||||
| text = "=" | ||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||
| [node name="LeftRemap" type="Sprite2D" parent="Panel/Control"] | ||||||||||||||||||||||||||||||
| position = Vector2(147, 87) | ||||||||||||||||||||||||||||||
| scale = Vector2(0.62, 0.62) | ||||||||||||||||||||||||||||||
| texture = ExtResource("5_xn13c") | ||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||
| [node name="DownRemap" type="Sprite2D" parent="Panel/Control"] | ||||||||||||||||||||||||||||||
| position = Vector2(148, 139) | ||||||||||||||||||||||||||||||
| scale = Vector2(0.62, 0.62) | ||||||||||||||||||||||||||||||
| texture = ExtResource("6_qrl0g") | ||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||
| [node name="UpRemap" type="Sprite2D" parent="Panel/Control"] | ||||||||||||||||||||||||||||||
| position = Vector2(148, 197) | ||||||||||||||||||||||||||||||
| scale = Vector2(0.62, 0.62) | ||||||||||||||||||||||||||||||
| texture = ExtResource("7_1a2jy") | ||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||
| [node name="RightRemap" type="Sprite2D" parent="Panel/Control"] | ||||||||||||||||||||||||||||||
| position = Vector2(150, 255) | ||||||||||||||||||||||||||||||
| scale = Vector2(0.62, 0.62) | ||||||||||||||||||||||||||||||
| texture = ExtResource("8_o7swo") | ||||||||||||||||||||||||||||||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fix conflicting and unintuitive key mappings.
There are several issues with the key mappings:
arrowDownmaps to 'W' which conflicts witharrowUpConsider this alternative mapping:
Also applies to: 51-51, 58-58, 65-65