added coins

This commit is contained in:
Jonas Braus
2024-07-28 21:20:05 +02:00
parent d13361cdb1
commit 5299f67b81
9 changed files with 239 additions and 3 deletions
+34 -1
View File
@@ -1,7 +1,9 @@
[gd_scene load_steps=13 format=3 uid="uid://dk1aby88pygtr"]
[gd_scene load_steps=15 format=3 uid="uid://dk1aby88pygtr"]
[ext_resource type="Script" path="res://scripts/player.gd" id="1_lm7ix"]
[ext_resource type="Texture2D" uid="uid://dhw3lpuskbvku" path="res://assets/mario-luigi-4.png" id="1_w3chr"]
[ext_resource type="FontFile" uid="uid://cpwx7datjer6s" path="res://assets/PixelOperator8.ttf" id="3_mkgvb"]
[ext_resource type="Texture2D" uid="uid://d0xxlo60h1d7i" path="res://assets/coinlabel.png" id="4_o0q77"]
[sub_resource type="AtlasTexture" id="AtlasTexture_l22ll"]
atlas = ExtResource("1_w3chr")
@@ -137,6 +139,37 @@ one_shot = true
[node name="pipe_timer_half" type="Timer" parent="."]
one_shot = true
[node name="CanvasLayer" type="CanvasLayer" parent="."]
[node name="Control" type="Control" parent="CanvasLayer"]
layout_mode = 3
anchors_preset = 15
anchor_right = 1.0
anchor_bottom = 1.0
grow_horizontal = 2
grow_vertical = 2
[node name="CoinAmt" type="Label" parent="CanvasLayer/Control"]
layout_mode = 1
offset_left = 136.0
offset_top = 56.0
offset_right = 241.0
offset_bottom = 104.0
theme_override_colors/font_color = Color(1, 0.627451, 0.266667, 1)
theme_override_fonts/font = ExtResource("3_mkgvb")
theme_override_font_sizes/font_size = 40
text = "0
"
vertical_alignment = 1
[node name="CoinLabel" type="TextureRect" parent="CanvasLayer/Control"]
layout_mode = 0
offset_left = 80.0
offset_top = 56.0
offset_right = 120.0
offset_bottom = 96.0
texture = ExtResource("4_o0q77")
[connection signal="area_entered" from="pipedetector_ground" to="." method="_on_pipedetector_area_entered"]
[connection signal="area_exited" from="pipedetector_ground" to="." method="_on_pipedetector_area_exited"]
[connection signal="area_entered" from="pipedetector_right" to="." method="_on_pipedetector_right_area_entered"]