Quick test that player sees interactible before bed.
This commit is contained in:
parent
3c38cdc258
commit
1cb72d1e43
|
|
@ -45,4 +45,4 @@ func _on_Interactable_Component_body_entered(body):
|
||||||
func _on_Interactable_Component_body_exited(body):
|
func _on_Interactable_Component_body_exited(body):
|
||||||
var colliding_node = body
|
var colliding_node = body
|
||||||
if colliding_node.has_node("Interactable_Receiver"):
|
if colliding_node.has_node("Interactable_Receiver"):
|
||||||
colliding_node.get_node("Interactable_Receiver").register_interactable(self)
|
colliding_node.get_node("Interactable_Receiver").remove_interactable(self)
|
||||||
|
|
|
||||||
|
|
@ -24,6 +24,8 @@ func hit_Receiver(damage):
|
||||||
yield( get_tree().create_timer(2 + $movement_state_machine/hurt.timeout_seconds), "timeout")
|
yield( get_tree().create_timer(2 + $movement_state_machine/hurt.timeout_seconds), "timeout")
|
||||||
$Hurtbox_Component.set_hurtbox(true)
|
$Hurtbox_Component.set_hurtbox(true)
|
||||||
|
|
||||||
|
func touch_the_thing():
|
||||||
|
print("You see! a THING...")
|
||||||
|
|
||||||
func _on_attack_do_attack():
|
func _on_attack_do_attack():
|
||||||
var is_shooting = false
|
var is_shooting = false
|
||||||
|
|
|
||||||
|
|
@ -562,9 +562,6 @@ __meta__ = {
|
||||||
script = ExtResource( 2 )
|
script = ExtResource( 2 )
|
||||||
player_number = 1
|
player_number = 1
|
||||||
|
|
||||||
[node name="movement_state_machine" parent="." index="3"]
|
|
||||||
debug_state_machine = true
|
|
||||||
|
|
||||||
[node name="idle" parent="movement_state_machine" index="0"]
|
[node name="idle" parent="movement_state_machine" index="0"]
|
||||||
script = ExtResource( 4 )
|
script = ExtResource( 4 )
|
||||||
move_speed = 1.0
|
move_speed = 1.0
|
||||||
|
|
@ -681,6 +678,7 @@ default_color = Color( 1, 0.607843, 0, 1 )
|
||||||
|
|
||||||
[node name="Interactable_Receiver" type="Node2D" parent="." index="8"]
|
[node name="Interactable_Receiver" type="Node2D" parent="." index="8"]
|
||||||
script = ExtResource( 16 )
|
script = ExtResource( 16 )
|
||||||
|
interactable_parent_callback = "touch_the_thing"
|
||||||
|
|
||||||
[connection signal="do_attack" from="movement_state_machine/attack" to="." method="_on_attack_do_attack"]
|
[connection signal="do_attack" from="movement_state_machine/attack" to="." method="_on_attack_do_attack"]
|
||||||
[connection signal="frame_reached" from="movement_state_machine/roll" to="." method="_on_roll_frame_reached"]
|
[connection signal="frame_reached" from="movement_state_machine/roll" to="." method="_on_roll_frame_reached"]
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user