Advertisement Jump to content
  • Advertisement
  • entries
  • comments
  • views

Hmm, this is a new one..

Sign in to follow this  


Right, so my attempts at revision worked this morning but failed this afternoon when I decided that taking a 2hr "power nap" was a better plan. Back to work as soon as I've finished this [headshake]

Working with XInput and the XB360 controller again... I got the thumbsticks working now. That was really hard by XInput standards - I had to compute deadzones [oh]

Anyway, the left thumbstick X axis rotates the camera and the right thumbstick Y axis "zooms". It's not quite zoom as it doesn't alter the FOV - just moves the camera closer. This means that when the camera gets fully zoomed in it appears to be almost top-down.

A combination of these has led me to think about how I want the player to control things. I've not had to do that before - it's always been obvious (aka copy what the other guys do).

The biggest problem is with rotation - as soon as you change the angle then the corresponding player movement is unintuitive. For example, from a camera at 0o DPAD-LEFT appears to move the player left, from 180o DPAD-LEFT moves the player right. Regardless of this, the player still transitions from tile-to-tile in the same direction.

As I see it, there are a couple of routes:
  1. Have a reset button. If the user presses "A" for example then the camera rotates to be "behind" the player.
    Allows the player to get back to normal if they get "lost".
    Requires the player to want to reset, meaning the view has to be wrong before they correct it.
  2. Have the camera auto-reset when the player moves. Allow camera manipulation only when they're stationary.
    The game takes care of things automagically.
    What if the player doesn't like the "normal" view.
  3. Completely change how the player is moved. Currently the player moves relative to the world, whereas I could make it such that DPAD-UP is whatever direction the camera is facing.
    Would eliminate the problem entirely.
    My game only have 8 possible movement directions - it's not freeform. It makes the camera involved in the gameplay, I like the way it's just a "view" into the game.

I'd be very interested in any ideas you guys have (nudge-nudge [wink] [wink])...
Sign in to follow this  


Recommended Comments

I'd like to propose a variant to 2 - have the view return to normal whenever the user releases the thumbstick - similar to the view inside the car in pgr3.

Share this comment

Link to comment
Hmm, I like the sound of that variant.

So basically, you have to hold the thumbstick in the position that you want to view from...

Thing is, how do you map -1..+1 to a full circle? currently moving it left/right just increments/decrements an angle around a circle, wrapping as appropriate.


Share this comment

Link to comment
I suppose so... but I haven't played many simple puzzle-type games lately (even then, I don't tend to play with a gamepad).

The character can go in 1 of 8 directions - up/down/left/right and diagonal. Yet the camera has 360 degrees of rotation... thus you can't always move in the direction the camera is facing..

I wanted to include camera navigation so that you could (potentially) look around the "puzzle space" and see things that you might not always see from a default angle..


Share this comment

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement

Important Information

By using, you agree to our community Guidelines, Terms of Use, and Privacy Policy. is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!