I’m grateful if you could answer the following questions:
how is timing done in fixedupdate() ? I don’t understand the function. Is it always called the same number of times per second ie fixed timing loop?
how are physics sped up and slowed down depending on the computer’s speed? is this automatically synched to 60fps? what happens to physics when the game is running at 800 fps?
where should I place my mainloop script? a script where I want things done every frame regardless that aren’t object specific?
whats the speed difference on iphone with unityscript (javascript) vs c# ? which is faster?
I would like to use shaped colliders ie box collider for my game, however it needs quite a few but when I select another GameObject with a collider, I cannot see the others in relation to it. Is there a way to force unity to show all colliders while editing one collider?
Is it ok to transform the GameObject instead of the collider, ie position, scale and rotation?
Eric, when I transform a GameObject’s scale with an attached Collider component, it scales the collider. Please try it and you’ll see. It also seems to work perfectly well but I don’t know if it is doing weird or game breaking math behind the scenes if I do this.
Can anyone confirm?
On my other question I asked if fixedupdate would run a set amount of times, and you replied it would. Is there a way to change this, or is it tied to the physics engine? Can I put all my time-sensitive maths in fixedupdate instead of using delta timing? I really loathe delta timing, thats all.
You should keep the scale at <1,1,1> unless there’s a good reason to do otherwise (e.g., animating the scale), since anything else seems to slow it down.
It’s tied to the physics engine. You can change whatever the fixed update interval is, but the point of that is to make the physics run more or less often.
It’s really not a good idea. There’s nothing wrong with deltaTime, and as I mentioned, FixedUpdate doesn’t necessarily run the same number of times per second, such as when the framerate drops sufficiently. In which case your time-sensitive math will be screwed, so you need to use deltaTime in FixedUpdate as well, which means there’s no point putting that code in FixedUpdate in the first place.