I am really stuck trying to figure out how to cast. Specifically, I have an Enemy component that is added to a GameObject and I am trying to call iTween on itself.
“iTween.MoveTo(this…” does not work, I get something like “expecting GameObject, not Enemy”
So how do I get the GameObject?
I tried “iTween.MoveTo(this as GameObject” and I get back “this is not a GameObject”
I tried:
“var go : GameObject = this;”
“iTween.MoveTo(this…”
This compiles and runs, but crashes with the same “not expecting an Enemy”
And this does not compile either
“var go : GameObject = this.GetComponent(GameObject);”
I realize it should not compile, but I am grasping at straws at this point.