📅  最后修改于: 2022-03-11 14:48:18.988000             🧑  作者: Mango
const pre_enemy_factory = preload("res://src/enemyfac.tscn")
var enemy_factory
func _ready():
enemy_factory = pre_enemy_factory.instance()
func add_enemy:
var enemy = enemy_factory.get_child("your enemy").duplicate()
level.add_child(enemy)