Compare commits
No commits in common. "77c005e5db75cb6e6205191d3080cef72101e154" and "6418952c59642cd9773e60323126c9cf011bcc90" have entirely different histories.
77c005e5db
...
6418952c59
4 changed files with 5 additions and 8 deletions
|
|
@ -19,10 +19,6 @@ config/icon="res://icon.svg"
|
||||||
|
|
||||||
EventBus="*res://scenes/autoload/event_bus.tscn"
|
EventBus="*res://scenes/autoload/event_bus.tscn"
|
||||||
|
|
||||||
[debug]
|
|
||||||
|
|
||||||
gdscript/warnings/untyped_declaration=2
|
|
||||||
|
|
||||||
[display]
|
[display]
|
||||||
|
|
||||||
window/size/viewport_width=320
|
window/size/viewport_width=320
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,6 @@
|
||||||
extends Node
|
extends Node
|
||||||
|
|
||||||
@warning_ignore("unused_signal")
|
|
||||||
signal ball_hit(player: int, velocity: Vector2)
|
signal ball_hit(player: int, velocity: Vector2)
|
||||||
|
|
||||||
func _ready() -> void:
|
func _ready():
|
||||||
process_mode = Node.PROCESS_MODE_ALWAYS
|
process_mode = Node.PROCESS_MODE_ALWAYS
|
||||||
|
|
|
||||||
|
|
@ -31,6 +31,5 @@ func _on_hit(hitbox: Area2D) -> void:
|
||||||
EventBus.ball_hit.emit(player.id, linear_velocity)
|
EventBus.ball_hit.emit(player.id, linear_velocity)
|
||||||
is_hit = true
|
is_hit = true
|
||||||
|
|
||||||
|
|
||||||
func _on_hit_end() -> void:
|
func _on_hit_end() -> void:
|
||||||
is_hit = false
|
is_hit = false
|
||||||
|
|
|
||||||
|
|
@ -6,6 +6,9 @@ extends Area2D
|
||||||
func _ready() -> void:
|
func _ready() -> void:
|
||||||
timer.connect("timeout", _despawn)
|
timer.connect("timeout", _despawn)
|
||||||
|
|
||||||
|
# Called every frame. 'delta' is the elapsed time since the previous frame.
|
||||||
|
func _process(delta: float) -> void:
|
||||||
|
pass
|
||||||
|
|
||||||
func _despawn() -> void:
|
func _despawn() -> void:
|
||||||
queue_free()
|
queue_free()
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue