A simple term for "translation", the change of position of an entity typically on the route of going from point A to point B.

learn more… | top users | synonyms

2
votes
4answers
4k views

box2d and constant movement

i'm developing a game with a top down view, the players body is a circle. To move the character you need to tap on the screen and it moves to the spot. To achieve this i'm saving the coordinate of ...
-1
votes
2answers
1k views

Move object to position using velocity [duplicate]

I'm trying to make a simple object move to a desired location using its velocity. But I'm having trouble with it over shooting its target. I have to use velocity, I can't simply lerp the position, ...
3
votes
1answer
124 views

How to create a path-finding compatible road map from user input?

I'm currently working on an agent simulation (inspired by the recent SimCity release). Now, basically I understood how agents work but I do not understand how to put them into context. Agents travel ...
0
votes
1answer
441 views

Pokémon character turning / facing: How is it achieved? Movement is already done though [closed]

You know that when the player playing Pokémon games want to change the facing of the main character, one would simply tap on the directional pad (D-pad) on the Game Boy (Color/Advanced/Advanced SP) or ...
0
votes
3answers
573 views

How do I move a sprite to the mouse position?

So, I'm trying to make my sprite walk to the X-coordinate of my mouse click. This is my code: currentMouseState = Mouse.GetState(); MouseState mouseState = Mouse.GetState(); ...
6
votes
2answers
517 views

How do I keep my character centred on screen?

I am making a game similar to Legend of Zelda: Link to the Past (top-down 2D action-adventure). I want the character to stay centred on the screen when he moves. Currently, whenever the player wants ...
1
vote
1answer
165 views

How to implement deceleration and stopping over a certain distance [duplicate]

So I have a a character, say a spaceship. It needs to move distance R, and in direction T (Theta). So say if The object is at (0,0), and it needs to get to (4,3), it has R = 5 and T = about 36 ...
3
votes
4answers
3k views

Multiple Key Presses in XNA?

I'm actually trying to do something fairly simple. I cannot get multiple key presses to work in XNA. I've tried the following pieces of code. else if (keyboardState.IsKeyDown(Keys.Down) && ...
3
votes
6answers
2k views

How to implement object velocity as a vector

I'm working on a Breakout game, and want to change the ball's movement code from how I currently do it, to something based on vectors (as I feel learning and implementing movement based on vectors ...
5
votes
2answers
520 views

How to combine tap and long hold gesture recognizers?

I have a game in which the player moves around a sprite by tapping on various sections of the screen (left, right, up, down). So far, each tap moves the sprite one tile (I use a tile system for ...
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 ...
4
votes
1answer
533 views

Collision Detection with SAT: False Collision for Diagonal Movement Towards Vertical Tile-Walls?

I'm developing my first tile-based 2D-game with Javascript. To learn the basics, I decided to write my own "game engine". I have successfully implemented collision detection using the separating axis ...
11
votes
1answer
1k views

Pathfinding on a uneven planetary surface

My question is what would be the best approach to pathfinding on an uneven planetary surface? Background Information I have created a planet from displacement mapping 6 sphere projected planes. ...
2
votes
2answers
195 views

Smoother controls

I am trying to move my background left if the user hits the right key. and right if the user hits the left key, so that it will look like the player is moving. The problem is that whenever I hold the ...
0
votes
1answer
362 views

Pong horizontal movement algorithm

I was just wondering about the horizontal movement of a pong ball? What is the general algorithm used with this? The ball in my pong game just move vertically and I don't know about the algorithms ...
4
votes
2answers
2k views

How to achieve smooth movement with a fixed timestep

Previously in the update method of my game I was using a variable time step which provided very smooth movement of a player sprite except when the frame rate would drop, even slightly. At that point I ...
2
votes
1answer
502 views

2D Top down acceleration vector

I have been wanting to solve the issue of movement once and for all... with all that I have learnt and read through, should be a piece of cake one would have thought... , seems it isn't. Having ...
0
votes
1answer
795 views

Interpolating a player between two 2D points?

I would like a player to be able to move in a direction smoothly, whilst sticking to a fixed grid. Much like in Pokemon, how the player can move, but when the key is pressed and released quickly, they ...
6
votes
2answers
1k views

I want to implement free-running movement (like Assassin's Creed) in 2D. What to do?

I would like to implement free-running as popularized by Assassin's Creed, albeit in 2D. What are some specific techniques or algorithms that I can use to achieve free-running in 2D without having to ...
2
votes
1answer
228 views

Movement on the X an Z axis are combined?

This is probably a stupid question, but I'm trying to simply move a 3D object up, down, left, and right (Not forward or backward). The Y axis works fine, but when I increment the object's X position, ...
2
votes
2answers
976 views

Implementing tile-based movement on 2D platformer

I'm trying to make a cinematic platformer, in the veins of the first two Oddworld games, Flashback, Prince of Persia, Blackthorne and so on. This article describes very well how this kind of movement ...
3
votes
1answer
184 views

Theory behind worm like movement?

I don't want code or anything that will make this too easy for me, but I'm just starting the development of a little game and I want to add worms to it, I want the worms to be Terraria like. My ...
1
vote
1answer
535 views

What algorithms can I use for bullet movement toward the enemy?

I'm developing 2D strategy game. There are weapons that shoot at enemies. From what I've read in this, this, this and this post I think that I need linear algebra, but I don't really understand what ...
-1
votes
2answers
1k views

Moving a sprite towards an x and y coordinate

Given a sprite with an x and y coordinate, how would I move it toward another sprite with an x and y coordinate? I've already made it face towards the other sprite, and I've made it move towards the ...
1
vote
2answers
479 views

Comparing a saved movement with other movement with Kinect

I need to develop an application where a user (physiotherapist) will perform a movement in front of the Kinect, I'll write the data for the movement in the database and then the patient will try to ...
0
votes
1answer
173 views

Character movement relative to cursor position

I want my top-down shooter character to move towards the mouse when pressing the up arrow and strafe relative at right angles to it when pressing the left and right arrow keys. I can't figure out how ...
2
votes
1answer
316 views

Translating a terrains position using input in Unity 3D C#

I am trying to make a terrain in Unity move, but im having trouble. Here's the code i have. using UnityEngine; using System.Collections; public class NewScript : MonoBehaviour { Camera camera; ...
0
votes
2answers
152 views

Grouped enemy movement out of sync after changing directions [closed]

Im working on a Galaxian/Space Invaders Inspired game. Im working on the enemy movement and am running into an issue where the enemies get out of sync when changing direction. My setup is that I ...
-1
votes
1answer
272 views

3D Character Development [closed]

First and for most. I do have a fair amount of experience programming. I have experience with many programming languages and I have taken a few courses in computer science. I have development some ...
1
vote
1answer
113 views

Movement constrained to the faces of a cube

The basic setup I'm working with is a cube rendered in-Engine (Panda3d, although I only am looking for a generalized solution) as well as a 2d square on one face of the cube. The eventual outcome I'm ...
0
votes
2answers
290 views

Using timer to reverse enemy movement in Flash game made with Flixel

I am creating a 2d flash game using Flixel 2.5 in Flash Builder. I am trying to reverse enemy movement on an interval so that they will move back and forth over a set space. I felt that a timer would ...
5
votes
2answers
263 views

How can I normalize a vector if I am handling movment of each axis seperatley?

I am writing a 2D tile based game engine in XNA, and I've recently fine-tuned my collision detection using the answers provided here and more specifically here. The tile based collision detection now ...
1
vote
2answers
89 views

Scene - human speed correlation

I am writing a really simple game with a scene (horizontal plane) and a human moving to the right of the plane (watching the simulation from the +z axis). The scene contains some trees, which I am ...
5
votes
1answer
467 views

Character Movement in 3D games

I'm either not searching correctly or there is really not a lot of material on Character Movement in 3D games. I'm mostly interested in how people usually implement character movement in games like ...
7
votes
2answers
418 views

Movement on a curved planet surface

I'm looking for a solution for moving a variety of objects over the uneven surface of my planet. The idea is that I will have a number of objects that follow the planetary landscape moving about in ...
8
votes
2answers
805 views

Following a path in a smooth fashion

I am currently making a 2d tower defense game with a static, predetermined lane that the enemies follow (i.e. towers cannot block the path and path finding is not the problem I am trying to solve). I ...
1
vote
1answer
385 views

In 2d game logic, should I use pixels or world coordinates?

Currently in my game I handle the logic (collisions, movement) using pixels but I find it very limiting espiecially when thinking about variable speed. For example Box2D requires you to use ...
1
vote
1answer
224 views

C++ Using clock() with IsKeyDown

I am trying to replicate the game Asteroids as a class project. I am having trouble measuring the time elapsed while the "W" key is pressed. This code is supposed to increase the force applied to the ...
4
votes
3answers
2k views

Smooth Sprite Movement - Don't Add Velocity to Position?

I am trying to figure out if there is a way to move a sprite smoothly on the screen at different speeds without stuttering, but keeping the effect that it's moving smoothly; especially at faster ...
1
vote
1answer
127 views

Increase restitution (bounciness) of an object in a JavaScript formula

I'm going slightly around the houses on this one. I originally started a thread over on Stack Overflow about it but then it seemed to diverge into mathematics, with no joy from the SO community over ...
1
vote
2answers
365 views

How can I move an object over a drawn tile map in HTML 5 without constant buffering?

I've been messing around with HTML5 for quite some time now but this is something that I guess I haven't figured out how to handle well yet. I'm sure there's an extremely easy solution and I just ...
1
vote
2answers
321 views

Controlling player and camera movement in a 3rd person game with keyboard and mouse

In many action games with a third person view, joystick controls typically map the left joystick for player movement and the right joystick for camera movement (or more precisely camera's direction ...
0
votes
1answer
159 views

DPad style movement for AI without using A*

What is the easiest way to implement DPad style movement (No diagonal) for AI without using and A* algorithm? I thought about having the enemy catch up to the player in the Y axis first then the X ...
2
votes
2answers
612 views

Making a player move to my mouse when clicked?

How can I get my player to move to the mouse when it is clicked (like in Warcraft)? So far I have tried: if (Mouse.isButtonDown(0)) { if (X < Mouse.getX()) { X += Speed; } if ...
1
vote
2answers
388 views

Moving an object around the the circle to the specific location in circumference

Well I have run out of ideas how to approach this particular problem.See the picture below: So the idea is that the object (dot in black) has to get to a point mark X (red X mark).However the ...
3
votes
3answers
2k views

How do I calculate how an object will move from one point to another?

Here's the problem: A player starts the game in the 0 coordinate (x=0,y=0). When the user clicks on the screen, it returns the coordinates of the destination. Now the player has to move from its ...
3
votes
1answer
189 views

Figuring out which direction my object is facing on a 2D plane?

My friend and I were messing around in XNA 4.0 making a 2D racing game. Kind of like this one: Ivan “Ironman” Stewart’s Super Off Road. The problem we are having is knowing which direction the car is ...
3
votes
1answer
183 views

AI surrounding algorithm suggestions

I am building up a simulation where predator groups (tribes) try to hunt other agents in the simulation (whom also are clustered in groups). Now I got to a point where members of a group follow their ...
1
vote
0answers
505 views

3 Button Multi-touch for Android

OK, my multi-touch system was somewhat convoluted, but was working perfectly OK until I tried to run my game on my Nexus 10 which is running Jellybean. Crashing all over the place! So I removed my ...
0
votes
1answer
286 views

Player movement behind objects

I was playing around on RPG JS and Browser Quest, and the player, when moving, can give the effect of walking behind the trees or houses etc, so the player effectively disappears while it is "behind" ...