Question by
wildlo93 · Jul 14, 2016 at 02:07 PM ·
errorgetcomponent
why i am getting this errorr....
11.png
(17.2 kB)
Comment
Best Answer
Answer by EDevJogos · Jul 14, 2016 at 02:10 PM
You must pass the component you want to get:
GetComponent<Rigidbody>().AddForce()
https://unity3d.com/pt/learn/tutorials/topics/scripting/getcomponent
Your answer
Follow this Question
Related Questions
C# - Cannnot access variable in another script unless I get the component everytime. 1 Answer
NullReferenceException: Object reference not set to an instance of an object 1 Answer
Object reference; sometimes works but sometimes doesn't??? 2 Answers
How to fix "no overload for method get component takes 1 arguments" 1 Answer
Unity3d Script does not work anymore 1 Answer