RotateAround still works, but I get a warning saying its obsolete, How would you setup the rotate around now? I posted a simplified version of my script, since the original one is too long.
Original Script
if (GameObject.Find(SystemSizeSetup<em>.name + "/Satellites/" + SystemSizeSetup<em>.Satellites[a].name)) GameObject.Find(SystemSizeSetup<em>.name + "/Satellites/" + SystemSizeSetup<em>.Satellites[a].name).transform.RotateAround(GameObject.Find(SystemSizeSetup<em>.name + "/Satellites/" + SystemSizeSetup<em>.Satellites[a].name).transform.up, -1*(SystemSizeSetup_.Satellites[a].orbitSatData.Speed/100)*Time.deltaTime);_</em></em></em></em></em></em>
Simplified Script if GameObject.Find(Moon) Moon.transform.RotateAround(GameObject.Find(Moon).transform.up, speed*Time.deltaTime); I’ve read the following script is a workaround, but I use transform.up and deltaTime and not x,y,z void Rotate(float xAngle, float yAngle, float zAngle, Space relativeTo);
There are two versions of RotateAround(). One take a point and is documented, the other (the obsolete one) does not and is not documented. Use the first version and specify transform.position for the point.
Ok, I checked, the code looked exactly what I written, and it was very easy to mislook the extra code, didn’t know there were 2 versions, the only thing I added was; “Vector3.zero”, now it works without warning and the moon still rotates, as it did before unity update without the extra code. Thx for the info, even thou I had to double check to see what was different from mine.
Here is a quick fix for the newer Unity 4.2.1 version, the solution was to add “Vector3.zero”