Jump to content

  • Log In with Google      Sign In   
  • Create Account

New Old Things

A C64 game - Step 11

Posted by Endurion, in Uncategorized, C64 24 June 2011 · 824 views

From colliding to dying is a small step. Once the player collides with an enemy we kill him by removing the player object. A "Press Fire to Restart" message is displayed and a press on the button will revive the player object.

We add the function RemoveObject which simply removes the object from the SPRITE_ACTIVE table and disables its sprite....

A C64 game - Step 10

Posted by Endurion, in Uncategorized, C64 17 June 2011 · 873 views

So you found out the enemies couldn't hurt you? Well, we're working towards that goal in this step. We add collision checks. Since I'm not completely sure about later changes we are NOT relying on the VICs collision checks but roll our own. Remember the object size contraints from step #6? We apply those to the object collision checks as...

A C64 game - Step 9

Posted by Endurion, 11 June 2011 · 884 views

What are enemies if they just sit put and don't move at all? Therefore we now add the sub routine ObjectControl. ObjectControl loops through all objects (even the player) and jumps to the behaviour function depending on the object type. This incurs that the behaviour is tied to the object type. We provide a table with function pointers to every...

A C64 game - Step 8

Posted by Endurion, 03 June 2011 · 900 views

Of course a game isn't a game without some challenge. Therefore we need enemies. Since we have some neat little level build code why not use it for enemies as well?

We add a new level primitive type LD_OBJECT which adds objects (= sprites). We use it for both player and enemies. A new table SPRITE_ACTIVE is added to see if a sprite is used (and which...

A C64 game - Step 7

Posted by Endurion, in Uncategorized, C64 29 May 2011 · 1,071 views

Now it's starting to resemble a game. Loosely.

In this step we add gravity and jumping. The player will fall if there is no blocking char below. On joystick up the player jumps in a curve.
Both fall speed and jump speed are non linear and based on tables.

This step shows:
-gravity (accelerating)
-jumping (following a delta y curve)

Most prominent...

A C64 Game - Step 6

Posted by Endurion, 20 May 2011 · 1,404 views

And onwards we go: Obviously we don't want the player to move through walls. In this step we check the chars in the players way to see if they are blocking.

To make this easier we store the character pos and the character delta pos (0 to 7) for x and y for every sprite (SPRITE_CHAR_POS_X, SPRITE_CHAR_POS_X_DELTA). If the sprite is not at a character...

A C64 game - Step 5

Posted by Endurion, 14 May 2011 · 1,278 views

Our next big step:

Obviously we want some play screen, and more obviously, we are not going to store full screens (we've got only 64Kb Ram after all). Therefore there's a level build routine that allows to build a screen with various building elements. For now we'll start out with vertical and horizontal lines. Since we always have a level...

A C64 game - Step 4

Posted by Endurion, 07 May 2011 · 1,553 views

Now we take a bigger step: Moving the sprite with the joystick. Since we want to make a real game we also allow to move the sprite over to the right side (in other words we'll take care of the extended x bit).

For clarification: The C64 has 8 hardware sprites. That's 8 objects of the size 24 x 21 pixels. They can be placed anywhere. The...

A C64 game - Step 3

Posted by Endurion, 30 April 2011 · 1,601 views

Quite similar to step 2 this time we set up sprites. Note that I used another selfmade tool (similar to SpritePad). The file J.SPR contains the sprites and is included into the source as binary. The sprites are located "under" the I/O ROM at $D000 onwards.

And another note: Since I'm lazy I built the sprite copy loop to always copy...

A c64 game - Step 2

Posted by Endurion, in Uncategorized, C64 22 April 2011 · 2,802 views

And onwards we stumble!

In the first part we prepared everything for the VIC, now we set up our modified charset. Note that I used a selfmade tool (similar to CharPad), which is included (Windows binary). The file J.CHR contains the charset and is included into the source as binary. The memory layout of the game expects the modified charset at...

September 2014 »

2829 30     

Recent Entries

Recent Comments