9 lines
197 B
GDScript3
9 lines
197 B
GDScript3
|
class_name CharacterComponent
|
||
|
extends Node
|
||
|
|
||
|
var character: Character
|
||
|
|
||
|
func _enter_tree():
|
||
|
assert(owner, "owner not set")
|
||
|
assert(owner is Character, "owner must be a character")
|
||
|
character = owner
|