mirror of
https://codeberg.org/StreamGraph/StreamGraph.git
synced 2024-11-13 19:49:55 +01:00
27 lines
453 B
GDScript
27 lines
453 B
GDScript
extends DeckNode
|
|
|
|
|
|
func _init() -> void:
|
|
add_input_port(
|
|
Deck.Types.STRING,
|
|
"Text to print",
|
|
"field"
|
|
)
|
|
|
|
add_input_port(
|
|
Deck.Types.BOOL,
|
|
"Trigger",
|
|
"button"
|
|
)
|
|
|
|
name = "Print"
|
|
|
|
|
|
func _receive(to_port: int, data: DeckType, extra_data: Array = []) -> void:
|
|
if to_port != 1:
|
|
return
|
|
|
|
var data_to_print = data.get_value()
|
|
# var data_to_print = input_ports[0].value_callback.call()
|
|
print(data_to_print)
|
|
print("extra data: ", extra_data)
|