forked from team-sg/hero-mark-2
add oxygen timer
This commit is contained in:
parent
fd218d6b13
commit
e6a393c5e2
22 changed files with 314 additions and 13 deletions
|
@ -1,7 +1,7 @@
|
|||
[gd_scene load_steps=44 format=2]
|
||||
[gd_scene load_steps=47 format=2]
|
||||
|
||||
[ext_resource path="res://objects/player/player.gd" type="Script" id=1]
|
||||
[ext_resource path="res://graphics/player/sg_duck.png" type="Texture" id=2]
|
||||
[ext_resource path="res://graphics/player/palettes/default.png" type="Texture" id=2]
|
||||
[ext_resource path="res://shaders/recolor_border.shader" type="Shader" id=3]
|
||||
[ext_resource path="res://graphics/player/sg_idle.png" type="Texture" id=4]
|
||||
[ext_resource path="res://addons/godot_state_charts/parallel_state.gd" type="Script" id=5]
|
||||
|
@ -23,11 +23,14 @@
|
|||
[ext_resource path="res://graphics/player/sg_push.png" type="Texture" id=21]
|
||||
[ext_resource path="res://graphics/player/sg_blink.png" type="Texture" id=22]
|
||||
[ext_resource path="res://graphics/player/sg_stim.png" type="Texture" id=23]
|
||||
[ext_resource path="res://graphics/player/sg_duck.png" type="Texture" id=24]
|
||||
[ext_resource path="res://graphics/player/sg_jump_megaman.png" type="Texture" id=25]
|
||||
|
||||
[sub_resource type="ShaderMaterial" id=1]
|
||||
shader = ExtResource( 3 )
|
||||
shader_param/border_color = Color( 0, 0, 0, 1 )
|
||||
shader_param/border_corners = true
|
||||
shader_param/palette = ExtResource( 2 )
|
||||
|
||||
[sub_resource type="Curve" id=13]
|
||||
_data = [ Vector2( 0, 1 ), 0.0, -0.0636948, 0, 0, Vector2( 1, 0 ), -3.43886, 0.0, 0, 0 ]
|
||||
|
@ -265,7 +268,7 @@ tracks/0/keys = {
|
|||
"times": PoolRealArray( 0 ),
|
||||
"transitions": PoolRealArray( 1 ),
|
||||
"update": 1,
|
||||
"values": [ ExtResource( 2 ) ]
|
||||
"values": [ ExtResource( 24 ) ]
|
||||
}
|
||||
tracks/1/type = "value"
|
||||
tracks/1/path = NodePath("Graphics/Sprite:hframes")
|
||||
|
@ -513,6 +516,58 @@ tracks/3/keys = {
|
|||
"values": [ 0.0 ]
|
||||
}
|
||||
|
||||
[sub_resource type="Animation" id=21]
|
||||
resource_name = "jump2"
|
||||
length = 0.001
|
||||
tracks/0/type = "value"
|
||||
tracks/0/path = NodePath("Graphics/Sprite:texture")
|
||||
tracks/0/interp = 1
|
||||
tracks/0/loop_wrap = true
|
||||
tracks/0/imported = false
|
||||
tracks/0/enabled = true
|
||||
tracks/0/keys = {
|
||||
"times": PoolRealArray( 0 ),
|
||||
"transitions": PoolRealArray( 1 ),
|
||||
"update": 1,
|
||||
"values": [ ExtResource( 25 ) ]
|
||||
}
|
||||
tracks/1/type = "value"
|
||||
tracks/1/path = NodePath("Graphics/Sprite:hframes")
|
||||
tracks/1/interp = 1
|
||||
tracks/1/loop_wrap = true
|
||||
tracks/1/imported = false
|
||||
tracks/1/enabled = true
|
||||
tracks/1/keys = {
|
||||
"times": PoolRealArray( 0 ),
|
||||
"transitions": PoolRealArray( 1 ),
|
||||
"update": 1,
|
||||
"values": [ 1 ]
|
||||
}
|
||||
tracks/2/type = "value"
|
||||
tracks/2/path = NodePath("Graphics/Sprite:frame")
|
||||
tracks/2/interp = 1
|
||||
tracks/2/loop_wrap = true
|
||||
tracks/2/imported = false
|
||||
tracks/2/enabled = true
|
||||
tracks/2/keys = {
|
||||
"times": PoolRealArray( 0 ),
|
||||
"transitions": PoolRealArray( 1 ),
|
||||
"update": 1,
|
||||
"values": [ 0 ]
|
||||
}
|
||||
tracks/3/type = "value"
|
||||
tracks/3/path = NodePath("Graphics/Sprite:rotation_degrees")
|
||||
tracks/3/interp = 1
|
||||
tracks/3/loop_wrap = true
|
||||
tracks/3/imported = false
|
||||
tracks/3/enabled = true
|
||||
tracks/3/keys = {
|
||||
"times": PoolRealArray( 0 ),
|
||||
"transitions": PoolRealArray( 1 ),
|
||||
"update": 0,
|
||||
"values": [ 0.0 ]
|
||||
}
|
||||
|
||||
[sub_resource type="Animation" id=17]
|
||||
resource_name = "push"
|
||||
length = 0.8
|
||||
|
@ -908,6 +963,7 @@ anims/fall = SubResource( 15 )
|
|||
anims/fall_scared = SubResource( 14 )
|
||||
anims/idle = SubResource( 6 )
|
||||
anims/jump = SubResource( 8 )
|
||||
anims/jump2 = SubResource( 21 )
|
||||
anims/push = SubResource( 17 )
|
||||
anims/shoot_airborne = SubResource( 11 )
|
||||
anims/shoot_grounded = SubResource( 10 )
|
||||
|
@ -1254,6 +1310,10 @@ theme = ExtResource( 7 )
|
|||
custom_styles/bg = SubResource( 4 )
|
||||
script = ExtResource( 8 )
|
||||
|
||||
[node name="OxygenTimer" type="Timer" parent="."]
|
||||
wait_time = 20.0
|
||||
autostart = true
|
||||
|
||||
[connection signal="body_entered" from="Hitbox" to="." method="_on_Hitbox_body_entered"]
|
||||
[connection signal="state_physics_processing" from="StateChart/Root/Movement" to="." method="_process_movement"]
|
||||
[connection signal="state_entered" from="StateChart/Root/Movement/Grounded" to="." method="_on_Grounded_state_entered"]
|
||||
|
@ -1289,3 +1349,4 @@ script = ExtResource( 8 )
|
|||
[connection signal="state_physics_processing" from="StateChart/Root/Movement/Climbing" to="." method="_process_climbing"]
|
||||
[connection signal="state_entered" from="StateChart/Root/Health/Respawn" to="." method="_on_Respawn_state_entered"]
|
||||
[connection signal="state_entered" from="StateChart/Root/Health/Dead" to="." method="_on_Dead_state_entered"]
|
||||
[connection signal="timeout" from="OxygenTimer" to="." method="_on_OxygenTimer_timeout"]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue