1
Fork 0
mirror of https://github.com/Steffo99/hella-farm.git synced 2024-11-24 00:54:22 +00:00

Create menu screen

This commit is contained in:
Steffo 2024-05-02 01:10:40 +02:00
parent 0886a25969
commit cbfb6a13d6
Signed by: steffo
GPG key ID: 5ADA3868646C3FC0
8 changed files with 127 additions and 19 deletions

View file

@ -28,3 +28,5 @@ This project uses the following external assets:
| `./entities/barn_coin_enter.ogg` | https://freesound.org/people/Nawer/sounds/711784/ | Attribution 4 |
| `./entities/barn_coin_drop.ogg` | https://freesound.org/people/Nawer/sounds/711784/ | Attribution 4 |
| `./behaviours/*.svg` | https://fontawesome.com/ | CC-BY 4.0 |
| `./scenes/menu/jacquard.ttf` | https://github.com/scfried/soft-type-jacquard | OFL-1.1 |
| `./scenes/menu/jacquarda.ttf` | https://github.com/scfried/soft-type-jacquarda-bastarda | OFL-1.1 |

View file

@ -3,7 +3,7 @@ class_name Main
@onready var tree: SceneTree = get_tree()
@onready var ui_container: Control = $"InterfaceCanvas/SafeMarginContainer"
@onready var ui_container: Control = %"SafeMarginContainer"
## The possible states the game can be in.

View file

@ -6,16 +6,18 @@
[node name="Main" type="Node"]
script = ExtResource("1_jyg3q")
starting_stage = 3
[node name="PostprocessingCanvas" type="CanvasLayer" parent="."]
[node name="PostprocessingRect" parent="PostprocessingCanvas" instance=ExtResource("2_shp84")]
starting_stage = 1
[node name="InterfaceCanvas" type="CanvasLayer" parent="."]
[node name="SafeMarginContainer" parent="InterfaceCanvas" instance=ExtResource("2_ah6n8")]
unique_name_in_owner = true
min_margin_left = 16
min_margin_right = 16
min_margin_top = 16
min_margin_bottom = 16
[node name="PostprocessingCanvas" type="CanvasLayer" parent="."]
[node name="PostprocessingRect" parent="PostprocessingCanvas" instance=ExtResource("2_shp84")]
mouse_filter = 2

BIN
scenes/menu/jacquard.ttf Normal file

Binary file not shown.

View file

@ -0,0 +1,38 @@
[remap]
importer="font_data_dynamic"
type="FontFile"
uid="uid://camets1b3cocg"
path="res://.godot/imported/jacquard.ttf-4410b1c91c50740230aeee76e0850418.fontdata"
[deps]
source_file="res://scenes/menu/jacquard.ttf"
dest_files=["res://.godot/imported/jacquard.ttf-4410b1c91c50740230aeee76e0850418.fontdata"]
[params]
Rendering=null
antialiasing=0
generate_mipmaps=false
multichannel_signed_distance_field=false
msdf_pixel_range=8
msdf_size=48
allow_system_fallback=true
force_autohinter=false
hinting=0
subpixel_positioning=0
oversampling=0.0
Fallbacks=null
fallbacks=[]
Compress=null
compress=true
preload=[{
"chars": [],
"glyphs": [],
"name": "New Configuration",
"size": Vector2i(16, 0)
}]
language_support={}
script_support={}
opentype_features={}

BIN
scenes/menu/jacquarda.ttf Normal file

Binary file not shown.

View file

@ -0,0 +1,38 @@
[remap]
importer="font_data_dynamic"
type="FontFile"
uid="uid://co1i46v73s8ex"
path="res://.godot/imported/jacquarda.ttf-0dd7ef705c30e88ab05101afb233fc86.fontdata"
[deps]
source_file="res://scenes/menu/jacquarda.ttf"
dest_files=["res://.godot/imported/jacquarda.ttf-0dd7ef705c30e88ab05101afb233fc86.fontdata"]
[params]
Rendering=null
antialiasing=0
generate_mipmaps=false
multichannel_signed_distance_field=false
msdf_pixel_range=8
msdf_size=48
allow_system_fallback=true
force_autohinter=false
hinting=0
subpixel_positioning=1
oversampling=0.0
Fallbacks=null
fallbacks=[]
Compress=null
compress=true
preload=[{
"chars": [],
"glyphs": [],
"name": "New Configuration",
"size": Vector2i(16, 0)
}]
language_support={}
script_support={}
opentype_features={}

View file

@ -1,6 +1,28 @@
[gd_scene load_steps=2 format=3 uid="uid://3yqvhxeq03rk"]
[gd_scene load_steps=9 format=3 uid="uid://3yqvhxeq03rk"]
[ext_resource type="Script" path="res://scenes/menu/main_menu.gd" id="1_jkswn"]
[ext_resource type="FontFile" uid="uid://camets1b3cocg" path="res://scenes/menu/jacquard.ttf" id="1_o1msi"]
[ext_resource type="FontFile" uid="uid://co1i46v73s8ex" path="res://scenes/menu/jacquarda.ttf" id="2_7jyq2"]
[ext_resource type="PackedScene" uid="uid://bc2bm8lbol18w" path="res://entities/sheep.tscn" id="4_2rc5j"]
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_be3vx"]
bg_color = Color(1, 0.45, 0.45, 0.607843)
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_ryadt"]
bg_color = Color(0.3, 0, 0, 0.607843)
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_ibsol"]
bg_color = Color(0.0627451, 0, 0, 0.745098)
[sub_resource type="Theme" id="Theme_almu1"]
Button/font_sizes/font_size = 48
Button/fonts/font = ExtResource("1_o1msi")
Button/styles/hover = SubResource("StyleBoxFlat_be3vx")
Button/styles/normal = SubResource("StyleBoxFlat_ryadt")
Button/styles/pressed = SubResource("StyleBoxFlat_be3vx")
PanelContainer/styles/panel = SubResource("StyleBoxFlat_ibsol")
RichTextLabel/fonts/bold_font = ExtResource("1_o1msi")
RichTextLabel/fonts/normal_font = ExtResource("2_7jyq2")
[node name="MainMenu" type="Control"]
layout_mode = 3
@ -9,9 +31,22 @@ anchor_right = 1.0
anchor_bottom = 1.0
grow_horizontal = 2
grow_vertical = 2
theme = SubResource("Theme_almu1")
script = ExtResource("1_jkswn")
[node name="Panel" type="Panel" parent="."]
[node name="Sheep" parent="." instance=ExtResource("4_2rc5j")]
position = Vector2(308, 426)
[node name="Sheep2" parent="." instance=ExtResource("4_2rc5j")]
position = Vector2(216, 215)
[node name="Sheep3" parent="." instance=ExtResource("4_2rc5j")]
position = Vector2(1053, 468)
[node name="Sheep4" parent="." instance=ExtResource("4_2rc5j")]
position = Vector2(819, 152)
[node name="Panel" type="PanelContainer" parent="."]
layout_mode = 1
anchors_preset = 15
anchor_right = 1.0
@ -20,12 +55,7 @@ grow_horizontal = 2
grow_vertical = 2
[node name="Layout" type="VBoxContainer" parent="Panel"]
layout_mode = 1
anchors_preset = 15
anchor_right = 1.0
anchor_bottom = 1.0
grow_horizontal = 2
grow_vertical = 2
layout_mode = 2
alignment = 1
[node name="Title" type="MarginContainer" parent="Panel/Layout"]
@ -39,10 +69,10 @@ theme_override_constants/margin_bottom = 16
layout_mode = 2
size_flags_vertical = 6
bbcode_enabled = true
text = "[center][font_size=144px]Garasauto[/font_size]
[font_size=64px]Il casello del destino[/font_size]
text = "[center][b][font_size=144px]Hella Farm[/font_size]
[font_size=72px]Ludum Dare Fiftyfive[/font_size]
[font_size=32px]Un gioco del Garasautomobileclub Italia[/font_size][/center]"
[font_size=32px]By @meowcat, @sensei, @snowycoder, @steffo[/font_size][/b][/center]"
fit_content = true
[node name="Buttons" type="MarginContainer" parent="Panel/Layout"]
@ -59,13 +89,11 @@ alignment = 1
[node name="Play" type="Button" parent="Panel/Layout/Buttons/Layout"]
custom_minimum_size = Vector2(200, 0)
layout_mode = 2
theme_override_font_sizes/font_size = 36
text = "Play"
[node name="Options" type="Button" parent="Panel/Layout/Buttons/Layout"]
custom_minimum_size = Vector2(200, 0)
layout_mode = 2
theme_override_font_sizes/font_size = 36
text = "Options"
[connection signal="pressed" from="Panel/Layout/Buttons/Layout/Play" to="." method="_on_play_pressed"]