mirror of
https://github.com/kristoferssolo/FuncIt.git
synced 2025-10-21 19:30:35 +00:00
12 lines
371 B
GDScript
12 lines
371 B
GDScript
extends Node
|
|
|
|
func instance_node_at_location(node: Object, parent: Object, location: Vector2) -> Object:
|
|
var node_instance = instance_node(node, parent)
|
|
node_instance.global_position = location
|
|
return node_instance
|
|
|
|
func instance_node(node: Object, parent: Object) -> Object:
|
|
var node_instance = node.instance()
|
|
parent.add_child(node_instance)
|
|
return node_instance
|