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

51
votes
7answers
6k views

Can I prevent diagonal movement from exploring more of the map?

In a tile-grid where movement in any of 8 directions takes exactly the same amount of turns (chess-board style rules), can I prevent diagonal movement from showing more new tiles than orthogonal ...
42
votes
5answers
2k views

Looking for a good technique for character movement in hack&slash game

I'm making hack&slash game and I want my characters move like for example in Torchlight, Diablo, etc. Currently I generate set of nodes for all walkable areas of a floor. When I click somewhere ...
24
votes
6answers
3k views

Who does the AI calculations in an MMO?

I am building an MMO and want to add NPCs. The thing is I don't know the basic design. What does the calculations, the clients or the server? I would understand the server calculating events and ...
22
votes
4answers
4k views

Top Down RPG Movement w/ Correction?

I would hope that we have all played Zelda: A Link to the Past, please correct me if I'm wrong, but I want to emulate that kind of 2D, top-down character movement with a touch of correction. It has ...
17
votes
2answers
1k views

Eight or infinity sign trajectory

When I want to move object around point I do: point.x *= cosf(timer.timeElapsed); point.y *= sinf(timer.timeElapsed); How to make point move on eight or infinity sign trajectory?
17
votes
3answers
4k views

How does client-side prediction work?

I've read Valve + Gafferon and hundreds of pages from Google, but for whatever reason I can't get my head around client prediction. To my understanding, the basic problem is: Client A sends input ...
16
votes
2answers
2k views

RTS Game Protocol

I've been thinking about a multi player RTS game. The part that I can't seem to get around is keeping unit movement synced. If I move unit A to spot XY, I have to communicate that back to server that ...
16
votes
6answers
1k views

AI control for a ship with physics model

I am looking for ideas how to implement following in 2D space. Unfortunately I don't know much about AI/path finding/autonomous control yet. Let's say this ship can move freely but it has mass and ...
14
votes
3answers
3k views

How to avoid movement speed stacking when multiple keys are pressed?

I've started a new game which requires no mouse, thus leaving the movement up to the keyboard. I have tried to incorporate 8 directions; up, left, right, up-right and so on. However when I press more ...
14
votes
3answers
751 views

AI to move custom-shaped spaceships (shape affecting movement behaviour)

I'm designing a networked turn based 3D-6DOF space fleet combat strategy game which relies heavily on ship customization. Let me explain the game a bit, since you need to know a bit about it to set ...
13
votes
6answers
2k views

How to build a “traffic AI”?

A project I am working on right now features a lot of "traffic" in the sense of cars moving along roads, aircraft moving aroun an apron etc. As of now the available paths are precalculated, so nodes ...
13
votes
3answers
452 views

Technique for objects following each other in complete movement?

I'm wondering how objects follow each other where they move over the previous position of the object in front of them. When the leading object stops, all that are following should stop at their ...
12
votes
4answers
4k views

Curved movement between two points

What is a good technique to enable an object to move between to points in a nice curved motion? The end position could also be in motion, such as the trajectory of a homing missile.
12
votes
3answers
1k views

How can I make “falling away” 3D terrain like Animal Crossing?

Animal Crossing has a unique way of scrolling the world map: When the character moves down, the the world rolls around and over at the top, like it's stuck to a cardboard tube: This video shows how ...
11
votes
1answer
349 views

Are there any pathfinding algorithms that would handle different movement types?

I'm developing a bot for a BattleTech board game simulator http://en.wikipedia.org/wiki/BattleTech, it is turn based. The board is divided into hexagons, each one has a different terrain type and ...
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. ...
10
votes
4answers
803 views

Player moving up, is he jumping or climbing?

In a 2D physics-based platformer game that has ladders in it, how do you determine whether the player moving up is caused by a jump or him climbing a ladder, such that you know what animation to play? ...
10
votes
2answers
601 views

How to limit click'n'drag movement to an area?

I apologize for the somewhat generic title. I'm really don't have much clue about how to accomplish what I'm trying to do, which is making it harder even to research a possible solution. I'm trying ...
10
votes
4answers
423 views

Where will my character stop?

Many years ago I coded some AI for a budget pseudo-3d game. There was one calculation which I never really figured out the best way to do, and that was calculating where the enemy would end up if it ...
9
votes
2answers
4k views

Enemy movement in straight line to player in chase game

I'm creating a game where the enemies spawn randomly on a map then move towards the player every frame at a random speed. The map has no obstacles so the enemies should always move in a straight line. ...
9
votes
2answers
1k views

How can I make a character walk on uneven walls in a 2D platformer?

I want to have a playable character who can "walk" on an organic surface at any angle, including sideways and upside-down. By "organic" levels with slanted and curved features instead of straight ...
9
votes
2answers
388 views

How to handle entity path-finding and movement in a large networked world?

Considering the image above with tiles split into 32x32 boxes, I have an entity which is marked to 'aggro' nearby players that come close to it. I'd like this monster to ideally chase the player (and ...
9
votes
2answers
220 views

Interpolating between two networked states?

I have many entities on the client side that are simulated (their velocities are added to their positions on a per frame basis) and I let them dead reckon themselves. They send updates about where ...
9
votes
2answers
3k views

How do I tackle top down RPG movement?

I have a game that I am writing in Java. It is a top down RPG and I am trying to handle movement in the world. The world is largely procedural and I am having a difficult time tackling how to handle ...
8
votes
3answers
2k views

How are game characters animated? [closed]

I will be working with my friends on our final year project. Our game will be FPS and I have to draw some animations for FPS view and other enemy character that can be programmed easily to make a good ...
8
votes
2answers
14k views

Moving a sprite in XNA/C#, using vectors

I'm currently looking into XNA game development with the C# language. I have two classes: the main game handler and a "sprite" class. Following is some basic pseudo-code which I hope adequately ...
8
votes
2answers
887 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 ...
8
votes
5answers
1k views

returning correct multiTouch id

I've spent countless hours on reading tutorials and looking at every question related to multiTouch from here and Stackoverflow. But I just cannot figure out how to do this correctly. I use a loop to ...
8
votes
1answer
409 views

Is there anything equivalent to Portal 2's linked_portal_door in any other engines?

I need the functionality of the linked_portal_door that's in Portal 2. I've searched a little in UDK and mostly got people trying to duplicate the portal gun. Does anyone know if UDK, CryEngine, ...
8
votes
4answers
822 views

Moving objects colliding when using unalligned collision avoidance (steering)

I'm having trouble with unaligned collision avoidance for what I think is a rare case. I have set two objects to move towards each other but with a slight offset, so one of the objects is moving ...
7
votes
2answers
4k views

Free movement in a tile-based isometric game

Is there a reasonable easy way to implement free movement in a tile-based isometric game? Meaning that the player wouldn't just instantly jump from one tile to another or not be "snapped" to the grid ...
7
votes
2answers
440 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 ...
6
votes
4answers
1k views

Equation for bouncing graph?

I basically want my camera in 3D move automatically. Currently, I have linear movement which is rather dumb, so I'd like to do a bouncing movement. However, what is a good equation for bouncing? I ...
6
votes
2answers
445 views

Simulate movement towards the screen in a 2D world

I need to create the illusion of someone kicking a ball to the screen. For that, I have a initial position of the ball (about the middle of the screen), and I put the sprite of the ball scaled at 0.2 ...
6
votes
2answers
546 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 ...
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 ...
6
votes
1answer
431 views

What is the best way to limit player movement?

I'm currently programming a 2d game where the player moves around on a rectangular playing field. The player has a direction and a velocity. What is the best way to limit the player's movement so ...
6
votes
1answer
287 views

Swaying Camera when Walking

You can see the effect in many games. The camera sways or wiggles a bit while walking to make the movement feel more realistic. I have implemented a camera in my game. (Who'd have thunk it?) So is ...
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 ...
6
votes
2answers
2k views

How to manage enemy movement and shoot in a shmup?

I'm wondering what is the best (or at least a good) way of managing enemies in a shoot-em-up. Basically, what I'd do would be a class that manages displaying and updating positions of all the ...
6
votes
1answer
376 views

Implementing David Silver's Cooperative Pathfinding in Real-Time

I'm currently implementing David Silver's Cooperative Pathfinding algorithm for a 2D game with grid-based movement (all eight directions). The issue I'm having trouble wrapping my mind around is the ...
6
votes
4answers
439 views

Implementing AI to hide behind obstacles

I am developing an AI simulation of predator and prey. I would like to simulate the AI hiding behind obstacles, if it is being chased. But I am still trying to figure out the best way to implement ...
6
votes
2answers
5k views

How do I make my character slide down high-angled slopes?

I am currently working on my character's movement in Unity3D. I managed to make him move relatively to the mouse cursor. I set a slope limit of 45°, which does not allow the character to walk up the ...
5
votes
2answers
1k views

Is it safe to set FPS rate to a constant?

I learned from game class that in update function, every movements must be time dependent for the sake of linearity in movement. We made a simple game. Every move like going left, right or jump is ...
5
votes
5answers
1k views

How do I implement deceleration for the player character?

Using delta time with addition and subtraction is easy. player.speed += 100 * dt However, multiplication and division complicate things a bit. For example, let's say I want the player to double his ...
5
votes
3answers
4k views

Moving from A(x,y) to B(x1,y1) with constant speed?

I currently have something like: float deltaX = point0.getX() - point1.getX(); float deltaY = point0.getY() - point1.getY(); And every 0.01 seconds I refresh my objects position like this: ...
5
votes
2answers
2k views

I am looking to create realistic car movement using vectors

I have goggled how to do this and found this http://www.helixsoft.nl/articles/circle/sincos.htm I have had a go at it but most of the functions that were showed didn't work I just got errors because ...
5
votes
3answers
624 views

Why is this code producing jittery movement?

I have a new project, all settings default with a simple cube on a plane. Cube is not kinematic but is a rigid body under the effects of gravity. I'm trying to normalize the direction before I ...
5
votes
2answers
3k views

Oscillating Sprite Movement in XNA

I'm working on a 2d game and am looking to make a sprite move horizontally across the screen in XNA while oscillating vertically (basically I want the movement to look like a sin wave). Currently for ...
5
votes
1answer
584 views

How can I implement view wobble when my player is running?

I'm creating a FPS in XNA. So far its' going great. What I'm looking at doing is replicating the camera movements that you see in Modern Warfare. So, if you are walking the camera stays pretty ...