The directional facing of an entity in the game space.

learn more… | top users | synonyms

11
votes
4answers
2k views

Why is Y up in many Games?

I learned at school that the z-axis is up. It is the same in modeling software like Blender. However in many games the y-axis is up. What is reason?
9
votes
4answers
2k views

X, Y, Z coordinate standards?

I'm pretty new to 3D development of any kind, nonetheless games. As I read through tutorials and examples, I find that the X/Y/Z coordinates seem a bit backwards than my first guess. I had imagined ...
6
votes
1answer
2k views

Rotate object to face player

This is probably a simple vector question, but I'm not sure how to do it. I have an object at vector position (ox,oy). Potentially every update, the user walks around the screen, and will be at ...
6
votes
1answer
276 views

Changing orientation by applying torques

Suppose you've got an object floating freely in space. You have a vector you want this object to point towards, and a vector representing the direction it's currently facing. From these two, you can ...
4
votes
2answers
1k views

How is the gimbal locked problem solved using accumulative matrix transformations

I am reading the online "Learning Modern 3D Graphics Programming" book by Jason L. McKesson As of now, I am up to the gimbal lock problem and how to solve it using quaternions. However right here, ...
3
votes
2answers
227 views

How to calculate left/right oriented angle between two 2D vectors? [duplicate]

I would like to calculate angle between two 2D vectors. Here's a picture of what I'm trying to achieve: I have an obstacle line segment AB and incoming moving PC. If I'm coming from one side C¹D¹ ...
3
votes
3answers
98 views

How can I reorient the axes of an object?

I spent some time in Unity yesterday trying to fire a sphere from a horizontal cylinder (like a ball from a cannon). I was using Vector3.forward, but the sphere kept coming out the top of the cylinder ...
3
votes
1answer
77 views

Finding the monitors orientation in XNA for Windows

Just to be clear this is not for Windows Phone 7. =) I've got some interesting requirements for a project and I'm having trouble trying to find the information I need. I have two monitors. The ...
3
votes
1answer
152 views

How to make an object stay relative to another object

In the following example there is a guy and a boat. They have both a position, orientation and velocity. The guy is standing on the shore and would like to board. He changes his position so he is ...
3
votes
1answer
206 views

Follow point of interest by applying torque

Given a body with an orientation angle and a point of interest or targetAngle, is there an elegant solution for keeping the body oriented towards the point of interest by applying torque or impulses? ...
3
votes
1answer
149 views

How to map absolute Joystick position to object rotation?

In my (Ogre) 3d scene I have an object that should be rotated locally based on Joystick input. I have a Joystick with min/max values of [-32767, 32767] on both X and Y axes. When the Joystick is in ...
3
votes
1answer
212 views

How do I determine a device's default orientation?

I am developing a game with accelerometer controls. This works well on all the mobile phones I've tested it on. However, when testing on a tablet, the y and x axes are reversed, presumably because the ...
3
votes
1answer
982 views

Quaternion Look At with Up vector

I have implemented a "look at" method for my screen elements and it almost works how I want it to work. The ScreenElement class uses a R3 Vector and a Quaternion to determine the position and ...
3
votes
0answers
399 views

Setting Orientation of Character in Bullet/Ogre [closed]

I've been suffering from an issue regarding the implementation of orienting characters in a game I'm implementing using Ogre3D and Bullet physics. What I have: A Direction Vector that the character ...
3
votes
1answer
527 views

How can I use orientation to compute position in Windows Phone 7? [closed]

I'm using the motion API and I'm trying to figure out a control scheme for the game I'm currently developing. What I'm trying to achive is for an orienation of the device to correlate directly to a ...
1
vote
2answers
878 views

convert orientation vec3 to a rotation matrix

I've got a normalized vec3 that represents an orientation. Each frame of animation, an object's orientation changes slightly, so I add a delta vector to the orientation vector and then normalize to ...
1
vote
1answer
210 views

How do I fix my planet-facing camera?

Summary I'm having trouble implementing a camera controller suitable for first person use around a planet. The camera needs to be oriented correctly according to gravity (vector from camera ...
1
vote
1answer
224 views

Change game from portrait to landscape dynamically

I have multiple classes that implement Screen. I want to, say, have the Main Menu screen portrait, then the Play Screen landscape. Is there anyway of changing the orientation dynamically? I thought ...
1
vote
1answer
17 views

Unity Android Orientation Bug in Auto Rotate

I am currently looking for a workaround, or fix, for a Unity bug. I want to be able to auto-rotate my game, while respecting the Android system settings. Currently, if you set your Unity Orientation ...
0
votes
1answer
101 views

How can I support both multiple resolutions and multiple orientations in a game?

I am writing a mobile Android and iOS game. This game is similar to Doodle Jump, but without scrolling. In my game I display a background image that should cover the entire screen. On top of that I ...
0
votes
0answers
70 views

How manage target selection in a high speed brawler?

I'm thinking of games like Batman Arkham Asylum and the Assassin's Creed series, in which landing the first blow gives you a soft lock that automatically rotates you to continue facing the target as ...
0
votes
1answer
112 views

Relative Position/Rotation calculation

I have 2 objects each with a 3x3 Matrix (Orientation) and a Vector3 (Translation). Both are relative to world coordinates. How do I calculate the position and orientation of object B in relation to ...