Questions tagged [movement]

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

Filter by
Sorted by
Tagged with
0 votes
0 answers
16 views

I'm looking for learning resources on implementing movement tech and player control [closed]

I have a strong technical background (masters engineering student who can program in c++ and who works on physical simulations/numerical methods.) I also understand on a basic level how to work with ...
  • 1
2 votes
1 answer
100 views

Movement system for thousands of entities

I want to implement a movement system for armies of multiple thousand units. However, I struggle to get the movement "stable" when there are more than a few hundred units. The problem: When ...
  • 23
1 vote
1 answer
36 views

Rotating a command relative to the body of a drone

Suppose you have a drone the shape of a cube with rotors on each face, it's completely unable to control its roll-pitch-yaw, but it can accelerate along any of its 3D orthogonal vectors (see image ...
  • 11
1 vote
1 answer
51 views

Rectangular Collision Resolution behaving incorrectly on corners

I'm currently writing a simple game engine and encountered an error while trying to resolve rectangular collisions. When an object moves diagonally and collides with a solid object I only correct it ...
0 votes
0 answers
38 views

Unity 2D Parabolic character movement between platforms displays unexpected behaviour

I am trying to write an enemy AI that jumps between available platforms when it doesn't have ground below its feet. I want the character to do the jumps in a parabolic fashion rather than doing a ...
2 votes
1 answer
42 views

Pygame moving only once when key pressed integrated into player class

I'm having an issue when I have created a player class and want to move my sprite in between three lanes. I was able to get the sprite to move when I used ...
1 vote
3 answers
58 views

How to calculate coefficient for how much a object with velocity x is moving towards point a?

I have a object in 3d space that has certain position and velocity. If that object moves perfectly towards point A, the coefficient should be 1. If it moves perfectly away from A it should be -1 or 0. ...
0 votes
0 answers
54 views

How do buildings in (Tile based) city builders/colony sims keep track of each other? [duplicate]

Like, how does a building in these games know if they're being powered? Or if they're within range of influence of a hospital or fire station, etc. How would they know where to send an NPC or ...
0 votes
2 answers
102 views

Why is Vector3.ProjectOnPlane() "drifting" further from desired rotation on steep slopes

I'm writing a simple player movement script in Unity 3D, and I've been using Vector3.ProjectOnPlane() to accomplish slope/ramp movement. For the most part, this ...
0 votes
0 answers
70 views

Movement diagonally is not consistent

I am making my own game and this is the first time i'm doing so. so I hope you can forgive stupid mistakes. Im making this in C++ and using the SDL2 framework. Currently, I have a character on my ...
0 votes
1 answer
26 views

Anchored Pull Function Breaks at Low Framerate

To start, I'm not working with an engine and am looking for some help fixing the math behind the function I created. Say we have anchor, ...
0 votes
1 answer
37 views

Why is my character controller deacceleration not working?

I want my player to deaccelerate when he stop not just stop in place. Here is my code: ...
  • 131
0 votes
0 answers
52 views

Quaternions around a moving Sphere

I'm using quaternions in my code to move my game camera around an object in 3D space. When stationary it works great and really simplifies the code. Unfortunately when the object starts moving I can't ...
0 votes
1 answer
59 views

Sometimes player moves too much

I'm working on a simple platform game. I have the player - a dynamic body, which moves by ApplyLinearImpulse. Generally it works very well, but sometimes the player ...
1 vote
1 answer
63 views

How to make an object move and rotate the same amount as another obejct

INTRO: I am trying to make a camera move around in a fast moving, rotating in all axis, spaceship.... This person has achieved exactly what I need to achieve if that is a good reference for you (go to ...
  • 169
2 votes
0 answers
97 views

What's the best strategy for incorporating jumps into a 3D AI navigation algorithm?

I'm trying to make a game centered around chase sequences in a 3D level with a high degree of verticality and movement options for the player. Basically think Breath of the Wild in an urban landscape ...
0 votes
1 answer
35 views

Player movement script based on a given symmetry

I'm trying to make a game where the movement of the second player is based on the first player's movement but with a given line of symmetry. For example, if the inputted symmetry was y=x, then when ...
  • 1
0 votes
0 answers
16 views

Help with making a sidescroller enemy turn in the opposite direction

recently I’ve been working on a way to make a sidescrolling enemy turnaround & go back in the opposite direction when they collide with a non-player object, with my setup being based on the one ...
0 votes
1 answer
39 views

JS 2D top down movement doesn't act as expected

I realise this is very similar to other 2D movement questions already posted but cant find a solution that fits the behaviour I'm looking for, so I'm posting in the hope that someone more ...
0 votes
0 answers
51 views

Problems with creating Linear Guide using Configurable joint

I'm trying to create an Linear Guide mechanism using Configurable Joint (I think this joint is better than other for this situation). I connected an orange cube to another object (let's call it frame) ...
0 votes
0 answers
64 views

Latency handling methods in a fast-paced multiplayer game with moving objects

I am working on a real-time multiplayer soccer game. Currently, on my game, I created an architecture like that: Every client has a copy of the game state, also the server has it too. Clients send ...
1 vote
1 answer
240 views

Vertex Displacement Shader Graph With The Camera Moving Issue

I have a foliage sway shader, that works well. But when the camera moves the vertex displacement stops: And the weird thing also is that if I move the camera to the right nothing seems to happen, ...
2 votes
0 answers
246 views

Fix slow and weird diagonal movement on slopes in Godot 3D?

I am creating a 3rd-person player controller using move_and_slide_with_snap in the style of WoW, so the player's speed should be the same horizontally no matter what the slope of the terrain they're ...
0 votes
2 answers
51 views

Unity Follow Object Movement in Local Space?

I have two objects in my scene each at different positions and rotations in the scene. In this example, object A (the leader) moves according to controls. I need object B (follower) to follow the ...
0 votes
1 answer
50 views

Control different speeds for moving left/right, and facing that direction

I have a game idea... and I need a script where I can control the speed for moving left, and control another speed for moving right. But, I also need to let my player face that direction. ...
5 votes
1 answer
231 views

Why would a bigger game move the gameworld around the Player instead of just moving a player within a gameworld?

So, this might be a little random since I can't remember any specific examples but this question just popped into my head 30mins ago and wont leave me alone. I remember hearing about some big game ...
  • 51
0 votes
1 answer
63 views

Sliding character inside the circle

When it comes to rect against rect smooth sliding movement, that is easy. Something like this will work ...
0 votes
0 answers
34 views

Javascript Game Collision Shaking

I have a problem with collision shaking. The problem doesn't come from the collision, but from client side (sometime the it's smooth and sometimes not). Here is a video to show it : https://www....
0 votes
0 answers
85 views

LibGDX sprite not moving with rotation

I have a player class and I'm trying to rotate the player and move it in the direction it's facing. The rotation works but I can't get the sprite to move. ...
0 votes
2 answers
74 views

How to restrict player movement without jitters

I am currently making top-down space shooter and would like to hear some suggestions on how to restrict player movement without causing jitters. Everything works fine except one thing: the player (...
0 votes
0 answers
22 views

Applying quadratics to velocity based player movement

In a speed based system where player.x and player.y +=1 when a button is pressed, a 3pt quadratic can be calculated via ...
  • 197
1 vote
0 answers
680 views

Pixel-perfect jitter-free motion

Here's a thing I cannot wrap my head around: When we are talking about low-resolution pixel art, there is a subcategory that deals with pixel perfection: Like in the olden days you are restricted to a ...
  • 111
1 vote
1 answer
194 views

Simulating movement input in server-side, with different tick rates

I'm designing a simple MMO game server with the help of ENet (reliable UDP library) and the Godot engine for client-side. I've read tons of articles, guides, stack exchanges questions regarding ...
  • 11
0 votes
1 answer
41 views

Implementing Linear Diagonal Movement Relative to Camera Rotation

So far I've implemented horizontal (X-axis) and vertical (Z-axis) linear movement for the player in a 3D game. Using the code shown below, the player is able to move relative to the camera's Y-axis ...
  • 101
0 votes
0 answers
389 views

How can I force my Navmesh agent to only move four directions? (for 2D)

I'm making a 2D game in Unity. For 2D I am using the NavmeshSurface2D-plus master package available on github. My enemy object is chasing my main character nicely, it's ok. I set my main character to ...
  • 13
1 vote
0 answers
29 views

Calculate 2d rotation to target (uniformly accelerated rotation, constant speed)

I'm trying to calculate an uniformly accelerated rotation for the autopilot module in my 3d space game shooter. The autopilot should fly the spaceship to any given point in the 3d space on the ...
0 votes
0 answers
33 views

High rigidbody drag value gives weird speed readings

when calculating speed in unity ...
  • 169
0 votes
1 answer
48 views

Animation and Movement -- Prototyping Efficiently

I'm a solo dev working on prototyping my game's movement system. My character is intended to be agile and lightweight, with quick movement options and a knack for climbing. As we know, the key to ...
0 votes
1 answer
122 views

Pygame : having trouble with implementing movement with vectors

I've been struggling a lot to learn how to use vectors in programming. Now I've successfully made my own vector class but I still can't use vectors for movement. This is my class : ...
  • 216
0 votes
1 answer
207 views

Make object follow another object like a dog sled

I'm trying to achieve the effect of a dog sled for a small prototype. All my attempts failed until now. I have the following code (inspired from this) ...
11 votes
1 answer
3k views

How can I "zero out" velocity in an arbitrary direction?

I'm currently running into an issue with my character controller using physics-based movement of rigidbodies in Unity. Here's an illustration of the issue I'm facing: Basically, after a jump, my ...
  • 530
0 votes
1 answer
88 views

Callback to a dynamic value in GameObject.transform

I'm currently writing an InputManager using Unity's "new" input system. The InputManager receives all player input ...
1 vote
1 answer
33 views

Can't get ThirdPersonController player to stick to a moving platform

I've followed 10+ tutorials on setting up basic C# code to allow a player gameObject to stick to a moving platform (even followed the code verbatim) and nothing works. I added some debug print ...
  • 21
0 votes
0 answers
9 views

In Unity how do I translate a game object's position relative to the axes of its parent object? [duplicate]

Basically, I have the following issue in my game scenario. I have a player game object whose parent object is a player rig (the parent also contains a camera following the player). I want to be able ...
0 votes
2 answers
87 views

Why do objects spin in circles instead of stopping when reaching their target?

This script is attached to each drone. ...
1 vote
1 answer
125 views

How to rotate a 3D object based on stick Input and the normal of the ground's surface? (Unity3D)

I am making a game where I want to view an object from any angle and use an analog stick to rotate it according to this input and the surface the object is currently resting on. Here's a visualization ...
0 votes
1 answer
51 views

Overshooting when traversing between two points with a set velocity

I'm creating a prototype for something I may make into a game and I've run into difficulty in creating a method to move a ship along a line between two points. While it reaches the end point, it ...
0 votes
0 answers
51 views

TRPG data structure

I have this question since a while now. In a TRPG game like Fire Emblem or Advanced Wars (or even in something simpler like a chess game) with tiles and units, you need to store where each unit is in ...
  • 115
0 votes
1 answer
72 views

Move between two points at a constant speed in LWJGL

I've been making a game engine in lwjgl and I have been trying to get an ai to move from one point to another. I used a lerp method but the speed is dependent on the distance between the two points, ...
's user avatar
0 votes
0 answers
68 views

Unity 2d - Enemy continuous curved movement

I'm trying to implement random enemy movement in a top down shooter game. Currently the enemy moves in a straight line from his current position to a randomly generated target position. Is there any ...

1
2 3 4 5
20