A simple term for "translation", the change of position of an entity typically on the route of going from point A to point B.
10
votes
1answer
200 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 ...
0
votes
1answer
94 views
Java: Basic Movement AI not working
I am working on a basic AI system to get an entity to follow a player. I created both the player and the ghost entity, but it seems as if the ghost only wants to increment both x and y, it never wants ...
-1
votes
0answers
40 views
OpenGL Camera with jBullet Physics
I am using jBullet with OpenGL to create a basic game engine. I created two classes named ObjectSurface and ObjectEntity. Basically ObjectSurface's have no mass so they don't move and ObjectEntity's ...
4
votes
3answers
160 views
Determining the end location for AI movement in groups in a 2D RTS
I have written an RTS game (a demo for a game engine of sorts, actually) in which the user's basic interaction with the game is to select a bunch of soldiers and then right-click on the map to move ...
0
votes
2answers
109 views
How to avoid character to move when selected
I've got a player Class which can walk to a certain point on the screen when left mouse is pressed:
if (mState.LeftButton == ButtonState.Released && oldMouseState.LeftButton == ...
5
votes
1answer
93 views
Walking on a sphere
I'm working on a game which involves walking your character on the surface of a sphere. Using the answer to Arbitrary Rotation about a Sphere, I've written my code as:
if (game.isKeyDown(37)) { // ...
3
votes
1answer
97 views
Precalculate the position of a rotating Aircraft
To start honestly, this question is probably mostly handling math. But thats only the road I tried to go and failed miserably, so maybe theres a much more simple way to do.
Ok the game situation is ...
3
votes
1answer
117 views
Implementing smooth 8 directional movement
I have my units that i move around my map with path finding. The units can move in 8 directions, currently i have the units moving around the map with a extremely basic check against the unit's ...
-3
votes
1answer
86 views
Undefined fireball movement behavior
Demonstration video
I try to do after the player shoot 10 times of fireball, then delete all the fireball objects and recreate a 10 new set of fireball objects. I did it but there is a weird bug ...
3
votes
3answers
138 views
Effective way to check if an Entity/Player enters a region/trigger
I was wondering how multiplayer games detect if you enter a special region. Let's assume there is a huge map that is so big that simply checking it would become a huge performance issue.
I've seen ...
1
vote
0answers
41 views
Finetuning movement based on gradual rotation towards a target [duplicate]
I have an object which moves towards a target destination by gradually adjusting its facing while moving forwards. If the target destination is in a "blind spot", then the object is incapable of ...
2
votes
2answers
91 views
Finding the shorter turning direction towards a target
I'm trying to implement a type of movement where the object gradually faces the target. The problem I've run into is figuring out which turning direction is faster. The following code works until the ...
0
votes
1answer
245 views
Character movement on a 2D tile map
I'm working at making a HTML5 game. Top down, closest thing I can equate it to is the gameboy zeldas, but open world and no rooms.
What I have so far is a procedurally generated map in a multi ...
4
votes
1answer
113 views
Time critical events based on framerate
Problem Description
Basically, I've made a "programming game" in which I've made my own scripting language. It is a completely standard Lunar Lander game, though instead of directly controlling the ...
0
votes
1answer
216 views
Player can move off screen?
So this is something that I've struggled with for a while.
I have this code to check if the player is off the screen (Which at the moment is the map)
if (newX < 0) {
newX = 0;
}
if (newY ...
0
votes
0answers
37 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 ...
1
vote
2answers
88 views
XNA Using velocity
Previously when making games I have just been using a Vector2 as the sprites position and altering that for movement, i.e.:
if(right key pressed)
Position.X += movementspeed * gametime...;
...
0
votes
1answer
46 views
SDL - BlitSurfaced Background Slowing Time Based Movement
Whenever I use BlitSurface to apply a background image, the movement of my characters is slowed drastically even though I have movement based on time:
SDL_BlitSurface( background, camera, screen, ...
0
votes
1answer
49 views
Rotating sprites
I'm a beginner at making games, i'm currently only working in 2D using XNA.
So far all of my games i've been using the following logic for sprite movement:
if(left key pressed)
sprite_x_position ...
1
vote
1answer
85 views
Android Action_Move when moving between specific screen areas
OK so I know how to iterate through the different pointers that are currently touching the screen so I know what the coordinates are of these pointers using the following:
Code snippet
case ...
1
vote
2answers
98 views
Correct way/How to think to plan out “control/animation flow”?
So basically, a problem I've had in past attempt at making games (little playing around with stuff): how to do a correct, non-sloppy way of planning the flow of animations/control?
Let's take an ...
0
votes
1answer
152 views
Android cocos2d getting a sprite to continuously move to a dynamic position
I tried using the MoveTo method in cocos2d to get a sprite to continuously follow my player sprite:
CCMoveTo actionMove = CCMoveTo.action(actualDuration, player.getPosition());
CCSequence actions = ...
-1
votes
2answers
166 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
75 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
3answers
206 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();
...
5
votes
2answers
404 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 ...
0
votes
1answer
230 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 ...
-1
votes
1answer
105 views
XNA - 2D Rotation of an object to a selected direction
I'm trying to figure out the best way of rotating an object towards the directional input of the user. I'm attempting to mimic making turns on ice skates.
For instance, if the player is moving right ...
1
vote
1answer
106 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 ...
0
votes
2answers
176 views
Displaying possible movement tiles
What's the fastest way to highlight all possible movement tiles for a player on a square grid? Players can only move up, down, left, right. Tiles can cost more than one movement, multiple levels are ...
5
votes
2answers
306 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 ...
3
votes
1answer
626 views
How do I implement movement in a WPF Adventure game?
I'm working on making a short WPF adventure game. The only major hurdle I have right now is how to animate objects on the screen correctly. I've experimented with DoubleAnimation and ...
3
votes
0answers
112 views
Simple movement restrictions to semi-realistically model human movement in top down 2D game?
I am writing a sports simulation game in which the simulated players will interact physically with each other (i.e. tackle, push, bump...) as well as do individual actions such as changing direction ...
0
votes
2answers
157 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 ...
11
votes
1answer
541 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. ...
0
votes
1answer
188 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 ...
3
votes
2answers
517 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
266 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
236 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 ...
2
votes
2answers
127 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 ...
3
votes
1answer
145 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 ...
2
votes
2answers
354 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 ...
-1
votes
2answers
309 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
153 views
How can i use triangle picking to determine the exact location of a triangle in world space coordinates?
Im trying to implement point and click movement in my game, but at the moment im stumped about how i can select parts of a mesh for the player to walk to.
So what ive done is ive got a navigational ...
2
votes
1answer
130 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
1answer
132 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 ...
0
votes
2answers
100 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 ...
0
votes
2answers
191 views
Increasing speed of circle over time as linear with Box2d
Assume that there is a circle and it can be moved by using keyboard arrows.Is required that increasing speed over time like increasing car speed. For example; max speed is 25 and time to reach max ...
0
votes
2answers
157 views
joystick movement for Geometry Wars clone
I am kinda new in game programming, but I've got a semestral work to make a game, so I decided to do a clone of Geometry Wars. Despite that the game is really simple (in principle), I have ran into a ...
-1
votes
1answer
175 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 ...