You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

16 lines
450 B

  1. extends Node
  2. export var character_data : Resource
  3. var interaction_component : BasisInteraction
  4. func spawn():
  5. var inst = character_data.scene.instance()
  6. inst.name = character_data.name
  7. if character_data.yarn != null:
  8. interaction_component = TalkInteraction.new()
  9. interaction_component.name = character_data.yarn.resource_name
  10. interaction_component.yarn_script = character_data.yarn
  11. inst.add_child(interaction_component)
  12. add_child(inst)