First commit 🎉

This commit is contained in:
Tony Bark 2025-07-17 01:49:18 -04:00
commit 43ea213f9b
728 changed files with 37080 additions and 0 deletions

View file

@ -0,0 +1,20 @@
extends HBoxContainer
#region Godot ######################################################################################
func _ready() -> void:
PopochiuUtils.e.command_selected.connect(_on_command_selected)
#endregion
#region Public #####################################################################################
func _on_command_selected() -> void:
for b in get_children():
(b as TextureButton).set_pressed_no_signal(false)
(get_child(PopochiuUtils.e.current_command) as TextureButton).set_pressed_no_signal(true)
PopochiuUtils.cursor.show_cursor(PopochiuUtils.e.get_current_command_name().to_snake_case())
#endregion

View file

@ -0,0 +1 @@
uid://hf44bjih0l8g

View file

@ -0,0 +1 @@
extends "sierra_commands_container.gd"

View file

@ -0,0 +1 @@
uid://c1qis2wgq3wss

View file

@ -0,0 +1,78 @@
extends Control
## Defines the height in pixels of the zone where moving the mouse in the top of the screen will
## make the bar to show. Note: This value will be affected by the Experimental Scale GUI checkbox
## in Project Settings > Popochiu > GUI.
@export var input_zone_height := 4
@onready var panel_container: PanelContainer = $PanelContainer
@onready var inventory = %Inventory
@onready var settings = %Settings
@onready var help = %Help
@onready var quit = %Quit
#region Godot ######################################################################################
func _ready():
inventory.pressed.connect(_on_inventory_pressed)
settings.pressed.connect(_on_settings_pressed)
help.pressed.connect(_on_help_pressed)
quit.pressed.connect(_on_quit_pressed)
hide()
func _input(event: InputEvent) -> void:
if PopochiuUtils.g.is_blocked: return
if event is InputEventMouseMotion:
var rect := panel_container.get_rect()
if not visible:
rect.size.y = input_zone_height
if PopochiuUtils.e.settings.scale_gui:
rect = Rect2(
panel_container.get_rect().position * PopochiuUtils.e.scale,
(Vector2(
panel_container.get_rect().size.x,
panel_container.get_rect().size.y if visible
else panel_container.get_rect().size.y / 2.0
)) * PopochiuUtils.e.scale
)
if not visible and rect.has_point(get_global_mouse_position()):
# Show the top menu
if not PopochiuUtils.i.active:
PopochiuUtils.cursor.show_cursor("gui")
show()
elif visible and not rect.has_point(get_global_mouse_position()):
# Hide the top menu
if not PopochiuUtils.i.active:
PopochiuUtils.cursor.show_cursor(PopochiuUtils.e.get_current_command_name().to_snake_case())
hide()
#endregion
#region Private ####################################################################################
func _on_inventory_pressed() -> void:
hide()
PopochiuUtils.g.popup_requested.emit("SierraInventoryPopup")
func _on_settings_pressed() -> void:
hide()
PopochiuUtils.g.popup_requested.emit("SierraSettingsPopup")
func _on_help_pressed() -> void:
# TODO: Open the help popup
pass
func _on_quit_pressed() -> void:
PopochiuUtils.g.popup_requested.emit("QuitPopup")
#endregion

View file

@ -0,0 +1 @@
uid://c0m0wibnq85lo

View file

@ -0,0 +1,204 @@
[gd_scene load_steps=35 format=3 uid="uid://c0cj1ckrygig8"]
[ext_resource type="Theme" uid="uid://djl1xk7jgyvpp" path="res://game/gui/resources/gui_theme.tres" id="1_ud5cn"]
[ext_resource type="Script" uid="uid://cvkymnm6vq3k0" path="res://game/gui/components/sierra_menu/sierra_menu_custom.gd" id="2_8nno7"]
[ext_resource type="Script" uid="uid://c1qis2wgq3wss" path="res://game/gui/components/sierra_menu/sierra_commands_container_custom.gd" id="3_rs6cd"]
[ext_resource type="Texture2D" uid="uid://dceipb6j03b7u" path="res://game/gui/images/btn_walk.png" id="4_xgctf"]
[ext_resource type="Script" uid="uid://bp2gnas5b8uc6" path="res://game/gui/components/sierra_command_button/sierra_command_button_custom.gd" id="5_nbbu2"]
[ext_resource type="Texture2D" uid="uid://c6j2obrx3bjug" path="res://game/gui/images/btn_look.png" id="6_6t2xu"]
[ext_resource type="Texture2D" uid="uid://mv2x206ftad" path="res://game/gui/images/btn_interact.png" id="7_05ecu"]
[ext_resource type="Texture2D" uid="uid://w8fcambs2g6l" path="res://game/gui/images/btn_talk.png" id="8_fd15y"]
[ext_resource type="Texture2D" uid="uid://lv4c6aalk6xk" path="res://game/gui/images/btn_inventory.png" id="9_wsgk5"]
[ext_resource type="Texture2D" uid="uid://ci5l1spqgxwnf" path="res://game/gui/images/btn_settings.png" id="10_iwmbg"]
[ext_resource type="Texture2D" uid="uid://1bv3yql4x3mr" path="res://game/gui/images/btn_help.png" id="11_ox5dl"]
[ext_resource type="Texture2D" uid="uid://lthnvxmoyv5u" path="res://game/gui/images/btn_quit.png" id="12_w05ne"]
[sub_resource type="AtlasTexture" id="AtlasTexture_csu2p"]
atlas = ExtResource("4_xgctf")
region = Rect2(0, 0, 24, 24)
[sub_resource type="AtlasTexture" id="AtlasTexture_ylk7h"]
atlas = ExtResource("4_xgctf")
region = Rect2(0, 24, 24, 24)
[sub_resource type="AtlasTexture" id="AtlasTexture_ao1oe"]
atlas = ExtResource("4_xgctf")
region = Rect2(0, 24, 24, 24)
[sub_resource type="AtlasTexture" id="AtlasTexture_irg4s"]
atlas = ExtResource("6_6t2xu")
region = Rect2(0, 0, 24, 24)
[sub_resource type="AtlasTexture" id="AtlasTexture_sijr3"]
atlas = ExtResource("6_6t2xu")
region = Rect2(0, 24, 24, 24)
[sub_resource type="AtlasTexture" id="AtlasTexture_msotb"]
atlas = ExtResource("6_6t2xu")
region = Rect2(0, 24, 24, 24)
[sub_resource type="AtlasTexture" id="AtlasTexture_u5ilp"]
atlas = ExtResource("7_05ecu")
region = Rect2(0, 0, 24, 24)
[sub_resource type="AtlasTexture" id="AtlasTexture_nkumn"]
atlas = ExtResource("7_05ecu")
region = Rect2(0, 24, 24, 24)
[sub_resource type="AtlasTexture" id="AtlasTexture_ddbjm"]
atlas = ExtResource("7_05ecu")
region = Rect2(0, 24, 24, 24)
[sub_resource type="AtlasTexture" id="AtlasTexture_r0y6q"]
atlas = ExtResource("8_fd15y")
region = Rect2(0, 0, 24, 24)
[sub_resource type="AtlasTexture" id="AtlasTexture_yyrpv"]
atlas = ExtResource("8_fd15y")
region = Rect2(0, 24, 24, 24)
[sub_resource type="AtlasTexture" id="AtlasTexture_m2m36"]
atlas = ExtResource("8_fd15y")
region = Rect2(0, 24, 24, 24)
[sub_resource type="StyleBoxEmpty" id="StyleBoxEmpty_a3v2b"]
[sub_resource type="AtlasTexture" id="AtlasTexture_uvguw"]
atlas = ExtResource("9_wsgk5")
region = Rect2(0, 0, 24, 24)
[sub_resource type="AtlasTexture" id="AtlasTexture_mdjye"]
atlas = ExtResource("9_wsgk5")
region = Rect2(0, 24, 24, 24)
[sub_resource type="AtlasTexture" id="AtlasTexture_odwa6"]
atlas = ExtResource("9_wsgk5")
region = Rect2(0, 24, 24, 24)
[sub_resource type="AtlasTexture" id="AtlasTexture_wy7fm"]
atlas = ExtResource("10_iwmbg")
region = Rect2(0, 0, 24, 24)
[sub_resource type="AtlasTexture" id="AtlasTexture_eccvv"]
atlas = ExtResource("10_iwmbg")
region = Rect2(0, 24, 24, 24)
[sub_resource type="AtlasTexture" id="AtlasTexture_0ahol"]
atlas = ExtResource("10_iwmbg")
region = Rect2(0, 24, 24, 24)
[sub_resource type="AtlasTexture" id="AtlasTexture_f8jt5"]
atlas = ExtResource("12_w05ne")
region = Rect2(0, 0, 24, 24)
[sub_resource type="AtlasTexture" id="AtlasTexture_c0o1t"]
atlas = ExtResource("12_w05ne")
region = Rect2(0, 24, 24, 24)
[sub_resource type="AtlasTexture" id="AtlasTexture_hs767"]
atlas = ExtResource("12_w05ne")
region = Rect2(0, 24, 24, 24)
[node name="SierraMenu" type="Control" groups=["popochiu_gui_component"]]
layout_mode = 3
anchors_preset = 15
anchor_right = 1.0
anchor_bottom = 1.0
grow_horizontal = 2
grow_vertical = 2
mouse_filter = 2
theme = ExtResource("1_ud5cn")
script = ExtResource("2_8nno7")
[node name="PanelContainer" type="PanelContainer" parent="."]
layout_mode = 1
anchors_preset = 10
anchor_right = 1.0
offset_bottom = 24.0
grow_horizontal = 2
[node name="HBoxContainer" type="HBoxContainer" parent="PanelContainer"]
layout_mode = 2
theme_override_constants/separation = 0
[node name="SierraCommandsContainer" type="HBoxContainer" parent="PanelContainer/HBoxContainer"]
layout_mode = 2
theme_override_constants/separation = 0
script = ExtResource("3_rs6cd")
[node name="Walk" type="TextureButton" parent="PanelContainer/HBoxContainer/SierraCommandsContainer"]
texture_filter = 1
layout_mode = 2
toggle_mode = true
texture_normal = SubResource("AtlasTexture_csu2p")
texture_pressed = SubResource("AtlasTexture_ylk7h")
texture_hover = SubResource("AtlasTexture_ao1oe")
script = ExtResource("5_nbbu2")
[node name="Look" type="TextureButton" parent="PanelContainer/HBoxContainer/SierraCommandsContainer"]
texture_filter = 1
layout_mode = 2
toggle_mode = true
texture_normal = SubResource("AtlasTexture_irg4s")
texture_pressed = SubResource("AtlasTexture_sijr3")
texture_hover = SubResource("AtlasTexture_msotb")
script = ExtResource("5_nbbu2")
command = 1
[node name="Interact" type="TextureButton" parent="PanelContainer/HBoxContainer/SierraCommandsContainer"]
texture_filter = 1
layout_mode = 2
toggle_mode = true
texture_normal = SubResource("AtlasTexture_u5ilp")
texture_pressed = SubResource("AtlasTexture_nkumn")
texture_hover = SubResource("AtlasTexture_ddbjm")
script = ExtResource("5_nbbu2")
command = 2
[node name="Talk" type="TextureButton" parent="PanelContainer/HBoxContainer/SierraCommandsContainer"]
texture_filter = 1
layout_mode = 2
toggle_mode = true
texture_normal = SubResource("AtlasTexture_r0y6q")
texture_pressed = SubResource("AtlasTexture_yyrpv")
texture_hover = SubResource("AtlasTexture_m2m36")
script = ExtResource("5_nbbu2")
command = 3
[node name="PanelContainer" type="PanelContainer" parent="PanelContainer/HBoxContainer"]
texture_filter = 1
layout_mode = 2
size_flags_horizontal = 3
theme_override_styles/panel = SubResource("StyleBoxEmpty_a3v2b")
[node name="Inventory" type="TextureButton" parent="PanelContainer/HBoxContainer"]
unique_name_in_owner = true
texture_filter = 1
layout_mode = 2
texture_normal = SubResource("AtlasTexture_uvguw")
texture_pressed = SubResource("AtlasTexture_mdjye")
texture_hover = SubResource("AtlasTexture_odwa6")
[node name="Settings" type="TextureButton" parent="PanelContainer/HBoxContainer"]
unique_name_in_owner = true
texture_filter = 1
layout_mode = 2
texture_normal = SubResource("AtlasTexture_wy7fm")
texture_pressed = SubResource("AtlasTexture_eccvv")
texture_hover = SubResource("AtlasTexture_0ahol")
[node name="Help" type="TextureButton" parent="PanelContainer/HBoxContainer"]
unique_name_in_owner = true
visible = false
texture_filter = 1
layout_mode = 2
texture_normal = ExtResource("11_ox5dl")
[node name="Quit" type="TextureButton" parent="PanelContainer/HBoxContainer"]
unique_name_in_owner = true
visible = false
texture_filter = 1
layout_mode = 2
texture_normal = SubResource("AtlasTexture_f8jt5")
texture_pressed = SubResource("AtlasTexture_c0o1t")
texture_hover = SubResource("AtlasTexture_hs767")

View file

@ -0,0 +1 @@
extends "sierra_menu.gd"

View file

@ -0,0 +1 @@
uid://cvkymnm6vq3k0