Cyclic Dependecy with inherited Class

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By whiteshampoo

Hi,

maybe this is a stupid question.
I have a class Subject.
Classes Player and Enemy are inheriting Subject
I want to check if an detected Node is from the other class
if found_node is Player: [...] in Enemy
and
if found_node is Enemy: [...] in Player

but this gives my cyclic dependencies.
How can i do this?