360 movement (Top-Down)

Hi All,

I’m a newbie at unity and especially iPhone… What I’m trying to do is make a basic movement controller for a topdown view game.

I’d like an interface similar to the Occlusion Example (the 2 circles where you use your thumbs to navigate). The difference is I want the left hand circle to be used for rotating and moving in that direction… For example, if I touch the left part of the circle, I want the player object to turn to the right and start moving in that direction.

I want to reserve the other circle for shooting in different directions also.

Can any one offer any help - Sample code would be greatly appreciated!

Many thanks,

  • Mel

Essentially, you’ll be pushing the object in whatever direction that thumbpad says, and within a certain amount of time, orienting your player object to the same direction.

Despite what logic dictates (ie, if the character is facing screen-up and the thumbstick says go left), it is generally considered unresponsive and sloppy to a player if the character’s movement is locked to his rotation, rotation should be secondary to movement. (Unless you’re talking about a car)

So, like a FPS, movement is more important than rotation.

You will essentially need to go from any given rotation toward your movement vector with a given amount of latency.

Thanks for the reply,

I understand the theory pretty well, it’s just putting it into practice that absolutely baffles me. If anyone could knock up some example code of this particular movement I believe it would be very helpful to the all newbies in the community as there is nothing useable in any of the iphone examples.

Thanks in advance,

  • Mel

I second this, please. Been trying to work out the analog sticks as well, and can get the character to move, but it still faces the same direction, doesn;t roate with the left stick. The right stick can make it rotate but not at the same time as an animation, and only works as a left / right slider, instead of a 360 wheel rotation.

ack!