Extensive work on animations and partially functional level keys, new UI gears but needs rounding error correction. Particle preloader added.
This commit is contained in:
18
scripts/collectable_depot.gd
Normal file
18
scripts/collectable_depot.gd
Normal file
@@ -0,0 +1,18 @@
|
||||
extends CSGCylinder3D
|
||||
|
||||
var time_remaining : float
|
||||
var collectable : Collectable
|
||||
|
||||
func generate_collectable() -> void:
|
||||
pass
|
||||
func _process(delta: float) -> void:
|
||||
if time_remaining > 0:
|
||||
time_remaining -= delta
|
||||
|
||||
if time_remaining <= 0 and collectable == null:
|
||||
generate_collectable()
|
||||
time_remaining = Game.level.collectable_drop_time
|
||||
|
||||
|
||||
func _on_collectable_collected() -> void:
|
||||
collectable = null
|
||||
Reference in New Issue
Block a user