Compare commits

..

5 Commits

25 changed files with 410 additions and 36 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.8 KiB

View File

@@ -0,0 +1,34 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://cowabod6jrn47"
path="res://.godot/imported/Skeleton Attack.png-049662b12bed4ec69aa7828712b2b871.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://resources/animated sprite/Skeleton Sprite/Skeleton Attack.png"
dest_files=["res://.godot/imported/Skeleton Attack.png-049662b12bed4ec69aa7828712b2b871.ctex"]
[params]
compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/hdr_compression=1
compress/normal_map=0
compress/channel_pack=0
mipmaps/generate=false
mipmaps/limit=-1
roughness/mode=0
roughness/src_normal=""
process/fix_alpha_border=true
process/premult_alpha=false
process/normal_map_invert_y=false
process/hdr_as_srgb=false
process/hdr_clamp_exposure=false
process/size_limit=0
detect_3d/compress_to=1

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 KiB

View File

@@ -0,0 +1,34 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://660wqxgwh8dr"
path="res://.godot/imported/Skeleton Dead.png-d7a83435b157e05a1d13265f37b1daa6.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://resources/animated sprite/Skeleton Sprite/Skeleton Dead.png"
dest_files=["res://.godot/imported/Skeleton Dead.png-d7a83435b157e05a1d13265f37b1daa6.ctex"]
[params]
compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/hdr_compression=1
compress/normal_map=0
compress/channel_pack=0
mipmaps/generate=false
mipmaps/limit=-1
roughness/mode=0
roughness/src_normal=""
process/fix_alpha_border=true
process/premult_alpha=false
process/normal_map_invert_y=false
process/hdr_as_srgb=false
process/hdr_clamp_exposure=false
process/size_limit=0
detect_3d/compress_to=1

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

View File

@@ -0,0 +1,34 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://btfjyc4jfhiii"
path="res://.godot/imported/Skeleton Hit.png-1c1b2b67a260111c2ac7c3f48618da2e.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://resources/animated sprite/Skeleton Sprite/Skeleton Hit.png"
dest_files=["res://.godot/imported/Skeleton Hit.png-1c1b2b67a260111c2ac7c3f48618da2e.ctex"]
[params]
compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/hdr_compression=1
compress/normal_map=0
compress/channel_pack=0
mipmaps/generate=false
mipmaps/limit=-1
roughness/mode=0
roughness/src_normal=""
process/fix_alpha_border=true
process/premult_alpha=false
process/normal_map_invert_y=false
process/hdr_as_srgb=false
process/hdr_clamp_exposure=false
process/size_limit=0
detect_3d/compress_to=1

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

View File

@@ -0,0 +1,34 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://bcr4bokw87m5n"
path="res://.godot/imported/Skeleton Idle.png-3aae60d292addc7af911333cb2fced6a.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://resources/animated sprite/Skeleton Sprite/Skeleton Idle.png"
dest_files=["res://.godot/imported/Skeleton Idle.png-3aae60d292addc7af911333cb2fced6a.ctex"]
[params]
compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/hdr_compression=1
compress/normal_map=0
compress/channel_pack=0
mipmaps/generate=false
mipmaps/limit=-1
roughness/mode=0
roughness/src_normal=""
process/fix_alpha_border=true
process/premult_alpha=false
process/normal_map_invert_y=false
process/hdr_as_srgb=false
process/hdr_clamp_exposure=false
process/size_limit=0
detect_3d/compress_to=1

Binary file not shown.

After

Width:  |  Height:  |  Size: 673 B

View File

@@ -0,0 +1,34 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://cuo2o785qopo3"
path="res://.godot/imported/Skeleton React.png-e4462e4ebc0bd8edc6e0657880709951.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://resources/animated sprite/Skeleton Sprite/Skeleton React.png"
dest_files=["res://.godot/imported/Skeleton React.png-e4462e4ebc0bd8edc6e0657880709951.ctex"]
[params]
compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/hdr_compression=1
compress/normal_map=0
compress/channel_pack=0
mipmaps/generate=false
mipmaps/limit=-1
roughness/mode=0
roughness/src_normal=""
process/fix_alpha_border=true
process/premult_alpha=false
process/normal_map_invert_y=false
process/hdr_as_srgb=false
process/hdr_clamp_exposure=false
process/size_limit=0
detect_3d/compress_to=1

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

View File

@@ -0,0 +1,34 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://b0dqy1at078ct"
path="res://.godot/imported/Skeleton Walk.png-8ad85ceee01590d6218dedb5245e9634.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://resources/animated sprite/Skeleton Sprite/Skeleton Walk.png"
dest_files=["res://.godot/imported/Skeleton Walk.png-8ad85ceee01590d6218dedb5245e9634.ctex"]
[params]
compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/hdr_compression=1
compress/normal_map=0
compress/channel_pack=0
mipmaps/generate=false
mipmaps/limit=-1
roughness/mode=0
roughness/src_normal=""
process/fix_alpha_border=true
process/premult_alpha=false
process/normal_map_invert_y=false
process/hdr_as_srgb=false
process/hdr_clamp_exposure=false
process/size_limit=0
detect_3d/compress_to=1

Binary file not shown.

After

Width:  |  Height:  |  Size: 486 B

View File

@@ -0,0 +1,34 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://c8y6tlvcgh2gn"
path="res://.godot/imported/beanstalk-dark.webp-c42752b76137a07f19260f250e70ea14.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://resources/textures/beanstalk-dark.webp"
dest_files=["res://.godot/imported/beanstalk-dark.webp-c42752b76137a07f19260f250e70ea14.ctex"]
[params]
compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/hdr_compression=1
compress/normal_map=0
compress/channel_pack=0
mipmaps/generate=false
mipmaps/limit=-1
roughness/mode=0
roughness/src_normal=""
process/fix_alpha_border=true
process/premult_alpha=false
process/normal_map_invert_y=false
process/hdr_as_srgb=false
process/hdr_clamp_exposure=false
process/size_limit=0
detect_3d/compress_to=1

12
scenes/game.gd Normal file
View File

@@ -0,0 +1,12 @@
extends Node
@onready var back_button: Button = $BackButtonContainer/BackButton
func _ready() -> void:
if not back_button.pressed.is_connected(_on_back_button_pressed):
back_button.pressed.connect(_on_back_button_pressed)
func _on_back_button_pressed() -> void:
AudioManager.play_ui_click()
GameManager.save_game()
GameManager.exit_to_main_menu()

1
scenes/game.gd.uid Normal file
View File

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

17
scenes/game.tscn Normal file
View File

@@ -0,0 +1,17 @@
[gd_scene load_steps=2 format=3 uid="uid://dmwkyeq2l7u04"]
[ext_resource type="Script" uid="uid://bvtr6yhlyuv4v" path="res://scenes/game.gd" id="1_uwrxv"]
[node name="Game" type="Node"]
script = ExtResource("1_uwrxv")
[node name="BackButtonContainer" type="Control" parent="."]
layout_mode = 3
anchors_preset = 0
offset_right = 40.0
offset_bottom = 40.0
[node name="BackButton" type="Button" parent="BackButtonContainer"]
offset_right = 45.0
offset_bottom = 31.0
text = "back"

View File

@@ -1,7 +1,8 @@
[gd_scene load_steps=3 format=3 uid="uid://ci2gk11211n0d"]
[gd_scene load_steps=4 format=3 uid="uid://ci2gk11211n0d"]
[ext_resource type="Script" uid="uid://cwlop1ettlqhg" path="res://scripts/Main.gd" id="1_0wfyh"]
[ext_resource type="PackedScene" uid="uid://gbe1jarrwqsi" path="res://ui/PressAnyKeyScreen.tscn" id="1_o5qli"]
[ext_resource type="Texture2D" uid="uid://c8y6tlvcgh2gn" path="res://resources/textures/beanstalk-dark.webp" id="2_sugp2"]
[node name="main" type="Control"]
layout_mode = 3
@@ -12,5 +13,15 @@ grow_horizontal = 2
grow_vertical = 2
script = ExtResource("1_0wfyh")
[node name="Background" type="TextureRect" parent="."]
layout_mode = 1
anchors_preset = 15
anchor_right = 1.0
anchor_bottom = 1.0
grow_horizontal = 2
grow_vertical = 2
texture = ExtResource("2_sugp2")
stretch_mode = 1
[node name="PressAnyKeyScreen" parent="." instance=ExtResource("1_o5qli")]
layout_mode = 1

View File

@@ -5,6 +5,7 @@ const UI_CLICK_SOUND_PATH := "res://audio/817587__silverdubloons__tick06.wav"
var music_player: AudioStreamPlayer
var ui_click_player: AudioStreamPlayer
var click_stream: AudioStream
func _ready():
music_player = AudioStreamPlayer.new()
@@ -14,13 +15,14 @@ func _ready():
ui_click_player.bus = "SFX"
add_child(ui_click_player)
click_stream = load(UI_CLICK_SOUND_PATH)
var orig_stream = _load_stream()
if not orig_stream:
push_error("Failed to load music stream: %s" % MUSIC_PATH)
return
var stream = orig_stream.duplicate(true) as AudioStream
_configure_stream_loop(stream)
music_player.stream = stream
_configure_audio_bus()
@@ -67,7 +69,7 @@ func _stop_music() -> void:
music_player.stop()
func play_ui_click() -> void:
var click_stream = load(UI_CLICK_SOUND_PATH)
if click_stream and click_stream is AudioStream:
ui_click_player.stream = click_stream
ui_click_player.play()
if not click_stream:
return
ui_click_player.stream = click_stream
ui_click_player.play()

View File

@@ -1,4 +1,21 @@
extends Node
func _ready():
pass
const GAME_SCENE_PATH := "res://scenes/Game.tscn"
const MAIN_SCENE_PATH := "res://scenes/Main.tscn"
func start_new_game() -> void:
var packed_scene := load(GAME_SCENE_PATH)
if not packed_scene or not packed_scene is PackedScene:
push_error("Failed to load Game scene at: %s" % GAME_SCENE_PATH)
return
get_tree().change_scene_to_packed(packed_scene)
func save_game() -> void:
print("Game saved (mock)")
func exit_to_main_menu() -> void:
var packed_scene := load(MAIN_SCENE_PATH)
if not packed_scene or not packed_scene is PackedScene:
push_error("Failed to load Main scene at: %s" % MAIN_SCENE_PATH)
return
get_tree().change_scene_to_packed(packed_scene)

View File

@@ -8,6 +8,7 @@ func _ready():
func _on_new_game_button_pressed():
AudioManager.play_ui_click()
print("New Game pressed")
GameManager.start_new_game()
func _on_settings_button_pressed():
AudioManager.play_ui_click()

View File

@@ -3,3 +3,7 @@
commonUrl: https://clement-panchout.itch.io/yet-another-free-music-pack
- fileName: audio/817587__silverdubloons__tick06.wav
commonUrl: https://freesound.org/people/SilverDubloons/sounds/817587/
- fileName: resources/textures/beanstalk-dark.webp
commonUrl: https://www.toptal.com/designers/subtlepatterns/beanstalk-dark-pattern/
- fileName: resources/animated sprite/Skeleton Sprite
commonUrl: https://jesse-m.itch.io/skeleton-pack

View File

@@ -11,15 +11,6 @@ grow_horizontal = 2
grow_vertical = 2
script = ExtResource("1_b00nv")
[node name="Background" type="ColorRect" parent="."]
layout_mode = 1
anchors_preset = 15
anchor_right = 1.0
anchor_bottom = 1.0
grow_horizontal = 2
grow_vertical = 2
color = Color(0.952411, 0.651681, 0.63048, 1)
[node name="MenuContainer" type="VBoxContainer" parent="."]
layout_mode = 1
anchors_preset = 8

View File

@@ -1,6 +1,92 @@
[gd_scene load_steps=2 format=3 uid="uid://gbe1jarrwqsi"]
[gd_scene load_steps=15 format=3 uid="uid://gbe1jarrwqsi"]
[ext_resource type="Script" uid="uid://buak21ajgvevl" path="res://scripts/PressAnyKeyScreen.gd" id="1_0a4p2"]
[ext_resource type="Texture2D" uid="uid://bcr4bokw87m5n" path="res://resources/animated sprite/Skeleton Sprite/Skeleton Idle.png" id="2_rjjcb"]
[sub_resource type="AtlasTexture" id="AtlasTexture_l6pue"]
atlas = ExtResource("2_rjjcb")
region = Rect2(0, 0, 24, 32)
[sub_resource type="AtlasTexture" id="AtlasTexture_3h5mc"]
atlas = ExtResource("2_rjjcb")
region = Rect2(24, 0, 24, 32)
[sub_resource type="AtlasTexture" id="AtlasTexture_gqpp5"]
atlas = ExtResource("2_rjjcb")
region = Rect2(48, 0, 24, 32)
[sub_resource type="AtlasTexture" id="AtlasTexture_ff5uo"]
atlas = ExtResource("2_rjjcb")
region = Rect2(72, 0, 24, 32)
[sub_resource type="AtlasTexture" id="AtlasTexture_e7oxa"]
atlas = ExtResource("2_rjjcb")
region = Rect2(96, 0, 24, 32)
[sub_resource type="AtlasTexture" id="AtlasTexture_urgkb"]
atlas = ExtResource("2_rjjcb")
region = Rect2(120, 0, 24, 32)
[sub_resource type="AtlasTexture" id="AtlasTexture_xfg50"]
atlas = ExtResource("2_rjjcb")
region = Rect2(144, 0, 24, 32)
[sub_resource type="AtlasTexture" id="AtlasTexture_sy0v8"]
atlas = ExtResource("2_rjjcb")
region = Rect2(168, 0, 24, 32)
[sub_resource type="AtlasTexture" id="AtlasTexture_kfv8w"]
atlas = ExtResource("2_rjjcb")
region = Rect2(192, 0, 24, 32)
[sub_resource type="AtlasTexture" id="AtlasTexture_lvvje"]
atlas = ExtResource("2_rjjcb")
region = Rect2(216, 0, 24, 32)
[sub_resource type="AtlasTexture" id="AtlasTexture_vvh7w"]
atlas = ExtResource("2_rjjcb")
region = Rect2(240, 0, 24, 32)
[sub_resource type="SpriteFrames" id="SpriteFrames_wtrhp"]
animations = [{
"frames": [{
"duration": 1.0,
"texture": SubResource("AtlasTexture_l6pue")
}, {
"duration": 1.0,
"texture": SubResource("AtlasTexture_3h5mc")
}, {
"duration": 1.0,
"texture": SubResource("AtlasTexture_gqpp5")
}, {
"duration": 1.0,
"texture": SubResource("AtlasTexture_ff5uo")
}, {
"duration": 1.0,
"texture": SubResource("AtlasTexture_e7oxa")
}, {
"duration": 1.0,
"texture": SubResource("AtlasTexture_urgkb")
}, {
"duration": 1.0,
"texture": SubResource("AtlasTexture_xfg50")
}, {
"duration": 1.0,
"texture": SubResource("AtlasTexture_sy0v8")
}, {
"duration": 1.0,
"texture": SubResource("AtlasTexture_kfv8w")
}, {
"duration": 1.0,
"texture": SubResource("AtlasTexture_lvvje")
}, {
"duration": 1.0,
"texture": SubResource("AtlasTexture_vvh7w")
}],
"loop": true,
"name": &"default",
"speed": 5.0
}]
[node name="PressAnyKeyScreen" type="Control" groups=["localizable"]]
layout_mode = 3
@@ -11,15 +97,6 @@ grow_horizontal = 2
grow_vertical = 2
script = ExtResource("1_0a4p2")
[node name="Background" type="ColorRect" parent="."]
layout_mode = 1
anchors_preset = 15
anchor_right = 1.0
anchor_bottom = 1.0
grow_horizontal = 2
grow_vertical = 2
color = Color(0.18, 0.18, 0.18, 1)
[node name="PressKeyContainer" type="VBoxContainer" parent="."]
layout_mode = 1
anchors_preset = 8
@@ -35,6 +112,18 @@ grow_horizontal = 2
grow_vertical = 2
metadata/_edit_use_anchors_ = true
[node name="AspectRatioContainer" type="AspectRatioContainer" parent="PressKeyContainer"]
layout_mode = 2
size_flags_horizontal = 4
size_flags_vertical = 0
alignment_horizontal = 0
alignment_vertical = 0
[node name="AnimatedSprite2D" type="AnimatedSprite2D" parent="PressKeyContainer/AspectRatioContainer"]
sprite_frames = SubResource("SpriteFrames_wtrhp")
autoplay = "default"
offset = Vector2(0, -30)
[node name="TitleLabel" type="Label" parent="PressKeyContainer"]
layout_mode = 2
text = "Skelly"

View File

@@ -11,15 +11,6 @@ grow_horizontal = 2
grow_vertical = 2
script = ExtResource("1_oqkcn")
[node name="Background" type="ColorRect" parent="."]
layout_mode = 1
anchors_preset = 15
anchor_right = 1.0
anchor_bottom = 1.0
grow_horizontal = 2
grow_vertical = 2
color = Color(0.209, 0.5159, 0.55, 1)
[node name="SettingsContainer" type="VBoxContainer" parent="."]
layout_mode = 1
anchors_preset = 8