From 0bfda86c29d106df5fa3dd16d925c193b3f726c7 Mon Sep 17 00:00:00 2001 From: Daniel Weipert Date: Mon, 25 Dec 2023 00:21:50 +0100 Subject: UI + HUD alignment --- Characters/Character.gd | 2 +- Characters/Dove.tscn | 4 ++++ Characters/Duck.tscn | 4 ++++ Characters/Elephant.tscn | 4 ++++ Characters/Monkey.gd | 2 +- Characters/Monkey.tscn | 4 ++++ Characters/Pidgin.tscn | 4 ++++ Characters/Tux.tscn | 2 +- 8 files changed, 23 insertions(+), 3 deletions(-) (limited to 'Characters') diff --git a/Characters/Character.gd b/Characters/Character.gd index b9bcd16..fc33096 100644 --- a/Characters/Character.gd +++ b/Characters/Character.gd @@ -6,7 +6,7 @@ const JUMPFORCE = -500 const GRAVITY = 20 const RUNSPEED = SPEED * 2 const WALLJUMPFORCE = JUMPFORCE * 0.75 -const WALLJUMPSPEED = SPEED * 8 +var WALLJUMPSPEED = SPEED * 8 var direction = Enum.DIRECTION.RIGHT diff --git a/Characters/Dove.tscn b/Characters/Dove.tscn index 0871bfa..de4df62 100644 --- a/Characters/Dove.tscn +++ b/Characters/Dove.tscn @@ -110,3 +110,7 @@ shape = SubResource("2") target_position = Vector2(0, 150) [node name="CheckFallLanding" type="RayCast2D" parent="."] + +[node name="WalljumpTimer" type="Timer" parent="."] +wait_time = 0.1 +one_shot = true diff --git a/Characters/Duck.tscn b/Characters/Duck.tscn index ea974d8..24fcddb 100644 --- a/Characters/Duck.tscn +++ b/Characters/Duck.tscn @@ -110,3 +110,7 @@ shape = SubResource("2") target_position = Vector2(0, 150) [node name="CheckFallLanding" type="RayCast2D" parent="."] + +[node name="WalljumpTimer" type="Timer" parent="."] +wait_time = 0.1 +one_shot = true diff --git a/Characters/Elephant.tscn b/Characters/Elephant.tscn index d0f9c73..1d664ae 100644 --- a/Characters/Elephant.tscn +++ b/Characters/Elephant.tscn @@ -80,3 +80,7 @@ animation = &"idle" [node name="CollisionShape2D" type="CollisionShape2D" parent="."] position = Vector2(2.38419e-07, 1.5) shape = SubResource("2") + +[node name="WalljumpTimer" type="Timer" parent="."] +wait_time = 0.1 +one_shot = true diff --git a/Characters/Monkey.gd b/Characters/Monkey.gd index b7c6d31..d39d9f8 100644 --- a/Characters/Monkey.gd +++ b/Characters/Monkey.gd @@ -2,4 +2,4 @@ extends "res://Characters/Character.gd" func _ready(): - pass + WALLJUMPSPEED = SPEED * 10 diff --git a/Characters/Monkey.tscn b/Characters/Monkey.tscn index 0c1889a..c86bbf0 100644 --- a/Characters/Monkey.tscn +++ b/Characters/Monkey.tscn @@ -80,3 +80,7 @@ animation = &"idle" [node name="CollisionShape2D" type="CollisionShape2D" parent="."] position = Vector2(2.38419e-07, -2.38419e-07) shape = SubResource("2") + +[node name="WalljumpTimer" type="Timer" parent="."] +wait_time = 0.1 +one_shot = true diff --git a/Characters/Pidgin.tscn b/Characters/Pidgin.tscn index 5410b71..4085500 100644 --- a/Characters/Pidgin.tscn +++ b/Characters/Pidgin.tscn @@ -110,3 +110,7 @@ shape = SubResource("2") target_position = Vector2(0, 150) [node name="CheckFallLanding" type="RayCast2D" parent="."] + +[node name="WalljumpTimer" type="Timer" parent="."] +wait_time = 0.1 +one_shot = true diff --git a/Characters/Tux.tscn b/Characters/Tux.tscn index 6a5b6de..3da5f79 100644 --- a/Characters/Tux.tscn +++ b/Characters/Tux.tscn @@ -113,5 +113,5 @@ target_position = Vector2(0, 150) [node name="CheckFallLanding" type="RayCast2D" parent="."] [node name="WalljumpTimer" type="Timer" parent="."] -wait_time = 0.25 +wait_time = 0.1 one_shot = true -- cgit v1.2.3