Questions tagged [2d-games]

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.

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, but not a z coordinate unlike in 3D games.

This can range from top-down games, like dwarf fortress, to side-scrolling ones, like platformers. It would refer to any games where the character / objects can move freely in two dimensions (e.g. left-right & up-down).

Related tags:

Remember there is also a special StackExchange site: Game Development

1116 questions
-3
votes
1 answer

Unity - unexpected behaviour when level it's finished

So I made a game like Happy Glass and it's working fine, but sometimes when the level is completed, the screen to go to the next level appears and then immediately dissapears and u cant press next level Here it's a picture for reference: This…
Filu
  • 45
  • 6
-3
votes
1 answer

snake movement in 2d-game

The right movement of the snake is working fine but when I pressed any other key(up or down) to change the direction of the movement, it throws error and the snake doesn't move.The following are the errors: Exception in thread "AWT-EventQueue-0"…
-3
votes
1 answer

How modify this Javascript Block-breaker game?

I have this group project that requires us to modify this JavaScript "block-breaker" game by adding some elements in the game. GAME (http://breakout.enclavegames.com/lesson10.html) that needs to be modified with the following conditions : Change…
-3
votes
1 answer

sprite-kit swift character select sort of menu?

i am making a sprite-kit game for IOS, and i want to add a something similar to a character select menu, how would i do that ? searched around on the web and didn't find any pages that could solve my problem
Hades
  • 41
  • 6
-3
votes
1 answer

How to choose an algorithm?

I've to choose an algorithm for a given problem: The game has two players: x and o. The players take alternate turns, with player x moving first at the beginning of each game. Player x starts at position (1,1) while o starts at (8,8). Each turn, a…
Ana Malin
  • 11
  • 2
-3
votes
2 answers

javascript how can I make collide with each other in DOM not canvas

Ok I got 2 images one of a player that I make jump and another one of a barrel that rolls towards the player. I searched on google to get all the code that I have together. The problem is I can't find a code that can detect collisions. I need that…
-3
votes
1 answer

Looking for Kineticjs Resources

I am looking for Kineticjs Resources ( except the official kineticjs site) - books , blogs , sample projects with source. There are several projects published on the official kineticjs site but i wasn't able to find the source code of any of them.
-3
votes
1 answer

Programming Gravity

I'm programming a game (JAVA) and i would like to add some gravity in. I tried to find a formula or someting like this and there is so different way to do it. I'm looking for a formula who can simulate a realistique gravity and make some rebound…
user2065368
  • 3
  • 1
  • 2
-3
votes
2 answers

Java 2D game, Both of my rectangles are moving when only one should move

I have coded a simple Java game where there are two rectangles on the screen, one of the rectangles should move and the other should stays still, the moving Rectangle moves with keyboard arrow input and can move either up, down, left or right. The…
Rahul Khosla
  • 349
  • 9
  • 21
-3
votes
1 answer

Enemy following player in XNA and stop within 20 pixels

I'm trying to get my enemies to follow the player and stop within 20 pixels, I have tried a number of algorithms including the Vector2.Lerp(); method to try and fix this but it keeps breaking the build. Any help would be greatly appreciated. The…
Bradley
  • 617
  • 2
  • 11
  • 26
-4
votes
1 answer

Tic Tac Toe JS game

I don't know exactly what is wrong in cod, can you help me find it? What I know is that 'available' array is not correctly emptying and computer sometimes plays two moves in row. link to code on github:…
-4
votes
1 answer

How to solve pc gaming error is water game?

I'm trying to make a game in Python using PyGame, but I receive this traceback: Traceback (most recent call last): File "C:\Users\usuario\Documents\abscorp\232\232.py", line 150, in hits = pygame.sprite.groupcollide(drop, player,…
Scorp Y
  • 51
  • 2
  • 6
-4
votes
1 answer

Incorporating Levels into iOS Game?

I am a beginner developer and programmer and was wondering how to set up an iOS game so that there are levels which can be unlocked once you beat the previous one. Is it under the 'Game' and 'SpriteKit' settings to get started? Also, how is a…
E. Brez
  • 1
  • 3
-4
votes
1 answer

In Java can you create an unordered collection of objects that have multiple links?

I'm trying to make a game similar to Risk where each territory on the map is an object of a class I made, Territory. In order to create the game map I would like each Territory object to be linked to the other territories that would be adjacent on…
-5
votes
1 answer

Calculating the distance between two random points in a C++ Battleship game

So, my problem is how to calculate the distance between the two random points (x,y) so i can use the abs method (as i was starting to do in the Function bool CheckColpo) and tell the player if his shot was actually in range of the enemy ship's…
1 2 3
74
75