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
0answers
12 views

Preview source state does not change

I am currently following this book "Developing 2d games with Unity" by Jared Halpern. I hope you might be familiar with it or you can help me anyway. Currently I try make the movement of my character ...
0
votes
0answers
9 views

How to avoid camera jerkiness when using integer-based movement with a remainder?

I am experimenting with a low-res project in GameMaker 2. To preserve the pixel art and prevent distortion, I have my movement code set up to only move my sprites in integer intervals. Basically, ...
0
votes
1answer
82 views

NPC Melee fighting movement issue

So i have been struggling with this for ages and I have now decided to reach out for help. The Problem: The game has two NPCs for reference we will call them "Ally" and "Enemy" Ally and Enemy each ...
1
vote
1answer
231 views

Animation Dilemma: How to create authentic discontinuous block-like character movement

I am using Unity. I have quite a bit of Unity experience, however I am a novice in animation. In the past I have had someone else do character Animation aside from some Camera animation and simple ...
0
votes
2answers
92 views

Using delta time for movement

I'm currently involved in a college assignment where we must create a game with our own game engine. In my game, we have an enemy moving around with paths constructed with a A* algorithm. Every frame ...
3
votes
1answer
411 views

AS3 move object to a point

I'm trying to make a room full of monster each side and the player stay in the middle. I have a problem, I don't know how I move each monster to the player and rotate each of them to face the player, ...
0
votes
1answer
51 views

How can I move my player on exact x and y coordinates, like on a grid?

I'd like to implement movement exactly like it is done in this game. (You can see it in action on YouTube.) I need my Player to always stay in the center of X and Y similar to grid movement, but with ...
0
votes
1answer
41 views

Way to Prevent Stacking Pieces (DnD)

I have a chessboard with all the black pieces that move with this code: I found that when I move the pieces, they will stack on top of each other. How can I prevent this? I have since changed the ...
0
votes
2answers
54 views

SDL2 Block collision with player Bug

I am currently working on a small 2D Games Engine with SDL2 for fun. The engine works in a way, that you can define a tileset, which accesses the engine and allows you to place tile by tile on the ...
0
votes
0answers
48 views

How would I go about making an area make the Player slower? [closed]

I am quite new to Unity so I don't know a crazy amount but topic is question.
0
votes
2answers
278 views

How to design components for tile-based movement in an RPG using ECS

I'm trying to re-write a small game of mine using ECS mostly for educational purposes and to see if it fits top-down RPG games in the style of Pokemon (gameboy). Since everything is tile based, ...
1
vote
1answer
165 views

How to handle forward/backward movement in an oblique top-down view

I'm making a pseudo-2D top-down game, where my assets are actually 3d but I use an orthographic projection to introduce more depth. I saw a picture of how the game "Enter the Gungeon" was actually ...
0
votes
1answer
38 views

Move a ball horizontally left and right but restricting forwards and backwards motion unity 2d

I am trying to develop an endless runner where there is a sphere as the player and it is moving left and right following the position of a finger on a touch screen. However, when I try to do this I ...
0
votes
1answer
4k 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. ...
1
vote
0answers
59 views

Rolling a circle around a square

I am stuck on a simple Box2D task. I have a box and a ball (in top-down view so no gravity), and I would like the ball to roll around the box. Here is my code. Basically now I am trying to detect ...
0
votes
0answers
47 views

How do I make my 3d cube move left and right with buttons in Unity with RigidBody.AddForce?

How do I make my 3d cube move left and right with buttons in Unity with RigidBody.AddForce()? I can't figure out how to do this in Unity! I'm trying to make my game ...
0
votes
1answer
61 views

Higher order splines for use with pathfinding

In this page, Amit explains that splines can be used to achieve movement on a found path. In the picture below, he explains that: The blue paths use splines, with dark blue being low order ...
0
votes
0answers
18 views

can't achieve a smooth movement with ShapeRender

I am using ShapeRender to render Circles and in the update function on every loop I update the coordinates that represent my ...
1
vote
1answer
6k views

Jump Script Component For Character Controller

I'm trying to implement a jump method into my FPSInput script. I know how to make this work for a Rigidbody, but how can I accomplish this with my Character Controller? Does CharacterController have a ...
0
votes
1answer
27 views

Prevent Wall Clipping with Bouncing Shape

I'm currently working on a demo-type program involving bouncing objects. Currently, I have a rectangle that can bounce around the screen. When the rectangle bounces against one of the walls ...
0
votes
0answers
17 views

Implement a scale factor to apply to UCharacterMovementComponent::JumpZVelocity in Unreal Engine 4

I'm creating a my own movement component inherited by UCharacterMovementComponent. I should implement a scale factor (I called it JumpZVelocityScale) to apply the JumpZVelocity (and I don't want ...
1
vote
1answer
72 views

In a MovementComponent, where should I initialize member variables?

I have a MovementComponent derived from CharacterMovementComponent MovementComponent, ...
1
vote
1answer
17 views

How do the PhysWalking and similar functions actually handle input?

As the title may suggest, I'm developing a CustomMovementComponent and I'm on the stage where I am developing my own PhysCustom ...
0
votes
0answers
25 views

How to use a derivative of CharacterMovementComponent

I'm developing a 3rd person platformer. My Character class (the default third person template class): PlatformerCharacter : ACharacter My MovementComp class: <...
0
votes
0answers
17 views

Add touch screen support to tile navigation

I saw this awesome tutorial that is related to Grid-based Movement in Godot What I want is to add touch screen support for this kind of movement i.e. with virtual on screen joystick or gestures. How ...
0
votes
2answers
2k views

Diagonal movement is faster than horizontal or vertical movement (unity)

When using Horizontal or Vertical input keys, the the movement is normal. But when trying to move diagonal, multiple keys are to be pressed, and the speed just stacks up. Yes there are many answers ...
1
vote
0answers
20 views

Smoothing long paths with splines

What is the best way to smooth a long path with splines? I first implemented a Bezier curve but then realised that I would have to join a lot of them. I used A* on a weighted grid so I can't use ...
0
votes
0answers
43 views

How does CharacterMovementComponent::PerformMovement work?

I'm developing an adventure platformer. As such, the manipulation etc. of the CharacterMovementComponent is going to be crucial to the game. I have seen the more ...
0
votes
1answer
52 views

How to get the actor to follow the mouse while clicking and holding?

I am trying to do the top down project from scratch. I can already get the actor to move toward the mouse click: Only I need to keep clicking several times to change its path and keep walking ...
0
votes
2answers
52 views

The camera goes up and down when following a rolling sphere

I have this CameraController script attached to my camera, to follow a sphere that moves using WSAD. ...
0
votes
3answers
142 views

How do you make a object that always follow another object?

I'm trying to make a game object follow another game object and switch to another when a button is pressed. But right now it just seems to change the position when the button is pressed but it doesn't ...
0
votes
1answer
49 views

Simple 2d Movement (Non platformer)

This seems so simple but my searching as failed to find a good result. The idea is that you can move in 360 degrees but you aren't faster when you move in a diagonal direction. I know how to do this ...
0
votes
2answers
109 views

Why is my player movement code not working?

I'm trying to make my 2D character able to float around the screen, but my code isn't working: ...
1
vote
1answer
146 views

Game object appears to accelerate too slowly

thank you for checking out my issue! I am trying to develop a game in java, but I have run into a problem. I would like to keep the physics as realistic as possible, so I am using a fixed time-step ...
0
votes
1answer
892 views

What is a good approach to dynamically change actor Position?

In my card game there are 2 players with each player having a hand(a ListArray of of Cards.In this case its ...
3
votes
2answers
238 views

How to program smooth player 2D movements

I am writing a simple 2D game in Rust, having access to the following dependencies: Piston: for the graphic engine nphysics: for the physics engine The genre is Metroidvania, the game features a ...
28
votes
4answers
10k views

How can I move an object in an “infinity” or “figure 8” 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 ...
0
votes
1answer
38 views

Why is Camera turning with different speed than Player with same code in different scripts? (with unity)

I want to integrate a running character in my game, so I downloaded the animation via Mixamo. The player is running and if I attach the camera directly to the Player it's shaking the camera and the ...
0
votes
1answer
131 views

Unity: Move Collider up stairs/ramps

The bots have a simple Capsule collider which cannot tilt. Movement is applied across the horizontal axes, gravity is enabled on the rigidbody. It moves up stairs okay with steps roughly 0.2 units ...
0
votes
0answers
24 views

Calculating stopping distance while turning

I need to calculate the movement of an object that is slowing down to approach its destination while turning. Calculating the linear stopping distance and deceleration is straightforward. However if ...
0
votes
1answer
211 views

LibGdx Positioning the camera

I've been following some tutorials about libGdx and I've tried to create a 2d platformer but I've got stuck at how would be the right way to make the camera not go out of the screen when the player ...
3
votes
1answer
940 views

How can I move a vehicle using speed and steering angle?

I want to drive a vehicle in x and y coordinate area with range from (0,0) to (6000,5000). I am using Visual Components (using Python API). On input I have speed data and steering angle of wheels ...
1
vote
1answer
121 views

Tile based smooth snake movement

while making my own Snake implementation I decided to use delta time for smoothing movement on screen. The problem is that before Snake was moving fixed amount of pixels every frame, but now when ...
0
votes
1answer
173 views

Drag object with mouse in diagonal direction

I have a gameobject which i want to move using mouse. Currently i can do that in x-axis and y-axis: ...
2
votes
2answers
108 views

Make a bullet move towards the mouse position

Before you give me a link to another post look first, just in case. So I'm making a top down game where the person can shoot around, I want the bullets to move towards the mouse, I have tried this: <...
0
votes
1answer
181 views

libgdx Player movment dungeon crawler

The player go's throe walls and stops when theres no wall. Code: ...
1
vote
1answer
177 views

Character Movement - Canvas Character - Javascript

How do I change the arrowkey movement so that is based off of the click of the buttons instead? Cheers ...
0
votes
1answer
1k views

Change Pawn movement speed

I'm newbie in Unreal development and I don't know how to move my pawn faster. By the way, I'm using Unreal 4.16. I'm developing Pong game and I have this method to move the pawn: ...
0
votes
1answer
57 views

Calculation of distance while switching between two speeds

There are two speed values, that are used by moving object. After a while speed switching occurs from V1 to V2. I need the formula that can be used for calculation of current distance (at specified ...
1
vote
1answer
574 views

Unity Mobile project, button problem “CrossPlatformInputManager.GetButton” not working

Good afternoon, I have a problem with an input in my code: Before testing it on mobile I tried on PC and the code to make my player sprint was like this: ...