2D games are drawn in a two-dimensional space using two-dimensional objects. To represent its position, each game object will have an `x` and a `y` coordinate.

learn more… | top users | synonyms

5
votes
3answers
1k views

2D Platformer Collision/Physics Problems

I'm making a 2D platformer similar to Terraria, although I'm having some problems with some collision detection code. I'm using the code from the AppHub Platformer sample, but tweaked so it fits with ...
12
votes
1answer
3k views

Terrain Generation for Tile-Based 2D Platformer

I'm currently working on a tile-based 2D platformer similar to Terraria in some ways, although I'm having difficulty with the terrain generation. I have some basics done, although they do not come out ...
15
votes
6answers
768 views

What are some techniques for designing fun, challenging Mario-style platformer levels?

I have everything I need to make a Mario type game. I just have no idea how to design the levels to make it challenging or fun. Any tips? The only way to kill enemies is by jumping on them, so I ...
8
votes
2answers
2k 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 ...
14
votes
3answers
2k views

What are the pros/cons of using a 3d engine for 2d games?

What pros or cons should a beginner be aware of when deciding between a 2d game engine (like Slick2D/Flixel/FlashPunk) and a 3d engine (like Unity) for 2d game development? I am just getting started ...
0
votes
2answers
748 views

Can you help me find resources for developing a top-down 2D game in Java?

I just started reading about games, and I'm going to develop a game where a person is moving around on a 2D map. My preferred language is Java. Is that suitable to develop games? I'm going to ...
15
votes
3answers
1k views

How can I identify feature regions in a procedurally generated world?

I'm building an Island. I use the classical heightmap solution : with a hill-building function, avoiding the corners of the map, I make altitude. Then, perlin noise give me some climatic variables to ...
3
votes
4answers
3k views

What 2D engine can I use to port my flash game to iOS and Android?

I would like to port my 2D flash game to Android and iOS. Is there any cross platform engine you could recommend? Corona is the only promising one I have found so far.
4
votes
3answers
422 views

Zelda LttP (Super Nintendo) room changes?

I'm trying to make a tile-world adventure game on iOS similar to Zelda Link to the Past on SNES, and one issue I've run into is having my camera move beyond walls revealing the rooms on the other ...
0
votes
2answers
616 views

How to coordinate sprites, player's position and collisions in a Bomberman-like 2D game?

I'm programming a Bomberman in Java (my first game) and I'm having problems with the player's sprites and position in the map. I'm using a 2D integer array to represent: Unbreakable blocks ...
1
vote
1answer
2k views

2D Physics Engine for Platform Games - Riding on a Platform

I have a number of questions relating to using a 2D physics engine in a platform game, but one main one that I'm grappling with at the moment. I managed to somewhat integrate the Physics2D.Net engine ...
2
votes
3answers
355 views

Efficient way of detecting a touched object in a game?

Imagine a Sims-like 2D game for a touch based mobile phone where one can interact with virtually any object in the scene. How can I efficiently detect which object is being touched by the player? In ...
42
votes
2answers
2k views

How can I get textures on edge of walls like in Super Metroid and Aquaria?

Games like Super Metroid and Aquaria present the terrain with the other facing parts having rocks and stuff while deeper behind them (i.e. underground) there's different detail or just black. I ...
6
votes
2answers
1k views

How do I rotate a structure of hexagonal tiles on a hexagonal grid?

My 2D isometric game uses a hexagonal grid map. In reference to the image below, how do I rotate the light blue hexagon structures by 60 degrees around the pink hexagons? EDIT: Main hex is (0,0). ...
4
votes
1answer
2k views

OpenGL or Canvas?

I'm writing a 2D snake-like game for android (Hungry Birds, already in the market), and now I'm wondering if I should port it to OpenGL so that the performance can stay stable while I continuously add ...
5
votes
4answers
662 views

Anyone know of an online resource with spritesheets from classic games? [closed]

I'm looking for spritesheets for classic retro games, and old home computer games (c64, amiga etc.) Does anyone know of a source online?
7
votes
2answers
7k views

Is there a good way to get pixel-perfect collision detection in XNA?

Is there a well-known way (or perhaps reusable bit of code) for pixel-perfect collision detection in XNA? I assume this would also use polygons (boxes/triangles/circles) for a first-pass, quick-test ...
6
votes
2answers
329 views

Maintaining Consistent Scale (2D games)

How do people making 2D games maintain a consistent scale for everything in their game? Say I'm coding an RPG. A house needs to be proportionally bigger than a person; an item, smaller. Everything ...
5
votes
3answers
278 views

Vector Art Tool: Size, Position, Shapes, Symbols

I'm looking for a vector art tool for gameart, similar to Flash, but preferably free. It just needs the following capabilities: Create vector images (can scale up/down without losing quality) ...
1
vote
2answers
1k views

Box2D Platform body not moving player body along with it

I am creating a game using Box2D (Javascript implementation) - and I added the ability to have a static platform, that is moved along an axis as a function of a sine. My problem is when the player ...
2
votes
2answers
337 views

Handling collision with 2D surfaces and player sprite

What's the best way of representing surfaces in a 2d top down racing game? I'd like paved and dirt surfaces in my game to have different friction properties. Would you break up the map into a grid and ...
2
votes
1answer
321 views

[2D] Finding largest possible straight lines around body

I've got a 2D-map, largely consisting of rectangular tiles, but with some none-rectangular objects mixed in as well (tilted lines on corners for example). Take this image as an example: I now ...
0
votes
1answer
463 views

What is the best mechanism for controlling a character in a 2D Android game?

Im developing a 2D RPG for Android where the character can move up, down, left, and right like in top-down RPGs like Pokemon. What is the best input mechanism to use to control the character? A ...
5
votes
3answers
695 views

Game Classes design

I'm trying to create a simple 2D sprite game. The problem I'm having now is how to design my game. I was thinking of using a Sprite class that will be my base class for all the different types of ...
9
votes
3answers
572 views

2d top-down map: normalisation or not?

I am an absolute beginner with game programming, should this question be poorly formulated, be aware it was not sloppiness by my side, but lack of game programming experience. The game I am planning ...
2
votes
2answers
498 views

2D AI Engines/ Resources?

i'm wondering if there's any 2D AI source code or engines out there. I'm inspired by the Euphoria engine, and want to use whatever is already out there to make something like it in 2D, where the ...
12
votes
2answers
656 views

How do you handle uneven tiles while rendering a tile map?

Here is what I want to do with my tile map that I am unsure of. As you can see the top walls are way larger then the bottom and side ones (this is also an issue with my corners which are odd shapes ...
6
votes
3answers
744 views

Find a unit vector exactly halfway between two connected line segments

Seems like a quick and easy question but I haven't been able to find exactly what I'm looking for so: How to calculate a unit length vector that is pointing along the line which is exactly 50% of the ...
5
votes
3answers
476 views

What's the best control scheme for an arena shooter on a touchscreen phone?

I am developing Android an game. It's going to be a top-down shooter with stealth features. I am now thinking about how to the make controls. Most top-down games are now twin stick (joystick on the ...
2
votes
3answers
826 views

Java tilemap not working, Think it has something to do with my image rendering

Hey can someone help me out, I've been trying to fix this for about 2 hours now, and I'm a noob when it comes to game programming and Java(only been reading and programming with it for a week now, ...
4
votes
2answers
1k views

How to calculate the vector of an interception?

Given are a twodimensional space, and 1 friendly spaceship standing still, one foe is moving NOT directly to the friendly ship with known actual position, speed and direction. The friendly ship wants ...
1
vote
1answer
612 views

LWJGL Rendering a 2D Object at a Certain Position On-Screen

Okay, so in LWJGL, how can I render a 2D object (maybe for like a menu, or meter that shows up on screen during the game), and have control over size and position on screen? So I can tell it what ...
4
votes
2answers
690 views

Collision response for 2D racing game

The title is fairly self-explanatory. I have a 2D racing game that utilizes per-pixel collision detection (the track is essentially two bitmaps, one for the graphics, one for collision data). The ...
43
votes
7answers
3k views

2D Platformer AABB collision problems

I have a problem with AABB collision resolution. I resolve AABB intersection by resolving the X axis first, then the Y axis. This is done to prevent this bug: http://i.stack.imgur.com/NLg4j.png ...
18
votes
4answers
2k views

Find Nearest Object

I have a fairly sizable game engine created, and I'm adding some needed features, such as this, how do I find the nearest object from a list of points? In this case, I could simply use the ...
1
vote
2answers
2k views

Android landscape mode game

I am beginner in android game development. I want my game to run only in landscape fullscreen mode (currently I have Optimus 2X with resolution 800x480 in landscape), and I don't know how to set it. ...
3
votes
3answers
7k views

What's the best program to learn/create 2d vector sprites?

I have Photoshop experience and a bit of drawing experience, and am looking to learn how to create sprites like this: http://www.lostgarden.com/2009/03/dancs-miraculously-flexible-game.html Any tips ...
1
vote
1answer
3k views

Where to find free platformer sprites for commercial use? [duplicate]

Possible Duplicate: Where can I find free sprites and images? I need some good 2d platformer sprites for a game i am making in C#. Can anyone suggest a good site or link? The sprites need ...
4
votes
3answers
3k views

Where to look for good 2d c++ opengl game engine architecture?

I'm writing own game engine and want to look how other peoples implement game engine architecture. So any advices about well architected engines (even paid ones) are welcome.
5
votes
4answers
714 views

(Where) Can I learn to create art for my 2D games?

I'm currently bad at drawing. If I want to create something looking acceptable, it usually takes me hours and hours to fiddle around just to get the basic looks right. I think that I'm not completely ...
3
votes
3answers
8k views

How to transform a 2d drawing in a 3d model in easy steps? Where to start?

I have a great draftsman, but I don't know how to take his drawings to 3D My basic notions guide me to get a front picture and a side picture and then put in a cross in a z-axis and give them ...
1
vote
2answers
402 views

Level Creating Help

I am making a little 2d overhead RPG type game just for fun. I have almost all the basic stuff set up, but I just need a little help on level creation. I can already make a level and place each tile ...
2
votes
6answers
839 views

Random Position between ranges

Does anyone have a good algorithm for generating a random y position for spawning a block, which takes into account a minimum and maximum height, allowing player to to jump on the block. Blocks will ...
10
votes
3answers
639 views

Drawing particles as a smooth blob

I'm new to game/graphics development and I'm playing around with particles (in 2D). I want to draw particles close to each other as a blob, just as liquid/water. I do not want to draw big circles ...
4
votes
3answers
827 views

Render angles of a 3D model into 2D images?

Is there a tool out there that you can give a 3D model file, and it will output 2D renders of it from various angles? For example if you were making a 2D RPG but you want to make your character look ...
5
votes
4answers
2k views

What language to use to create a browser-MMO? [closed]

I have a game ready to be implemented (Class Diagrams and other UML stuff are good). Here are some characteristics: MMO. Browser game and download-game. Multiplatform. With 2D graphics. Real time. ...
6
votes
2answers
777 views

Casting a shadow over a whole scene with GLSL in 2D?

I'm making a (non-isometric) side scrolling 2D game and I want each fragment that I draw to cast a small drop shadow when it is near another object. What sort of algorithms are used in fragment ...
7
votes
5answers
3k views

2D rectangular object collision - Detect direction

Coming form this question, I'm needing some more help. I need some ideas to find out from which side the collision came, and react accordingly. Use this image as reference: The blue lines are the ...
9
votes
1answer
1k views

Angle of Reflection

I have this "Breakeout style" game. I have a cannon at the center, blocks around the cannon and pads around the blocks. This is how the game looks like: I've managed to get the collision per ...
11
votes
1answer
1k views

Draw real time fog of war in 2d game

I have game situation as shown in picture: Red dot: player Brown dot: obstacle ( rock, tree, etc) Grey: non visible area ( under fog of war) My question is: how can I draw that kind of shape, ...

1 14 15 16 17 18 21