From 6286304ebfd359287a9d87d1d129861904fd4391 Mon Sep 17 00:00:00 2001 From: winniewk Date: Mon, 2 Sep 2024 23:01:45 -0400 Subject: [PATCH] Reset the coin count after player is defeated --- ...state-6d8e6ff1e6f20a36e0402d27c623c86c.cfg | 2 +- ...state-b6bd7a241034177d7fe082a7597ba8ea.cfg | 2 +- ...state-96b2131180b71dd158e52c5527d22dd4.cfg | 2 +- ...state-65637dc57c83dac3d15ec1cb22439bd7.cfg | 2 +- .godot/editor/editor_layout.cfg | 12 +-- .godot/editor/filesystem_cache8 | 88 ++++++++++-------- .godot/editor/filesystem_update4 | 13 +-- ...state-c2a7af834e91ff64325daddf58e45dc0.cfg | 2 +- ...state-38bf74ff262409a94a41206b2b776d33.cfg | 2 +- ...state-cc2f727180cd42d9c13434cb55b1ce69.cfg | 2 +- .godot/editor/project_metadata.cfg | 8 +- .godot/editor/recent_dirs | 1 + .godot/editor/script_editor_cache.cfg | 56 ++++++++--- ...state-7f960b0e063e7daa9b04ba3fda3f82d8.cfg | 2 +- ...state-9211dc52ac9df169ba4fe77cbc1dc833.cfg | 2 +- .godot/uid_cache.bin | Bin 1099 -> 1099 bytes project.godot | 2 + scripts/characterBody.gd | 1 - scripts/coin.gd | 1 - scripts/gameManager.gd | 6 +- scripts/gamecontroller.gd | 3 +- todo.txt | 10 ++ 22 files changed, 132 insertions(+), 87 deletions(-) create mode 100644 todo.txt diff --git a/.godot/editor/bullet.tscn-editstate-6d8e6ff1e6f20a36e0402d27c623c86c.cfg b/.godot/editor/bullet.tscn-editstate-6d8e6ff1e6f20a36e0402d27c623c86c.cfg index 4abcfd8..9c1d3ac 100644 --- a/.godot/editor/bullet.tscn-editstate-6d8e6ff1e6f20a36e0402d27c623c86c.cfg +++ b/.godot/editor/bullet.tscn-editstate-6d8e6ff1e6f20a36e0402d27c623c86c.cfg @@ -172,4 +172,4 @@ Anim={ "zfar": 4000.01, "znear": 0.05 } -selected_nodes=Array[NodePath]([NodePath("/root/@EditorNode@17140/@Panel@13/@VBoxContainer@14/@HSplitContainer@17/@HSplitContainer@25/@HSplitContainer@33/@VBoxContainer@34/@VSplitContainer@36/@VSplitContainer@62/@VBoxContainer@63/@PanelContainer@110/MainScreen/@CanvasItemEditor@9462/@VSplitContainer@9281/@HSplitContainer@9283/@HSplitContainer@9285/@Control@9286/@SubViewportContainer@9287/@SubViewport@9288/Game/CharacterBody2D")]) +selected_nodes=Array[NodePath]([NodePath("/root/@EditorNode@17150/@Panel@13/@VBoxContainer@14/@HSplitContainer@17/@HSplitContainer@25/@HSplitContainer@33/@VBoxContainer@34/@VSplitContainer@36/@VSplitContainer@62/@VBoxContainer@63/@PanelContainer@110/MainScreen/@CanvasItemEditor@9465/@VSplitContainer@9284/@HSplitContainer@9286/@HSplitContainer@9288/@Control@9289/@SubViewportContainer@9290/@SubViewport@9291/RigidBody2D")]) diff --git a/.godot/editor/character.tscn-editstate-b6bd7a241034177d7fe082a7597ba8ea.cfg b/.godot/editor/character.tscn-editstate-b6bd7a241034177d7fe082a7597ba8ea.cfg index e77cb32..7a77309 100644 --- a/.godot/editor/character.tscn-editstate-b6bd7a241034177d7fe082a7597ba8ea.cfg +++ b/.godot/editor/character.tscn-editstate-b6bd7a241034177d7fe082a7597ba8ea.cfg @@ -172,4 +172,4 @@ Anim={ "zfar": 4000.01, "znear": 0.05 } -selected_nodes=Array[NodePath]([NodePath("/root/@EditorNode@17140/@Panel@13/@VBoxContainer@14/@HSplitContainer@17/@HSplitContainer@25/@HSplitContainer@33/@VBoxContainer@34/@VSplitContainer@36/@VSplitContainer@62/@VBoxContainer@63/@PanelContainer@110/MainScreen/@CanvasItemEditor@9462/@VSplitContainer@9281/@HSplitContainer@9283/@HSplitContainer@9285/@Control@9286/@SubViewportContainer@9287/@SubViewport@9288/Game/CharacterBody2D")]) +selected_nodes=Array[NodePath]([NodePath("/root/@EditorNode@17150/@Panel@13/@VBoxContainer@14/@HSplitContainer@17/@HSplitContainer@25/@HSplitContainer@33/@VBoxContainer@34/@VSplitContainer@36/@VSplitContainer@62/@VBoxContainer@63/@PanelContainer@110/MainScreen/@CanvasItemEditor@9465/@VSplitContainer@9284/@HSplitContainer@9286/@HSplitContainer@9288/@Control@9289/@SubViewportContainer@9290/@SubViewport@9291/RigidBody2D")]) diff --git a/.godot/editor/coin.tscn-editstate-96b2131180b71dd158e52c5527d22dd4.cfg b/.godot/editor/coin.tscn-editstate-96b2131180b71dd158e52c5527d22dd4.cfg index e7bfe99..099dcbd 100644 --- a/.godot/editor/coin.tscn-editstate-96b2131180b71dd158e52c5527d22dd4.cfg +++ b/.godot/editor/coin.tscn-editstate-96b2131180b71dd158e52c5527d22dd4.cfg @@ -172,4 +172,4 @@ Anim={ "zfar": 4000.01, "znear": 0.05 } -selected_nodes=Array[NodePath]([NodePath("/root/@EditorNode@17140/@Panel@13/@VBoxContainer@14/@HSplitContainer@17/@HSplitContainer@25/@HSplitContainer@33/@VBoxContainer@34/@VSplitContainer@36/@VSplitContainer@62/@VBoxContainer@63/@PanelContainer@110/MainScreen/@CanvasItemEditor@9462/@VSplitContainer@9281/@HSplitContainer@9283/@HSplitContainer@9285/@Control@9286/@SubViewportContainer@9287/@SubViewport@9288/Game/CharacterBody2D")]) +selected_nodes=Array[NodePath]([NodePath("/root/@EditorNode@17150/@Panel@13/@VBoxContainer@14/@HSplitContainer@17/@HSplitContainer@25/@HSplitContainer@33/@VBoxContainer@34/@VSplitContainer@36/@VSplitContainer@62/@VBoxContainer@63/@PanelContainer@110/MainScreen/@CanvasItemEditor@9465/@VSplitContainer@9284/@HSplitContainer@9286/@HSplitContainer@9288/@Control@9289/@SubViewportContainer@9290/@SubViewport@9291/RigidBody2D")]) diff --git a/.godot/editor/crate.tscn-editstate-65637dc57c83dac3d15ec1cb22439bd7.cfg b/.godot/editor/crate.tscn-editstate-65637dc57c83dac3d15ec1cb22439bd7.cfg index 31912db..01b6fa2 100644 --- a/.godot/editor/crate.tscn-editstate-65637dc57c83dac3d15ec1cb22439bd7.cfg +++ b/.godot/editor/crate.tscn-editstate-65637dc57c83dac3d15ec1cb22439bd7.cfg @@ -172,4 +172,4 @@ Anim={ "zfar": 4000.01, "znear": 0.05 } -selected_nodes=Array[NodePath]([NodePath("/root/@EditorNode@17140/@Panel@13/@VBoxContainer@14/@HSplitContainer@17/@HSplitContainer@25/@HSplitContainer@33/@VBoxContainer@34/@VSplitContainer@36/@VSplitContainer@62/@VBoxContainer@63/@PanelContainer@110/MainScreen/@CanvasItemEditor@9462/@VSplitContainer@9281/@HSplitContainer@9283/@HSplitContainer@9285/@Control@9286/@SubViewportContainer@9287/@SubViewport@9288/Game/CharacterBody2D")]) +selected_nodes=Array[NodePath]([NodePath("/root/@EditorNode@17150/@Panel@13/@VBoxContainer@14/@HSplitContainer@17/@HSplitContainer@25/@HSplitContainer@33/@VBoxContainer@34/@VSplitContainer@36/@VSplitContainer@62/@VBoxContainer@63/@PanelContainer@110/MainScreen/@CanvasItemEditor@9465/@VSplitContainer@9284/@HSplitContainer@9286/@HSplitContainer@9288/@Control@9289/@SubViewportContainer@9290/@SubViewport@9291/RigidBody2D")]) diff --git a/.godot/editor/editor_layout.cfg b/.godot/editor/editor_layout.cfg index 0c58482..1b8027c 100644 --- a/.godot/editor/editor_layout.cfg +++ b/.godot/editor/editor_layout.cfg @@ -19,24 +19,24 @@ dock_filesystem_split=0 dock_filesystem_display_mode=0 dock_filesystem_file_sort=0 dock_filesystem_file_list_display_mode=1 -dock_filesystem_selected_paths=PackedStringArray("res://scenes/game.tscn") -dock_filesystem_uncollapsed_paths=PackedStringArray("Favorites", "res://", "res://scripts/", "res://scripts/resources/", "res://scenes/") +dock_filesystem_selected_paths=PackedStringArray("res://scripts/characterBody.gd") +dock_filesystem_uncollapsed_paths=PackedStringArray("Favorites", "res://", "res://scripts/") dock_3="Scene,Import" dock_4="FileSystem" dock_5="Inspector,Node,History" [EditorNode] -open_scenes=PackedStringArray("res://scenes/character.tscn", "res://scenes/bullet.tscn", "res://scenes/crate.tscn", "res://scenes/platform.tscn", "res://scenes/coin.tscn", "res://scenes/hud.tscn", "res://scenes/slimeEnemy.tscn", "res://scenes/game.tscn", "res://scenes/ui.tscn") -current_scene="res://scenes/game.tscn" +open_scenes=PackedStringArray("res://scenes/character.tscn", "res://scenes/bullet.tscn", "res://scenes/crate.tscn", "res://scenes/platform.tscn", "res://scenes/coin.tscn", "res://scenes/hud.tscn", "res://scenes/ui.tscn", "res://scenes/game.tscn") +current_scene="res://scenes/crate.tscn" center_split_offset=-272 selected_default_debugger_tab_idx=0 selected_main_editor_idx=2 -selected_bottom_panel_item=1 +selected_bottom_panel_item=0 [ScriptEditor] -open_scripts=["res://scripts/bullet.gd", "res://scripts/characterBody.gd", "res://scripts/resources/characterStats.gd", "res://scripts/coin.gd", "res://scripts/enemy.gd", "res://scripts/gamecontroller.gd", "res://scripts/gameManager.gd", "res://scripts/ui.gd"] +open_scripts=["res://scripts/bullet.gd", "res://scripts/characterBody.gd", "res://scripts/resources/characterStats.gd", "res://scripts/coin.gd", "res://scripts/enemy.gd", "res://scripts/gamecontroller.gd", "res://scripts/gameManager.gd", "res://todo.txt", "res://scripts/trigger.gd", "res://scripts/ui.gd"] selected_script="res://scripts/gamecontroller.gd" open_help=[] script_split_offset=162 diff --git a/.godot/editor/filesystem_cache8 b/.godot/editor/filesystem_cache8 index 1d5fdcc..f376a2d 100644 --- a/.godot/editor/filesystem_cache8 +++ b/.godot/editor/filesystem_cache8 @@ -1,42 +1,48 @@ ea4bc82a6ad023ab7ee23ee620429895 -::res://::1724106264 -icon.svg::CompressedTexture2D::9114977118871582245::1724105533::1724105533::1::::<><>:: -::res://graphics/::1724105533 -Terrain (32x32).png::CompressedTexture2D::8707534964839485024::1724105533::1724105533::1::::<><>:: -::res://graphics/background/::1724105533 -Additional Sky.png::CompressedTexture2D::1244579229272977068::1724105533::1724105533::1::::<><>:: -Additional Water.png::CompressedTexture2D::5600863291548044975::1724105533::1724105533::1::::<><>:: -BG Image.png::CompressedTexture2D::8171004012114145580::1724105533::1724105533::1::::<><>:: -::res://graphics/enemies/::1724105533 -slime_purple.png::CompressedTexture2D::8000128190937998756::1724105533::1724105533::1::::<><>:: -::res://graphics/items/::1724105533 -cannister.png::CompressedTexture2D::7418095402531000042::1724105533::1724105533::1::::<><>:: -::res://graphics/pickups/::1724105533 -coin.png::CompressedTexture2D::4421146948747862835::1724105533::1724105533::1::::<><>:: -::res://graphics/playerDeath/::1724105533 -Player Death 64x64.png::CompressedTexture2D::2301479042922018053::1724105533::1724105533::1::::<><>:: -::res://graphics/playerIdle/::1724105533 -Player Idle 48x48.png::CompressedTexture2D::6544563428604246579::1724105533::1724105533::1::::<><>:: -::res://graphics/playerJump/::1724105533 -player jump 48x48.png::CompressedTexture2D::1627608568707791839::1724105533::1724105533::1::::<><>:: -::res://graphics/playerLand/::1724105533 -player land 48x48.png::CompressedTexture2D::3499637713582873633::1724105533::1724105533::1::::<><>:: -::res://graphics/playerRun/::1724105533 -player run 48x48.png::CompressedTexture2D::1502492849971408816::1724105533::1724105533::1::::<><>:: -::res://scenes/::1724108423 -bullet.tscn::PackedScene::6880909734590904373::1724108422::0::1::::<><>::res://scripts/bullet.gd<>uid://ddxm7hj323fta::::res://graphics/items/cannister.png -character.tscn::PackedScene::451838158579532324::1724108469::0::1::::<><>::res://scripts/characterBody.gd<>uid://714a2jbwrdbp::::res://graphics/playerDeath/Player Death 64x64.png<>uid://c0iiaebonyhh0::::res://graphics/playerIdle/Player Idle 48x48.png<>uid://xgoqfqmvorcx::::res://graphics/playerJump/player jump 48x48.png<>uid://vn23qn3f0dvc::::res://graphics/playerRun/player run 48x48.png -coin.tscn::PackedScene::2149639666289516704::1724108608::0::1::::<><>::uid://b38vv525jl8cd::::res://graphics/pickups/coin.png<>res://scripts/coin.gd -crate.tscn::PackedScene::41931541512830250::1724108422::0::1::::<><>::uid://ddxm7hj323fta::::res://graphics/items/cannister.png -game.tscn::PackedScene::1738196330916037717::1724108423::0::1::::<><>::res://scripts/gamecontroller.gd<>uid://go4yc8hfo1gq::::res://scenes/character.tscn<>uid://dwb83f7uoweuy::::res://graphics/Terrain (32x32).png<>res://scripts/Trigger.gd<>uid://doodiicuxeb53::::res://graphics/background/BG Image.png<>uid://ry5bkalocmx5::::res://graphics/background/Additional Sky.png<>uid://cl2dnusewe0ch::::res://graphics/background/Additional Water.png<>uid://ukuu7p7vhlq::::res://scenes/crate.tscn<>uid://5vkisovypn7u::::res://scenes/coin.tscn<>uid://b07px1qf5obql::::res://scenes/slimeEnemy.tscn -hud.tscn::PackedScene::2846083967266652522::1724108423::0::1::::<><>:: -platform.tscn::PackedScene::6925631844010706180::1724108422::0::1::::<><>:: -slimeEnemy.tscn::PackedScene::4208155081516926623::1724108423::0::1::::<><>::uid://dl8k7bq5pkuvk::::res://graphics/enemies/slime_purple.png<>res://scripts/enemy.gd -::res://scripts/::1724108406 -bullet.gd::GDScript::-1::1724105533::0::1::::<>Area2D<>:: -characterBody.gd::GDScript::-1::1724108469::0::1::::<>CharacterBody2D<>:: -coin.gd::GDScript::-1::1724107615::0::1::::Coin<>Area2D<>:: -enemy.gd::GDScript::-1::1724105533::0::1::::<>Area2D<>:: -gamecontroller.gd::GDScript::-1::1724108608::0::1::::<>Node<>:: -gameManager.gd::GDScript::-1::1724108406::0::1::::<>Node<>:: -Trigger.gd::GDScript::-1::1724106138::0::1::::<>Area2D<>:: +::res://::1725298946 +icon.svg::CompressedTexture2D::9114977118871582245::1723383776::1723383776::1::::<><>:: +::res://graphics/::1723682052 +Terrain (32x32).png::CompressedTexture2D::8707534964839485024::1723383776::1723383776::1::::<><>:: +::res://graphics/background/::1723679592 +Additional Sky.png::CompressedTexture2D::1244579229272977068::1723679592::1723679592::1::::<><>:: +Additional Water.png::CompressedTexture2D::5600863291548044975::1723679592::1723679592::1::::<><>:: +BG Image.png::CompressedTexture2D::8171004012114145580::1723679592::1723679592::1::::<><>:: +::res://graphics/enemies/::1723679592 +slime_purple.png::CompressedTexture2D::8000128190937998756::1723679592::1723679592::1::::<><>:: +::res://graphics/items/::1723383776 +cannister.png::CompressedTexture2D::7418095402531000042::1723383776::1723383776::1::::<><>:: +::res://graphics/pickups/::1723679592 +coin.png::CompressedTexture2D::4421146948747862835::1723679592::1723679592::1::::<><>:: +::res://graphics/playerDeath/::1723679592 +Player Death 64x64.png::CompressedTexture2D::2301479042922018053::1723679592::1723679592::1::::<><>:: +::res://graphics/playerIdle/::1723682026 +Player Idle 48x48.png::CompressedTexture2D::6544563428604246579::1723383776::1723682026::1::::<><>:: +::res://graphics/playerJump/::1723682031 +player jump 48x48.png::CompressedTexture2D::1627608568707791839::1723383776::1723682031::1::::<><>:: +::res://graphics/playerLand/::1723682046 +player land 48x48.png::CompressedTexture2D::3499637713582873633::1723383776::1723682046::1::::<><>:: +::res://graphics/playerRun/::1723682052 +player run 48x48.png::CompressedTexture2D::1502492849971408816::1723383776::1723682052::1::::<><>:: +::res://scenes/::1725298927 +bullet.tscn::PackedScene::6880909734590904373::1723685890::0::1::::<><>::res://scripts/bullet.gd<>uid://ddxm7hj323fta::::res://graphics/items/cannister.png +character.tscn::PackedScene::451838158579532324::1725298927::0::1::::<><>::res://scripts/characterBody.gd<>uid://714a2jbwrdbp::::res://graphics/playerDeath/Player Death 64x64.png<>uid://c0iiaebonyhh0::::res://graphics/playerIdle/Player Idle 48x48.png<>uid://xgoqfqmvorcx::::res://graphics/playerJump/player jump 48x48.png<>uid://vn23qn3f0dvc::::res://graphics/playerRun/player run 48x48.png +coin.tscn::PackedScene::2149639666289516704::1723685890::0::1::::<><>::uid://b38vv525jl8cd::::res://graphics/pickups/coin.png<>res://scripts/coin.gd +crate.tscn::PackedScene::41931541512830250::1723685890::0::1::::<><>::uid://ddxm7hj323fta::::res://graphics/items/cannister.png +game.tscn::PackedScene::1738196330916037717::1725298927::0::1::::<><>::res://scripts/gamecontroller.gd<>uid://go4yc8hfo1gq::::res://scenes/character.tscn<>uid://dwb83f7uoweuy::::res://graphics/Terrain (32x32).png<>res://scripts/Trigger.gd<>uid://doodiicuxeb53::::res://graphics/background/BG Image.png<>uid://ry5bkalocmx5::::res://graphics/background/Additional Sky.png<>uid://cl2dnusewe0ch::::res://graphics/background/Additional Water.png<>uid://ukuu7p7vhlq::::res://scenes/crate.tscn<>uid://5vkisovypn7u::::res://scenes/coin.tscn<>uid://b07px1qf5obql::::res://scenes/slimeEnemy.tscn<>uid://drnga68jb8frq::::res://scenes/ui.tscn +hud.tscn::PackedScene::2846083967266652522::1723685890::0::1::::<><>:: +platform.tscn::PackedScene::6925631844010706180::1723685890::0::1::::<><>:: +slimeEnemy.tscn::PackedScene::4208155081516926623::1723685890::0::1::::<><>::uid://dl8k7bq5pkuvk::::res://graphics/enemies/slime_purple.png<>res://scripts/enemy.gd +ui.tscn::PackedScene::8379675285299188318::1725298927::0::1::::<><>::res://scripts/ui.gd +::res://scripts/::1725298927 +bullet.gd::GDScript::-1::1723685532::0::1::::<>Area2D<>:: +characterBody.gd::GDScript::-1::1725298927::0::1::::<>CharacterBody2D<>:: +coin.gd::GDScript::-1::1725298927::0::1::::Coin<>Area2D<>:: +enemy.gd::GDScript::-1::1725298927::0::1::::Enemy<>Area2D<>:: +gamecontroller.gd::GDScript::-1::1725298927::0::1::::<>Node<>:: +gameManager.gd::GDScript::-1::1725298927::0::1::::<>Node<>:: +trigger.gd::GDScript::-1::1723684750::0::1::::<>Area2D<>:: +ui.gd::GDScript::-1::1725298927::0::1::::<>Control<>:: +::res://scripts/resources/::1725298927 +characterStats.gd::GDScript::-1::1725298927::0::1::::Character<>Resource<>:: +playerStats.tres::Resource/Character::8779682877369753764::1725298927::0::1::::<><>::res://scripts/resources/characterStats.gd +slimeStats.tres::Resource/Character::1410397446622825581::1725298927::0::1::::<><>::res://scripts/resources/characterStats.gd diff --git a/.godot/editor/filesystem_update4 b/.godot/editor/filesystem_update4 index aa47c9c..c845e57 100644 --- a/.godot/editor/filesystem_update4 +++ b/.godot/editor/filesystem_update4 @@ -1,18 +1,15 @@ -res://scenes/game.tscn res://scenes/character.tscn -res://scripts/Trigger.gd +res://scripts/trigger.gd res://scenes/bullet.tscn res://scenes/crate.tscn res://scenes/platform.tscn res://scenes/coin.tscn res://scenes/hud.tscn res://scenes/slimeEnemy.tscn -res://scripts/gameManager.gd +res://scenes/game.tscn +res://scenes/ui.tscn +res://todo.txt res://scripts/coin.gd +res://scripts/gameManager.gd res://scripts/gamecontroller.gd res://scripts/characterBody.gd -res://scripts/resources/characterStats.gd -res://scripts/resources/slimeStats.tres -res://scripts/enemy.gd -res://scenes/ui.tscn -res://scripts/ui.gd diff --git a/.godot/editor/game.tscn-editstate-c2a7af834e91ff64325daddf58e45dc0.cfg b/.godot/editor/game.tscn-editstate-c2a7af834e91ff64325daddf58e45dc0.cfg index 77f4144..a1ab6b2 100644 --- a/.godot/editor/game.tscn-editstate-c2a7af834e91ff64325daddf58e45dc0.cfg +++ b/.godot/editor/game.tscn-editstate-c2a7af834e91ff64325daddf58e45dc0.cfg @@ -172,4 +172,4 @@ Anim={ "zfar": 4000.01, "znear": 0.05 } -selected_nodes=Array[NodePath]([NodePath("/root/@EditorNode@17140/@Panel@13/@VBoxContainer@14/@HSplitContainer@17/@HSplitContainer@25/@HSplitContainer@33/@VBoxContainer@34/@VSplitContainer@36/@VSplitContainer@62/@VBoxContainer@63/@PanelContainer@110/MainScreen/@CanvasItemEditor@9462/@VSplitContainer@9281/@HSplitContainer@9283/@HSplitContainer@9285/@Control@9286/@SubViewportContainer@9287/@SubViewport@9288/Game/CharacterBody2D")]) +selected_nodes=Array[NodePath]([NodePath("/root/@EditorNode@17150/@Panel@13/@VBoxContainer@14/@HSplitContainer@17/@HSplitContainer@25/@HSplitContainer@33/@VBoxContainer@34/@VSplitContainer@36/@VSplitContainer@62/@VBoxContainer@63/@PanelContainer@110/MainScreen/@CanvasItemEditor@9465/@VSplitContainer@9284/@HSplitContainer@9286/@HSplitContainer@9288/@Control@9289/@SubViewportContainer@9290/@SubViewport@9291/RigidBody2D")]) diff --git a/.godot/editor/hud.tscn-editstate-38bf74ff262409a94a41206b2b776d33.cfg b/.godot/editor/hud.tscn-editstate-38bf74ff262409a94a41206b2b776d33.cfg index 11a5a70..1da9598 100644 --- a/.godot/editor/hud.tscn-editstate-38bf74ff262409a94a41206b2b776d33.cfg +++ b/.godot/editor/hud.tscn-editstate-38bf74ff262409a94a41206b2b776d33.cfg @@ -172,4 +172,4 @@ Anim={ "zfar": 4000.01, "znear": 0.05 } -selected_nodes=Array[NodePath]([NodePath("/root/@EditorNode@17140/@Panel@13/@VBoxContainer@14/@HSplitContainer@17/@HSplitContainer@25/@HSplitContainer@33/@VBoxContainer@34/@VSplitContainer@36/@VSplitContainer@62/@VBoxContainer@63/@PanelContainer@110/MainScreen/@CanvasItemEditor@9462/@VSplitContainer@9281/@HSplitContainer@9283/@HSplitContainer@9285/@Control@9286/@SubViewportContainer@9287/@SubViewport@9288/Game/CharacterBody2D")]) +selected_nodes=Array[NodePath]([NodePath("/root/@EditorNode@17150/@Panel@13/@VBoxContainer@14/@HSplitContainer@17/@HSplitContainer@25/@HSplitContainer@33/@VBoxContainer@34/@VSplitContainer@36/@VSplitContainer@62/@VBoxContainer@63/@PanelContainer@110/MainScreen/@CanvasItemEditor@9465/@VSplitContainer@9284/@HSplitContainer@9286/@HSplitContainer@9288/@Control@9289/@SubViewportContainer@9290/@SubViewport@9291/RigidBody2D")]) diff --git a/.godot/editor/platform.tscn-editstate-cc2f727180cd42d9c13434cb55b1ce69.cfg b/.godot/editor/platform.tscn-editstate-cc2f727180cd42d9c13434cb55b1ce69.cfg index b140422..0223ba6 100644 --- a/.godot/editor/platform.tscn-editstate-cc2f727180cd42d9c13434cb55b1ce69.cfg +++ b/.godot/editor/platform.tscn-editstate-cc2f727180cd42d9c13434cb55b1ce69.cfg @@ -172,4 +172,4 @@ Anim={ "zfar": 4000.01, "znear": 0.05 } -selected_nodes=Array[NodePath]([NodePath("/root/@EditorNode@17140/@Panel@13/@VBoxContainer@14/@HSplitContainer@17/@HSplitContainer@25/@HSplitContainer@33/@VBoxContainer@34/@VSplitContainer@36/@VSplitContainer@62/@VBoxContainer@63/@PanelContainer@110/MainScreen/@CanvasItemEditor@9462/@VSplitContainer@9281/@HSplitContainer@9283/@HSplitContainer@9285/@Control@9286/@SubViewportContainer@9287/@SubViewport@9288/Game/CharacterBody2D")]) +selected_nodes=Array[NodePath]([NodePath("/root/@EditorNode@17150/@Panel@13/@VBoxContainer@14/@HSplitContainer@17/@HSplitContainer@25/@HSplitContainer@33/@VBoxContainer@34/@VSplitContainer@36/@VSplitContainer@62/@VBoxContainer@63/@PanelContainer@110/MainScreen/@CanvasItemEditor@9465/@VSplitContainer@9284/@HSplitContainer@9286/@HSplitContainer@9288/@Control@9289/@SubViewportContainer@9290/@SubViewport@9291/RigidBody2D")]) diff --git a/.godot/editor/project_metadata.cfg b/.godot/editor/project_metadata.cfg index 1e1162d..e8cde4b 100644 --- a/.godot/editor/project_metadata.cfg +++ b/.godot/editor/project_metadata.cfg @@ -1,6 +1,6 @@ [editor_metadata] -executable_path="/home/timbosga/Documents/software/godot/Godot_v4.2.1-stable_linux.x86_64" +executable_path="/Applications/Godot.app/Contents/MacOS/Godot" use_advanced_connections=false tile_source_sort=0 tile_snap_option=0 @@ -14,8 +14,8 @@ run_debug_collisions=false [recent_files] -scenes=["res://scenes/ui.tscn", "res://scenes/game.tscn", "res://scenes/slimeEnemy.tscn", "res://scenes/hud.tscn", "res://scenes/coin.tscn", "res://scenes/platform.tscn", "res://scenes/crate.tscn", "res://scenes/bullet.tscn", "res://scenes/character.tscn", "res://scenes/enemy.tscn"] -scripts=["res://scripts/ui.gd", "res://scripts/resources/characterStats.gd", "res://scripts/gameManager.gd", "CharacterBody2D", "res://scripts/enemy.gd", "res://scripts/coin.gd", "res://scripts/Trigger.gd", "res://scripts/bullet.gd", "res://scripts/CharacterBody2D.gd", "res://scripts/gamecontroller.gd"] +scenes=["res://scenes/game.tscn", "res://scenes/ui.tscn", "res://scenes/slimeEnemy.tscn", "res://scenes/hud.tscn", "res://scenes/coin.tscn", "res://scenes/platform.tscn", "res://scenes/crate.tscn", "res://scenes/bullet.tscn", "res://scenes/character.tscn", "res://scenes/enemy.tscn"] +scripts=["res://scripts/trigger.gd", "Node", "res://todo.txt", "res://scripts/ui.gd", "res://scripts/resources/characterStats.gd", "res://scripts/gameManager.gd", "CharacterBody2D", "res://scripts/enemy.gd", "res://scripts/coin.gd", "res://scripts/Trigger.gd"] [linked_properties] @@ -46,7 +46,7 @@ HBoxContainer:scale=true [dialog_bounds] create_new_node=Rect2(679, 94, 900, 883) -project_settings=Rect2(510, 190, 900, 700) +project_settings=Rect2(510, 190, 1408, 1462) [color_picker] diff --git a/.godot/editor/recent_dirs b/.godot/editor/recent_dirs index 2c16bb5..436d250 100644 --- a/.godot/editor/recent_dirs +++ b/.godot/editor/recent_dirs @@ -1,3 +1,4 @@ +/Users/winniekwan/Projects/TTLGodotCourse/ res://scripts res://scenes res://scripts/resources/ diff --git a/.godot/editor/script_editor_cache.cfg b/.godot/editor/script_editor_cache.cfg index 5ca5892..d5931ef 100644 --- a/.godot/editor/script_editor_cache.cfg +++ b/.godot/editor/script_editor_cache.cfg @@ -3,11 +3,11 @@ state={ "bookmarks": PackedInt32Array(), "breakpoints": PackedInt32Array(), -"column": 0, +"column": 15, "folded_lines": Array[int]([]), "h_scroll_position": 0, -"row": 39, -"scroll_position": 29.0, +"row": 16, +"scroll_position": 0.0, "selection": false, "syntax_highlighter": "GDScript" } @@ -31,10 +31,10 @@ state={ state={ "bookmarks": PackedInt32Array(), "breakpoints": PackedInt32Array(), -"column": 11, +"column": 28, "folded_lines": Array[int]([]), "h_scroll_position": 0, -"row": 5, +"row": 4, "scroll_position": 0.0, "selection": false, "syntax_highlighter": "GDScript" @@ -49,7 +49,7 @@ state={ "folded_lines": Array[int]([]), "h_scroll_position": 0, "row": 1, -"scroll_position": 22.0, +"scroll_position": 0.0, "selection": false, "syntax_highlighter": "GDScript" } @@ -59,11 +59,11 @@ state={ state={ "bookmarks": PackedInt32Array(), "breakpoints": PackedInt32Array(), -"column": 16, +"column": 36, "folded_lines": Array[int]([]), "h_scroll_position": 0, -"row": 29, -"scroll_position": 21.0, +"row": 90, +"scroll_position": 84.0, "selection": false, "syntax_highlighter": "GDScript" } @@ -73,12 +73,16 @@ state={ state={ "bookmarks": PackedInt32Array(), "breakpoints": PackedInt32Array(), -"column": 14, +"column": 16, "folded_lines": Array[int]([]), "h_scroll_position": 0, -"row": 23, +"row": 19, "scroll_position": 0.0, -"selection": false, +"selection": true, +"selection_from_column": 5, +"selection_from_line": 19, +"selection_to_column": 16, +"selection_to_line": 19, "syntax_highlighter": "GDScript" } @@ -113,3 +117,31 @@ state={ "selection_to_line": 5, "syntax_highlighter": "GDScript" } + +[res://todo.txt] + +state={ +"bookmarks": PackedInt32Array(), +"breakpoints": PackedInt32Array(), +"column": 39, +"folded_lines": Array[int]([]), +"h_scroll_position": 0, +"row": 9, +"scroll_position": 0.0, +"selection": false, +"syntax_highlighter": "Plain Text" +} + +[res://scripts/trigger.gd] + +state={ +"bookmarks": PackedInt32Array(), +"breakpoints": PackedInt32Array(), +"column": 0, +"folded_lines": Array[int]([]), +"h_scroll_position": 0, +"row": 0, +"scroll_position": 0.0, +"selection": false, +"syntax_highlighter": "GDScript" +} diff --git a/.godot/editor/slimeEnemy.tscn-editstate-7f960b0e063e7daa9b04ba3fda3f82d8.cfg b/.godot/editor/slimeEnemy.tscn-editstate-7f960b0e063e7daa9b04ba3fda3f82d8.cfg index 6094962..df1d4a6 100644 --- a/.godot/editor/slimeEnemy.tscn-editstate-7f960b0e063e7daa9b04ba3fda3f82d8.cfg +++ b/.godot/editor/slimeEnemy.tscn-editstate-7f960b0e063e7daa9b04ba3fda3f82d8.cfg @@ -172,4 +172,4 @@ Anim={ "zfar": 4000.01, "znear": 0.05 } -selected_nodes=Array[NodePath]([NodePath("/root/@EditorNode@17140/@Panel@13/@VBoxContainer@14/@HSplitContainer@17/@HSplitContainer@25/@HSplitContainer@33/@VBoxContainer@34/@VSplitContainer@36/@VSplitContainer@62/@VBoxContainer@63/@PanelContainer@110/MainScreen/@CanvasItemEditor@9462/@VSplitContainer@9281/@HSplitContainer@9283/@HSplitContainer@9285/@Control@9286/@SubViewportContainer@9287/@SubViewport@9288/Game/CharacterBody2D")]) +selected_nodes=Array[NodePath]([]) diff --git a/.godot/editor/ui.tscn-editstate-9211dc52ac9df169ba4fe77cbc1dc833.cfg b/.godot/editor/ui.tscn-editstate-9211dc52ac9df169ba4fe77cbc1dc833.cfg index 2525911..b4fbb67 100644 --- a/.godot/editor/ui.tscn-editstate-9211dc52ac9df169ba4fe77cbc1dc833.cfg +++ b/.godot/editor/ui.tscn-editstate-9211dc52ac9df169ba4fe77cbc1dc833.cfg @@ -172,4 +172,4 @@ Anim={ "zfar": 4000.01, "znear": 0.05 } -selected_nodes=Array[NodePath]([NodePath("/root/@EditorNode@17140/@Panel@13/@VBoxContainer@14/@HSplitContainer@17/@HSplitContainer@25/@HSplitContainer@33/@VBoxContainer@34/@VSplitContainer@36/@VSplitContainer@62/@VBoxContainer@63/@PanelContainer@110/MainScreen/@CanvasItemEditor@9462/@VSplitContainer@9281/@HSplitContainer@9283/@HSplitContainer@9285/@Control@9286/@SubViewportContainer@9287/@SubViewport@9288/Game/CharacterBody2D")]) +selected_nodes=Array[NodePath]([NodePath("/root/@EditorNode@17150/@Panel@13/@VBoxContainer@14/@HSplitContainer@17/@HSplitContainer@25/@HSplitContainer@33/@VBoxContainer@34/@VSplitContainer@36/@VSplitContainer@62/@VBoxContainer@63/@PanelContainer@110/MainScreen/@CanvasItemEditor@9465/@VSplitContainer@9284/@HSplitContainer@9286/@HSplitContainer@9288/@Control@9289/@SubViewportContainer@9290/@SubViewport@9291/RigidBody2D")]) diff --git a/.godot/uid_cache.bin b/.godot/uid_cache.bin index b486fd13a63380ce2b256a42c180d6c9cf3c4af9..ff939456ce41605e74ae869f783321d74c0e3fda 100644 GIT binary patch delta 33 pcmX@jahhYpD(1=BEDD@U6il-CH(#&Rn9Rr`J^2N*^W;^`QUJ(E3t0dF delta 19 bcmX@jahhYpD(1 0: player.currentHealth -= 20 - print("player health is now " + str(player.currentHealth)) func resetPlayer(): player.currentHealth = player.maxHealth diff --git a/scripts/gamecontroller.gd b/scripts/gamecontroller.gd index 8f34d05..b29ee04 100644 --- a/scripts/gamecontroller.gd +++ b/scripts/gamecontroller.gd @@ -11,10 +11,10 @@ var myBox = preload("res://scenes/crate.tscn") # Called when the node enters the scene tree for the first time. func _ready(): GameManager.resetPlayer() + GameManager.resetCoinCollectedCount() for n in coins.get_children(): if n is Coin: - #wire up our listener n.coinCollected.connect(_on_area_2d_coin_collected) for n in enemies.get_children(): if n is Enemy: @@ -27,7 +27,6 @@ func _process(delta): timer.start() func _on_area_2d_areatrigger(effect, body): - print("Game Controller sees the trigger " + effect) match effect: "alert": for n in 5: diff --git a/todo.txt b/todo.txt new file mode 100644 index 0000000..3335e5b --- /dev/null +++ b/todo.txt @@ -0,0 +1,10 @@ +A list of things to do to finish up the game: + - Reskin the main character + - Create a starting menu + - Have the character die when falling through the ground + - Reset the coin count when dying + - Add feedback when getting injured + - Have the bullet do something + - Look into the error when spawning crates + - Reskin the bullet so it's not a crate + - Have the falling crates do something