24 lines
447 B
GDScript
24 lines
447 B
GDScript
extends Control
|
|
|
|
export(NodePath) var labelPath
|
|
export(NodePath) var continuePath
|
|
|
|
signal start_fight()
|
|
|
|
var _playerWonLabel
|
|
var _continueButton
|
|
|
|
func _ready():
|
|
_playerWonLabel = get_node(labelPath) as Label
|
|
_continueButton = get_node(continuePath) as Label
|
|
|
|
|
|
func set_win_message(player_id):
|
|
_playerWonLabel.text = "Player " + str(player_id + 1) + " is victorious!"
|
|
|
|
|
|
func _on_Continue_pressed():
|
|
print("test2")
|
|
|
|
emit_signal("start_fight")
|