Quantcast
Channel: Answers for "'GetComponent' is not a member of 'Object'... who said I was using an Object??"
Browsing all 4 articles
Browse latest View live

Answer by aldonaletto

This error should not happen, since *ent1* is a member variable declared as GameObject. The only thing I can think is that the compiler is creating a temporary variable *ent1* in the *for..in* loop -...

View Article



Answer by Mortoc

Your iteration variable has the same name as your member variable. Change the iterator (ent1) variable to a different name.

View Article

Answer by aldonaletto

This error should not happen, since *ent1* is a member variable declared as GameObject. The only thing I can think is that the compiler is creating a temporary variable *ent1* in the *for..in* loop -...

View Article

Answer by Mortoc

Your iteration variable has the same name as your member variable. Change the iterator (ent1) variable to a different name.

View Article
Browsing all 4 articles
Browse latest View live




Latest Images