- Home /
TransformPoint not working
SO I am getting an error MissingMethodException: Method not found: 'UnityEngine.Transform.TransformPoint'.
http://unity3d.com/support/documentation/ScriptReference/Transform.TransformPoint.html as the link shows the function clearly exists.
The line of code I am using is:
gameObject.camera.transform.position = object.transform.TransformPoint(script.cameraPoint);
object is a GameObject, script is a script with a variable cameraPoint : Vector3
Answer by Dunkhan · Nov 09, 2011 at 11:36 AM
I figured it out, pretty silly error. It was Java's dynamic typing. Just had to cast everything including across in the other script and then it worked. Pretty lame that it doesn't mention the arguments don't match in the error message.
Answer by JakeElliott · Nov 08, 2011 at 08:00 PM
Is your variable really named object
? That might be causing some conflicts.
Your answer
Follow this Question
Related Questions
I need help with an error 1 Answer
Every script says "can not load script" and that there is no monobehavior in the file 2 Answers
Player Prefs, Adding Two Variables 1 Answer
Limit rotation for a statue puzzle 1 Answer
SDK updater failed 0 Answers