Archive for 2012

Tutorial [Java]: Snake Game Remake

The first thing I wrote when I made this blog was a 7-part tutorial series on writing a snake game in Java. Unfortunately, due to inexperience and the tutorial format, the code wasn't very well written and the result was rather sloppy. I decided to spend much of this morning rewriting a greatly improved version of the game from scratch.

Posted in , , , , , , , , | 35 Comments

Tutorial [Java]: Tetris Game

It's not uncommon to see new game developers writing clones of classic games. The games are usually simple enough to write in a day or two, and generally don't need to be optimized for modern hardware. This makes them a great starting point for learning the basics of game development. While I have tinkered around with more complex games, I still enjoy making simple games or programs and sharing them on here with anyone who's watching.

Posted in , , , , , , | 29 Comments

Tutorial [Java]: Creating a Snake Game [Part 07] - Putting it All Together

Note: I have completely rewritten and improved this game. Most of my traffic comes from these posts, so I've not deleted them. Please use the new version which can be found here.

Finally, we're on the home stretch for the game. All that's left to implement is death and respawning. Let's not waste any time and jump straight in and get this beast finished, shall we?

Posted in , , , , , | 6 Comments

Tutorial [Java]: Creating a Snake Game [Part 06] - Fruit and Scoring

Note: I have completely rewritten and improved this game. Most of my traffic comes from these posts, so I've not deleted them. Please use the new version which can be found here.

Games get boring rather quickly if there's no goal to it. For this reason, our game is about as entertaining as watching paint dry. To change this, we need to introduce the scoring system, and a steadily increasing difficulty. This section solves both of these problems in one quick swoop.

Posted in , , , , , | Leave a comment

Tutorial [Java]: Creating a Snake Game [Part 05] - Controller Input

Note: I have completely rewritten and improved this game. Most of my traffic comes from these posts, so I've not deleted them. Please use the new version which can be found here.

What good is a game if there's no way for the player to interact with it? As I mentioned in the last part of the tutorial, this section will cover the controller input that is used in the Snake Game. This section will probably be relatively short, since we've already implemented most of the code in the Snake class. Anyway, let's begin!

Posted in , , , , , | Leave a comment

Tutorial [Java]: Creating a Snake Game [Part 04] - The Snake

Note: I have completely rewritten and improved this game. Most of my traffic comes from these posts, so I've not deleted them. Please use the new version which can be found here.

Now that we have the world and the engine in place, we need to get working on the player. In the case of the Snake Game, the player assumes the role of the Snake. A majority of the game's logic goes into updating the snake, as it has the many more physical properties and updates than anything else in the game. With that said, let's get started, shall we?

Posted in , , , , , | 1 Comment

Tutorial [Java]: Creating a Snake Game [Part 03] - The World

Note: I have completely rewritten and improved this game. Most of my traffic comes from these posts, so I've not deleted them. Please use the new version which can be found here.

The next step in creating the Snake Game is to create the world. Without the world, there would be no where for the game to take place, which wouldn't be fun at all. In the case of the Snake Game, the world will be an array of tiles, each with a type, which we can make use of when writing the game's logic.

Posted in , , , , , | 4 Comments

Tutorial [Java]: Creating a Snake Game [Part 02] - Game Engine

Note: I have completely rewritten and improved this game. Most of my traffic comes from these posts, so I've not deleted them. Please use the new version which can be found here.

At the heart of every game is the engine. The engine is responsible for updating the game at fixed intervals, in response to events, or a combination of the two. In the case of the Snake Game, we need to update the game at regular intervals, and accept user input from the Keyboard. This part of the lesson will explain how to setup the basic game engine, which we will add functionality to as we develop the game.

Posted in , , , , , , | 15 Comments

Tutorial [Java]: Creating a Snake Game [Part 01] - Introduction

Note: I have completely rewritten and improved this game. Most of my traffic comes from these posts, so I've not deleted them. Please use the new version which can be found here.

Snake is a classic game in which the player controls a snake that moves around and eats fruit. With each piece of fruit that the snake eats, it grows in length by one, and the player earns one point. The player loses the game when the snake either collides with it's tail, or a wall.

Posted in , , , , , | 5 Comments

Search

Swedish Greys - a WordPress theme from Nordic Themepark. Converted by LiteThemes.com.