- Home /
Jumping to high
Hi all.
I'm making this 2D sidescroller for the iPhone, and I have a really annoying problem when my character jumps. I apologize ahead of my question, for not providing sufficient data, but I really don't know what data to give.
The problem is, that when I play my game on my iPhone, once in a while (seldom!), my character starts jumping twice as high as he otherwise would.
All jumps are made with rigidbody.AddForce. All physics are in a fixed update, and all controls are in ordinary update functions.
I've made keyboard controls, so I can test the game in Unity, and the touch controls are made in the same way as the keyboard controls. (For jump, Keyboard is OnKeyDown and touch is touchPhase == touches.began) This never happens when I'm testing in Unity, and when it happens on the phone, it seems to always be while xCode is running it. If I stop xCode and restart it on the phone, I can't seem to replicate the problem (or I simply haven't had the luck).
Has anyone in here experienced something like it??