2015-09-16 01:07:03 +00:00
|
|
|
|
|
|
|
extends RigidBody2D
|
|
|
|
|
2015-11-21 15:13:43 +00:00
|
|
|
# Member variables
|
|
|
|
var timeout = 5
|
2015-09-16 01:07:03 +00:00
|
|
|
|
|
|
|
|
|
|
|
func _process(delta):
|
2015-11-21 15:13:43 +00:00
|
|
|
timeout -= delta
|
|
|
|
if (timeout < 1):
|
2015-09-16 01:07:03 +00:00
|
|
|
set_opacity(timeout)
|
2015-11-21 15:13:43 +00:00
|
|
|
if (timeout < 0):
|
2015-09-16 01:07:03 +00:00
|
|
|
queue_free()
|
|
|
|
|
|
|
|
|
2015-11-21 15:13:43 +00:00
|
|
|
func _ready():
|
|
|
|
set_process(true)
|