# Tagged Questions

A process of adjusting game objects position after collision.

5k views

### Microsoft XNA Platformer Example, is the Collsion Detection implemented accurately?

The example provided by Microsoft seems as if the collision detection (from what I can see) will have a small error. When the user collides with an Unpassable tile, the depth of the intersection is ...
3k views

### How do I calculate rotation caused by bounce friction?

Following on from my previous question: I have the ball quite realistically bouncing from surfaces it hits. Now I'd like to make it spin from the friction of the hit. Showing this is simple enough: I ...
5k views

### How to deal with corner collisions in 2D?

I'm writing a top down 2d XNA game. Since its my first I'm trying to write the physics and collision stuff myself to learn it. Whenever my player sprite character attempts to move into a position ...
7k views

### Collision resolution in case of collision with multiple objects

I have static objects and movable objects. The collisions are detected using the separating-axis-theorem. For example, in this situation I have two static objects (in red): and a movable object ...
766 views

### How to separate colliding objects without creating more collisions

Suppose I use a simple discrete collision detection system where I move all objects then check for collisions. I want any colliding objects to be separated (of course) and assigned appropriate ...
2k views

### How do I resolve a collision of a rectangle with two rectangular tiles at once?

I am having some problems with collision detection between a player and the environment in a tile-based game. I have a player objects, Tiles and what I call MapObjects. The tiles are all 16×16. The ...
516 views

### Help me please to choose proper path-finding algorithm

I am new to game development and just want to ask for advice. I need to know which path-finding algoritm will be suitable for my scenario: Units - any shape. But in most cases rectangles of ...
2k views

### 2D AABBs and resolving multiple collisions

Okay, so this is a problem I've been trying to figure out for quite some time. Mine is a 2D platformer game with a world made up of (usually) immobile tiles and mobile sprites, both of which use AABBs ...
3k views

### Circle-Rectangle collision in a tile map game

I am making a 2D tile map based putt-putt game. I have collision detection working between the ball and the walls of the map, although when the ball collides at the meeting point between 2 tiles I ...
3k views

### Hexagon collision detection for fast moving objects?

A object has a position and a speed vector. Usually only the position is used to check if two objects collide, this is problematic for very fast moving objects as it can happen that the object moves ...
3k views

### How to implement friction in a physics engine based on “Advanced Character Physics”

I have implemented a physics engine based on the concepts in the classic text Advanced Character Physics by Thomas Jakobsen. Friction is only discussed very briefly in the article and Jakobsen himself ...
3k views

### How to resolve penetration of two colliding bodies

I've implemented simple 3D game physics engine. I already have decent collision detection in place, now I'm trying to figure out the collision response part. I'm using impulse based method to ...
1k views

### Handling collisions with ground

How do you usually solve collisions between entities and the ground? Sending collision events hardly seems appropriate since almost everything touches the ground at almost all points in time. Calling ...
2k views

### How do I make a collision between AABBs slide?

I have a room with objects inside. Each object has it's own AABB. I know how to check for collisions between the objects with an AABB-AABB intersection. How do I calculate an appropriate collision ...
553 views

### How to make a stack stable? Need help for an explicit resting contact scheme (2-dimensional)

Previously, I struggle with the sequential impulse-based method I developed. Thanks to jedediah referring me to this paper, I managed to rebuild the codes and implement the simultaneous impulse based ...
2k views

### Collision rectangle response

I'm having difficulties getting a moveable rectangle to collide with more than one rectangle. I'm using SFML and it has a handy function called intersects which takes 2 rectangles and returns the ...
2k views

### How do I restrict the movement of a point to within a radius of another?

I have a situation where a sprite's center point needs to be constrained within a certain boundary in 2D space. The boundary is circular, so the sprite is constrained within a radius. This radius is ...
407 views

### Move penetrating OBB out of another OBB to resolve collision

I'm working on collision resolution for my game. I just need a good way to get an object out of another object if it gets stuck. In this case a car. Here is a typical scenario. The red car is in ...
678 views

### Allowing a player to walk up and down slopes without resistance

I am trying to implement a platformer where both the player and the level are made up of arbitary polygons. One requirement is that the player can stand still on slopes, and walk up and down them ...
315 views

### Lerping character moving up and down slope tiles

So, when interpolating position against a standard 'horizontal' platform, everything works great. What happens is something like this..... (Question continues after graphic) Now, the question I ...
2k views

### Collision with tile corners/seams in 2D platformer

There seems to be a lot of somewhat related questions answered already, but none I read answered my exact problem. I have a 2D platformer whose world is made entirely out of tiles that are in a ...
742 views

### Character jittering with this tile based collision code

I have been trying to get my collision code working for hours now but with every resource I have tried my character still jitters. First I tried using the platformer sample but my character still ...
623 views

### How do I avoid pathfinding characters getting stuck in corners?

I used A* pathfinding to return a list of Tiles to get from an enemy to the player. After that, I wasn't sure how to actually move the enemy. What I ended up doing was get the first Tile in the path. ...
166 views

### AABB collision resolution issues

I'm trying to make a character collide with some tiled terrain. I have an issue with the collision resolution, and after days of shooting in the dark ant not finding any relevant help online, I'm no ...
990 views

### How to detect screen boundary using AndEngine GLES1?

I am using the AnalogOnScreenControl to move my sprite around the screen. I would like to restrict the sprite so it can not move outside the screen boundaries. I have tried putting a line at the ...
455 views

### How can I determine which direction a 2D collision is occurring from?

The problem is as follows: Think 2D Zelda (Links Awakening, A Link to the Past) style movement where you can run into walls from any of the four cardinal directions, or basically up, down, left, and ...
4k views

### Circle-Rectangle collision resolution

I have a non axis aligned rectangle, like a car, in my game. I have to check and resolve the collision between the rectangle and circle, which is stationary. I have found lots of ways to determine ...
161 views

### Collision detection between axis-aligned bounding box and bitmap (pixel perfect) terrain

Working on a Worms-type game, I have my objects in bounding boxes and they sit on the pixel terrain. Currently I am able to successfully do the collision detection for objects when they enter the ...
186 views

### How to calculate new velocities between resting objects (AABB) after accelerations?

lately I have been trying to create a 2D platformer engine in C++ with Direct2D. The problem I am currently having is getting objects that are resting against each other to interact correctly after ...
1k views

### 2D platformer multiple rectangle collision cause jitter

I posted this question two weeks ago: 2D platformer corner collision and I implemented NoobsArePeople2's solution. Problem is, when player intersects two rectangles that are inside each other, he ...
144 views

### Rendering after interpolating, renders inside/outside other objects

So, we're working out our interpolated render-coordinates during our render call and it's doing a fantastic job of smoothing everything out. All is great and collision detection is working to a ...
642 views

### Collision detection - make sure the player touches the object exactly

I know this is really something I should be able to figure out on my own, but a solution is evading me. Okay, here are a few relevant parts of my code. bool Game::Col(int x1,int y1,int w1,int h1, ...
232 views

### Collision Resolution: Objects “swap” places

I am working on making my own simple collision resolution class so I can learn a bit about how it works, while also improving my entity-component model framework. For those of you unfamiliar with a ...
2k views

### Resolving 2D Collision with Rectangles

For about a week I've been trying to grasp the basics of collision, but I've been driven to the point of wanting to just give up on everything when it comes to collision. I just don't understand it. ...
79 views

### simple solution for 3d collision detection and response

I'm having great difficulty trying to implement collision detection and response in a 3d game What are some simple solutions someone can use to implement smooth collision and response similar to ...
986 views

### How do I handle collision response between many different types of game objects?

I am looking for a way to avoid the dreaded switch or if/else scenarios between numerous game object types when a collision takes place in a game. For example: You have a list of game objects which ...