A branch of mathematics that studies triangles and the relationships between their sides and the angles between these sides.

learn more… | top users | synonyms

0
votes
0answers
75 views

How do I find the camera direction vector for 3D sound purposes? (C++, DirectX)

Question I'm trying to make a sound class for playing 3D sound effects with DirectSound and DirectX, without using DirectSound's 3D libraries. The plan is to have every game object constantly play ...
3
votes
1answer
118 views

determine collision angle on a rotating body

update: new diagram and updated description I have a contact listener set up to try and determine the side that a collision happened at relative to the a bodies rotation. One way to solve this is ...
0
votes
0answers
27 views

How to find optimal perpendicular axis of rotation vector to draw arrows?

I am drawing lines on the screen. Each line has a point (x,y,z) and a direction (u,v,w). I want to draw arrow heads on these lines, like two lines that start from (x,y,z) and leave at a 15 degree ...
1
vote
0answers
77 views

3D Camera Y-Axis wrong angle

I am trying to build a camera class, though I am running into a problem. When I move the camera above/below, and try to move towards the ground, I am moved off in what seems to be about 45 degrees in ...
1
vote
2answers
103 views

How can I fix my sprite being rotated 90 degrees more than toward the mouse?

I am trying to get a Sprite in LibGDX to look at the player's mouse. Here's the code I have (mind you, I am using JRuby): target = mouse_position.sub(spatial.position) rotation = ...
1
vote
1answer
189 views

How do I find two points at an angle on opposite sides of a circle?

With reference to my previous question: I'm using micklh's answer, which works perfectly. However, it calculates the gradient based on two points, a starting point and an ending point. I want to ...
0
votes
1answer
78 views

How do I lock drawn lines to be orthogonal to an existing one?

I'm making a 2D game in Corona for Android/iPhone that is similar to Volfied. In my game, the user has to touch the screen to draw a line for the character to move along. How can I force the lines to ...
2
votes
3answers
164 views

breakout game, computing optimal ricochet angle of a ball to get to a certain point

perhaps the title isn't clear so here is an explanation with a picture to better express my question Consider the following breakout clone game where the game is rigged to change the ricochet ...
0
votes
2answers
104 views

infer half vector length in BRDF

it's my first question on stack. Is it possible to infer length of the half angle vector for specular lighting from N·L and N·V without the whole view and light vectors? I may be completely off-track, ...
1
vote
0answers
116 views

Handling angles in multiplayer games

I am developing a small 2d multiplayer game. My most recent concern is, that trigonometric functions can take up a lot of time in any processor, and I was wondering if I could reduce this. So in my ...
0
votes
1answer
501 views

How to shoot on direction of touch

I'm new to the Corona SDK(and I also suck in trigonometry) and I'm trying to achieve this: Shoot a bullet from the player, towards the direction of the point the user touched, but always with ethe ...
4
votes
3answers
117 views

Propel entities at some angle (depending on explosion's position)

I have a 2D platformer. There are multiple particles that are just 1x1 colored pixels. Let's assume there are 256 particles laid out as a 16x16 cube. Say I popped an explosion right in the middle. All ...
0
votes
1answer
68 views

Get rotate angle using a formula

I am developing a game that is being played on a board with the top first tile having the coordinates [0,0], the next one has [0,1], second row has [1,0]... and so on (most likely this would be a ...
1
vote
2answers
201 views

Bullet entry Point around Player Object

I have a player rotating by the mouse and want the bullets line up with the player's gun. Right now they simply come from the point of the player and shoot in the direction of mouse. I just need the ...
0
votes
1answer
105 views

“Walking” along a rotating surface in LimeJS

I'm trying to have a character walk along a plank (a long, thin rectangle) that works like a seesaw, being rotated around a central point by box2d physics (falling objects). I want the left and right ...
0
votes
2answers
108 views

Need to use trig to make a ship point in the right direction

I'm making a 2D spaceship-shooter game that moves in all directions, (i.e. ( -x, +x ),( -y, +y ) ). I'm trying to make the spaceship face the direction of the movement according to a virtual ...
0
votes
2answers
339 views

Asteroids Movement

I have been making an asteroids clone, in C#. However, the ship's movement is... not quite right. My plan is this: there is a speed, and two directions, namely the direction the ship is facing ...
1
vote
1answer
155 views

Using circles to create a sphere

I've been working on creating spheres in a 3D space recently, and have successfully created cylinders. I've just run into a little problem. For some reason, my "Spheres" end up looking like very thick ...
0
votes
1answer
179 views

getting direction of x and y… north,south,east,west

I have a player in the center of the screen, where I also have my mouse position origin. (0,0) I would like to know the direction of the mouse, imagine splitting the screen with a X, so the top ...
0
votes
1answer
150 views

Points around a circumference C#

Im trying to get a list of vectors that go around a circle, but i keep getting the circle to go around several times. I want one circel and the dots to be placed along its circumference. I want the ...
2
votes
1answer
816 views

Raycasting “fisheye effect” question

Continuing my exploration of raycasting, I am very confused about how the correction of the fisheye effect works. Looking at the screenshot below from the tutorial at permadi.com, the way I ...
3
votes
1answer
709 views

Spherical to Cartesian Coordinates

Well I'm reading the Frank's Luna DirectX10 book and, while I'm trying to understand the first demo, I found something that's not very clear at least for me. In the updateScene method, when I press A, ...
5
votes
2answers
2k views

How to rotate camera centered around the camera's position?

Currently I am using gluLook at like so: gluLookAt(position.x, position.y, position.z, viewPoint.x, viewPoint.y, viewPoint.z, upVector.x, upVector.y, upVector.z); with the ...
6
votes
3answers
2k views

How do I make an entity move in a direction?

I have an Entity instance which is updated every game tick. Let's just assume that entity moves forward constantly. I'd like to be able to give the entity's angle to a function that makes it move in ...
0
votes
1answer
989 views

Calculate the angle between two 3d vectors: Function always returns 89.1-89.9

I have my own 2d game and I am attempting to calculate the angle between 2 GameObjects. My Problem: My function that is meant to calculate the angle(direction) between 2 Vector3's doesn't appear to ...
0
votes
3answers
647 views

Game Institute Math Courses

I'm 21 years old and I suck at math, I mean really bad. I don't have the necessary logic to apply it towards programming. I would like to learn the math and logic of applying it. I found Game ...
0
votes
0answers
136 views

What is the connection between an isometric angle and scale

I am trying to work out an isometric projection matrix for a custom angle. In the engine I'm using there's a projection matrix defined like so: projection.rotate(45 * (Math.PI / 180) ); scale = ...
0
votes
1answer
184 views

Minimap Around Perimeter of Screen, Code Provided

What I'm essentially trying to do is what a lot of FPS's nowadays do in regards to their HUD. When an objective is off-screen, a small icon / symbol is shown on the perimeter of the screen, basically ...
11
votes
1answer
1k views

How can I draw an arrow at the edge of the screen pointing to an object that is off screen?

I am wishing to do what is described in this topic: http://www.allegro.cc/forums/print-thread/283220 I have attempted a variety of the methods mentioned here. First I tried to use the method ...
2
votes
4answers
2k views

How to detect if object is moving in clockwise- or counterclockwise direction?

I've read this one, but I need more info: rotating an object from sourceAngle to destAngle, both 0-359, clockwise or counter clockwise? I have a ball. The user is able to drag the ball in any ...