Procházet zdrojové kódy

Show colored death at crash

DricomDragon před 4 roky
rodič
revize
5bf9dbb807
3 změnil soubory, kde provedl 46 přidání a 2 odebrání
  1. binární
      Resources/Images/crash.png
  2. 34 0
      Resources/Images/crash.png.import
  3. 12 2
      Scenes/Player.tscn

binární
Resources/Images/crash.png


+ 34 - 0
Resources/Images/crash.png.import

@@ -0,0 +1,34 @@
+[remap]
+
+importer="texture"
+type="StreamTexture"
+path="res://.import/crash.png-980821fbf9675e1af92728e819feef06.stex"
+metadata={
+"vram_texture": false
+}
+
+[deps]
+
+source_file="res://Resources/Images/crash.png"
+dest_files=[ "res://.import/crash.png-980821fbf9675e1af92728e819feef06.stex" ]
+
+[params]
+
+compress/mode=0
+compress/lossy_quality=0.7
+compress/hdr_mode=0
+compress/bptc_ldr=0
+compress/normal_map=0
+flags/repeat=0
+flags/filter=true
+flags/mipmaps=false
+flags/anisotropic=false
+flags/srgb=2
+process/fix_alpha_border=true
+process/premult_alpha=false
+process/HDR_as_SRGB=false
+process/invert_color=false
+stream=false
+size_limit=0
+detect_3d=true
+svg/scale=1.0

+ 12 - 2
Scenes/Player.tscn

@@ -1,8 +1,9 @@
-[gd_scene load_steps=5 format=2]
+[gd_scene load_steps=6 format=2]
 
 [ext_resource path="res://Scripts/Player.gd" type="Script" id=1]
 [ext_resource path="res://Scripts/CharTween.gd" type="Script" id=2]
 [ext_resource path="res://Resources/Images/player.png" type="Texture" id=3]
+[ext_resource path="res://Resources/Images/crash.png" type="Texture" id=4]
 
 [sub_resource type="RectangleShape2D" id=1]
 extents = Vector2( 16, 16 )
@@ -12,13 +13,21 @@ extents = Vector2( 16, 16 )
 ]]
 script = ExtResource( 1 )
 
-[node name="Sprite" type="Sprite" parent="."]
+[node name="Liner" type="Sprite" parent="."]
 z_index = 1
 texture = ExtResource( 3 )
 __meta__ = {
 "_edit_lock_": true
 }
 
+[node name="Crash" type="Sprite" parent="."]
+visible = false
+z_index = 1
+texture = ExtResource( 4 )
+__meta__ = {
+"_edit_lock_": true
+}
+
 [node name="HitBox" type="CollisionShape2D" parent="."]
 shape = SubResource( 1 )
 __meta__ = {
@@ -28,3 +37,4 @@ __meta__ = {
 [node name="Tween" type="Tween" parent="."]
 script = ExtResource( 2 )
 [connection signal="body_entered" from="." to="." method="_on_crash"]
+[connection signal="crash" from="." to="Crash" method="show"]