36 lines
639 B
GDScript
36 lines
639 B
GDScript
extends Reference
|
|
|
|
const NAME = "blocked"
|
|
|
|
var ctx = null
|
|
|
|
func _init():
|
|
pass
|
|
|
|
func enter_from(state, block_string = null):
|
|
ctx.progress_text.text = block_string
|
|
ctx.coin_machine.enabled = false
|
|
ctx.item_holder.add_enabled = true
|
|
for item_slot in ctx.item_slots:
|
|
item_slot.add_enabled = true
|
|
item_slot.remove_enabled = true
|
|
|
|
func exit_to(state):
|
|
pass
|
|
|
|
func update(delta):
|
|
pass
|
|
|
|
func on_coin_machine_coin_requirement_met(player):
|
|
assert(false)
|
|
|
|
func on_gen_timer_timeout():
|
|
assert(false)
|
|
|
|
func on_slot_item_changed(item):
|
|
pass
|
|
|
|
func on_item_holder_item_changed(item):
|
|
if item == null:
|
|
ctx.change_state(ctx.StateIdle.new())
|