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

1
vote
2answers
321 views

Show a range grid movement as3

How do I show range of grid movement in AS3? When player controls a character and chooses "move" options, the grid of movement will be displayed as 3 grid of X, 4 grid of Y (Both sides, + and -). So, ...
1
vote
1answer
30 views

Doubts on player movement strategy

What I want to achieve is the player moving to the touched position on a 2D grid-based game, stopping at the last reachable spot if the target position is unreachable. What is the strategy usually ...
1
vote
3answers
197 views

How do I correctly make character sprite direction match player inputs?

In my top down game I can move the character around and the character will even face the direction he is moving. However, there is some weird behavior I'm having: when you hold down one direction and ...
0
votes
3answers
832 views

How would I go about making a movement system like Mario Party?

Main question How would I go about getting a movement system similar to the one they have in Mario Party only minus the dice roll? Things I have researched I have been studying the uses for ...
3
votes
2answers
90 views

Unintentional slight arm position change

In the scene I have a capsule with a camera parented and a looking script so when I look down or up the weapon slightly moves forward and then moves back when I look straight forward. weapon when I ...
1
vote
2answers
145 views

Determine facing direction mecanim 2d movement

I'm using this script to move my character in my 2d world: public float speed; //Movementspeed public Rigidbody2D rbody; Animator anim; void Start () { rbody = ...
0
votes
3answers
55 views

How do I flip Player in 2D Touch Movement?

How do i flip my Player in 2D when i got touch movement? I got Buttons to move but how do I flip the player now if i walk to the right cause my player faces to the left..? here is my Player Script: ...
0
votes
1answer
2k views

Unity-Animation parameters are not being set

I have the following animation controller: with two parameters of walkingSpeed and Jump. I have the following code which should change the values: animator.SetFloat("walkingSpeed",0.9f); ...
1
vote
2answers
41 views

Bike game - following a road path

I am writing a game in java which has a bike riding down a road. I intend to add some obstacles on the road which are structures having a slope, which the biker must negotiate. In other words, the ...
1
vote
1answer
53 views

Correct order of entity updates and collision detection

I'm trying to simulate a number of units walking in a single file. My update loop looks like this: for each unit: n = compute next position if n is empty then move to n If I start the loop ...
2
votes
1answer
238 views

Handling touch input with Event Trigger

I wrote a simple script to control my 'Player' object: using UnityEngine; using System.Collections; public class PlayerMovement : MonoBehaviour { public float jumpVelocity = 10; ...
8
votes
3answers
441 views

Guided Missile with Constant Time

I'm building a game with players and missiles. I want to fire a missile from P1 to P2. The missile should always take exactly five seconds to reach P2. The missile should also track P2. If P2 moves ...
3
votes
1answer
357 views

Controlling roll rotation when travelling along bezier curves

I am currently working on a curve implementation for use in Unity which includes an editor: The aim is to get an object to follow the path represented by the curve at a constant velocity. Currently ...
0
votes
3answers
384 views

How do I make sure the player model only moves 1 unit?

I am doing a school assignment based off of the Unity3D tutorial 2D RogueLike (all code available here) In my version though, the movement is not turnbased and I am having some trouble figuring it ...
1
vote
1answer
125 views

Unity 2D Diablo style movement

I've made a totally new scene for a 2D mobile game. I placed a sprite on the center of the screen and attached the following script onto it (this is basically a diablo-style click-to-move control ...
2
votes
1answer
2k views

How to move an UIView along a curved CGPath according to user dragging the view

I'm trying to build a interface that the user can move his finger around the screen an a list of images moves along a path. The idea is that the images center nevers leaves de path. Most of the ...
0
votes
2answers
105 views

Smooth movement from point A to point B in a tile-based game

I'm currently very new to XNA, and I'm trying to get a grasp on movement. Currently, I have a function that checks for keypresses, and moves my character from point A to point B instantly: private ...
3
votes
1answer
133 views

How do I get A.I. that follows a list of movement commands to move smoothly in a tilemap based game?

This is for a school project so it's not intended to be sold/fun/or a complete game, rather just a demonstration of stuff we've learned without resorting to frameworks and stuff. My ai agents choose ...
2
votes
1answer
87 views

2D Change Velocity Based on Distance XY While Moving Parabolic Arc

What I'm trying to achieve is that the entity moves in a parabolic curve, and no this has nothing to do with gravity before you ask. I give the entity a target position which it should move to, but ...
1
vote
1answer
138 views

Unity 5.2 default 3rd person controller makes character fly upwards when moving forward

I'm new to Unity and already dealing with a problem.. using the default third person controller script I am trying to move and animate player. But I have a problem that as I try to move the character ...
1
vote
1answer
30 views

Circular Movement

if (Keyboard.isKeyDown(Keyboard.KEY_D)) { if (i < 360) { setX((float) (groundState.getX() + groundState.getRadius() * Math.cos(Clock.delta() * i))); setY((float) ...
1
vote
1answer
528 views

How to move rigidbody player to its facing direction with AddForce?

How can I move a rigidbody to its facing direction? I've already tried this: rigidbody.AddForce (transform.forward * v, ForceMode.Acceleration); // v is a public float which gets a new value in ...
1
vote
1answer
56 views

libgdx - Texture not appearing sometimes

When I run the App the Ball moves sometimes downwards, but sometimes its not moving. I dont change anything on script. What I want is the ball should come from top outside of the screen, but when its ...
0
votes
1answer
149 views

Continuous Jumping Cycle

The script makes a GameObject jump using realistic gravity and reach a specific target. The GameObject jumps relative to the target, thus adjusting its trajectory. It also works while the target point ...
0
votes
1answer
61 views

Moving a character to a point without any floating point operations

So I'm writing an adventure game for MSDOS, just a fun challenge for me. I'm trying to get the character to walk along a straight line to his destination (either the next navMesh node or where you ...
2
votes
2answers
146 views

How do you avoid lag with Three.js and mousemove?

I'm trying to create a browser moba-like game using three.js. I'm using WASD for movement and the player rotation follows the mouse with mousemove then lookAt() the intersection. The problem: As I ...
3
votes
2answers
113 views

How can I make the ball in pong move even if no event is taking place in Allegro5?

I've been trying to make a pong game with C++ and allegro5, I found moving the ball around easy with SFML, but in allegro5 I don't know what I can do to move it around, right now, it moves but only ...
0
votes
3answers
124 views

Move Camera When Player Move C#

i developing side Scrolling endless Game. i want to Change X Axis of camera as player moving to Right. and i almost Done That. but the problem is when move Camera to the Right then its look so stiff ...
0
votes
1answer
36 views

Libgdx: move img from one point to another?

I'm trying to make an image move towards another point. I only have the current X/Y and the destination X/Y + Speed. That's it. public void Draw(SpriteBatch batch, int goalX, int goalY){ destX = ...
0
votes
0answers
43 views

How to fix my issue with movement?

I am making a 2D tile game in Java, and I am having problems with movement, could someone tell me what I am doing wrong please? I am having difficulty in "calling" the function vectorFromKey in main. ...
0
votes
2answers
27 views

Getting input from just one Axis at a time

I'm trying to make a CharacterController2D Script for a simple 2D TopDown game, but i was wondering, what would be the best way to disable 2-axis movement? just allowing one direction at a time (Maybe ...
0
votes
0answers
12 views

If I attach a RunAnimation to my Player and move it, the Camera starts to freak

If I make a RunAnimation for my Player in 2D, then there is one Spot it works and I can move perfectly but if I move my Player to a different position,my Player stucks in Midair and my Camera starts ...
3
votes
1answer
605 views

Scaling sprite velocity / co-ordinates in Android

I'm trying to find the answer to a question that I've had for a long time, but am having trouble finding it! I hope someone can help :-) I'm trying to find information on how to scale sprite velocity ...
0
votes
1answer
47 views

Moving script not working after SetActive/Pause change

I have a pause menu for my game which instantiates a texture and sets a text frame to active and slides both objects onto the screen using the code below: Instantiating the menu texture and ...
1
vote
3answers
57 views

What is easiest way to move towards and along the edge on a hex grid?

I have a hexagonal grid with variable radius. My entity can move exacly 2 hexes per turn. How should I calculate next step towards border and afterwards travelling clockwise around map? Preferred ...
0
votes
0answers
23 views

Preventing a NavMesh agent from moving Diagonally?

I'm currently working on a topdown game that uses 3D models. I am planning on using the NavMesh system in Unity to handle the movement of my NPCs, however, the NavMesh agents move diagonally when ...
0
votes
0answers
42 views

LibGDX - Player Movement Flickers

So, I was programming a very simple LibGDX game, so I decided to include a player class into the program. Once I did that, the players image started to flicker/stutter while I moved it. Here's the ...
0
votes
1answer
69 views

How to make my character double jump in unity3d using CharacterController?

I can now control my character in air, I used Unity's CharacterController.Move docs, but now I need to make my character double jump. Here's the code. public class PlayerMovement : MonoBehaviour { ...
0
votes
0answers
16 views

Move car with script [duplicate]

How would I go about writing a car script in C#. Is there anything special I would need to code. Or is it simply if pressed certain button, Rigidbody.AddForce() or transform.Translate(). My question ...
0
votes
0answers
39 views

Adding a 2d collider causes incremented movement of a child, how to fix it?

I have 2d game, with a parent object with two sprite children, a man moving up and down with a flamethrower. Currently having only the movement script and rigidbody, I can move the parent easily with ...
4
votes
1answer
183 views

Creating a Roguelike game in C

I'm trying to create a simple rogue-like game in ncurses in a C program. The idea here is that, I'd parse a file like this: 10X10 ds2 de2 dw5 12X12 ds3 de2 dw1 14X14 ds5 de1 dw5 10X10 ds5 de3 dw5 ...
13
votes
2answers
2k views

Movement appears to be frame rate dependent, despite use of Time.deltaTime

I have the following code to calculate the translation required to move a game object in Unity, which is called in LateUpdate. From what I understand, my use of Time.deltaTime should make the final ...
0
votes
0answers
18 views

JavaScript — Unity Movement Bug

Hello fellow programmers ! I have been working on a game lately and It's going pretty good. Today I decided to make a new car for it since it's a racing game. When I was modelling the car I ...
0
votes
0answers
51 views

How to make this 2D jumping animation smooth in XNA?

I am currently developing a game where I have a sprite that its objective is to jump over boxes coming at it. I know that you have to change the Y values. When spacebar is hit, it goes up but then I ...
0
votes
0answers
41 views

storing hexagon-based (x/y) movements in a database

Im developing a hex(agon)-grid based game. The game is turn-based. Players move stuff on the map and they need to be allowed to issue movement-orders. Units move a certain amount of movement-points ...
0
votes
0answers
30 views

What can I do to improve my movement?

I'm starting with my first prototype, I can move my player and jump, but it doesn't feel very good indeed. I've made a gif to show it. This is my script: using System.Collections; public class ...
0
votes
1answer
32 views

Character doesn't move. I think I've tried everything, so I'm asking [Unity3D]

The animations are playing fine, however I can't manage to move my character. My script: using UnityEngine; using System.Collections; public class PlayerMovement : MonoBehaviour { public float ...
1
vote
3answers
143 views

Getting sprites to move exactly the same on different devices

Background When moving a sprite along the X axis, this is my code: spriteXReal = spriteXReal + (spriteXVel * dt); //.5 would be halfway point of, 1 would be right hand side screen etc... ...
1
vote
1answer
476 views

Multiplying by delta not giving smooth movement

I started working on my first proper game but reached a problem straight away. In short I have a game that runs most of the time at 60 fps. ( I am using Libgdx a popular Java framework) but my game ...
0
votes
1answer
108 views

Libgdx Delta time stutter?

Alright, so I want my guy to move, I simply use this code. velocity.y = speed; Same goes for velocity.x Thing is, the lower the framerate the slower he moves. But, if I add delta time, the player ...