Frogger by GB Community & Ripper121

Advice on general approaches or feasibility and discussions about game design

Frogger by GB Community & Ripper121

Postby ripper121 » Mon Jun 23, 2014 1:50 pm

So the next game i like to create is frogger.
s_Frogger_1[1].png
Atari 2600 Frogger
s_Frogger_1[1].png (2.27 KiB) Viewed 6888 times


If someone like to help me, i need some graphics.
Frog, Cars, etc....


First test code with no output.
Code: Select all
//imports the SPI library (needed to communicate with Gamebuino's screen)
#include <SPI.h>
//importe the Gamebuino library
#include <Gamebuino.h>
//creates a Gamebuino object named gb
Gamebuino gb;


// Game constants
boolean paused = false;

//Game Speed
unsigned long prevTime = 0;                        // for gamedelay (ms)
int delayTime = 500;                               // Game step in ms

typedef struct
{
  char x;
  char y;
  byte w;
  byte h;
}  player;
player Frogg;

typedef struct
{
  char x;
  char y;
  byte w;
  byte h;
}  enemy;

void setup() {
  // initialize the Gamebuino object
  gb.begin();
  gb.startMenu(F("Frogger by Ripper121"));
  initGame();
}

void loop(void)
{
  if (gb.update()) {
    if (gb.buttons.pressed(BTN_C)) {
      paused = !paused; //toggle paused state
    }

    if (!paused) {

      if (gb.buttons.pressed(BTN_LEFT)) {
      }
      if (gb.buttons.pressed(BTN_RIGHT)) {
      }
      if (gb.buttons.pressed(BTN_UP)) {
      }
      if (gb.buttons.pressed(BTN_DOWN)) {
      }

      unsigned long currentTime = millis();
      if (currentTime - prevTime >= delayTime) {
        nextstep();
        prevTime = currentTime;
      }
    }
    draw();
  }
}

void initGame() {
  //Game Speed
  prevTime = 0;                        // for gamedelay (ms)
  delayTime = 200;                     // Game step in ms
  randomSeed(millis());

}



void draw() {
  gb.display.drawFastVLine(0, 0, LCDHEIGHT);
  gb.display.drawFastHLine(0, 0, LCDWIDTH);
  gb.display.drawFastVLine(LCDWIDTH-1, 0, LCDHEIGHT);
  gb.display.drawFastHLine(0, LCDHEIGHT-1, LCDWIDTH);
}

void nextstep() {}
Last edited by ripper121 on Thu Jun 26, 2014 12:51 pm, edited 1 time in total.
User avatar
ripper121
 
Posts: 224
Joined: Fri Apr 04, 2014 2:02 pm
Location: Germany

Re: Frogger by Ripper121

Postby treflip » Mon Jun 23, 2014 6:17 pm

How do I help? I like frogger.
treflip
 
Posts: 83
Joined: Fri May 30, 2014 4:50 pm
Location: Florida

Re: Frogger by Ripper121

Postby treflip » Mon Jun 23, 2014 6:37 pm

Will these work? I just did them during lunch.
Image
Last edited by treflip on Tue Jun 24, 2014 1:56 pm, edited 1 time in total.
treflip
 
Posts: 83
Joined: Fri May 30, 2014 4:50 pm
Location: Florida

Re: Frogger by Ripper121

Postby Drakker » Mon Jun 23, 2014 8:44 pm

Almost 16x16 is waaay too big... the screen is 48 px high. Do you plan to scroll the screen once the frog reaches the river? If so, maybe the cars could be something like 6x6 or 8x6.
User avatar
Drakker
 
Posts: 297
Joined: Sun Mar 30, 2014 2:54 am
Location: Québec, Canada

Re: Frogger by Ripper121

Postby treflip » Mon Jun 23, 2014 8:51 pm

Ahh, that makes sense. I thought I read somewhere someone said 16x16 is good for sprites. I'll have to adjust it later today for 8x8 or something proportional to the road. Also I was thinking of making the automobiles white if the road will be black??? Thanks!
treflip
 
Posts: 83
Joined: Fri May 30, 2014 4:50 pm
Location: Florida

Re: Frogger by Ripper121

Postby ripper121 » Mon Jun 23, 2014 9:34 pm

It can also 8x10 or 5x6 pixel ;).
Black is good the road is white.
Thanks for your help :)
User avatar
ripper121
 
Posts: 224
Joined: Fri Apr 04, 2014 2:02 pm
Location: Germany

Re: Frogger by Ripper121

Postby treflip » Mon Jun 23, 2014 9:48 pm

No problem. I need to start somewhere!

Here's the dimensions I am thinking for my parameters.
Image

The white is for measuring: Inside the grey area is 84 x 48 - so the top green is 5 pixels tall for the landing across after passing over the logs; the water is 25 pixels tall; the road is 20 pixels tall - which breaks into three lanes (6 pixels ea.) and takes about two hops per lane to get across. The cars are like Drakkar said 4 x 6.

Let me know if this is good and I'll finish up the cars/logs, spiders, tomorrow during lunch!
treflip
 
Posts: 83
Joined: Fri May 30, 2014 4:50 pm
Location: Florida

Re: Frogger by Ripper121

Postby ripper121 » Mon Jun 23, 2014 10:02 pm

Yes looks great.
Pleas only black and white, grey is at the moment no so well
User avatar
ripper121
 
Posts: 224
Joined: Fri Apr 04, 2014 2:02 pm
Location: Germany

Re: Frogger by Ripper121

Postby treflip » Tue Jun 24, 2014 3:13 pm

Ok, the colored window was just to differentiate between the segments easier. Here's what it will actually look like.
Image

and here should be the images for cars, logs, flowers, alligators.
Image

Notes:
The cars move one way on the outer lanes and the opposite way in the middle.
The alligators have 4 images for moving the mouth and loop back to the first.
....The first alligator image is for when the frog needs to jump across quickly and won't kill it but the other 3 will.
The misc images on the right are flowers.
The bottom right img's are the frog. The middle blinks so the player can reference where it is quicker.


Not sure if the frog size will be an issue with the flowers let me know if it needs a little tweaking and I'll get it fixed.
Last edited by treflip on Tue Jun 24, 2014 3:30 pm, edited 1 time in total.
treflip
 
Posts: 83
Joined: Fri May 30, 2014 4:50 pm
Location: Florida

Re: Frogger by Ripper121

Postby rodot » Tue Jun 24, 2014 3:27 pm

You can attach images to your post and insert them inline, so please don't host them somewhere else. Your links are broken.
User avatar
rodot
Site Admin
 
Posts: 1290
Joined: Mon Nov 19, 2012 11:54 pm
Location: France

Next

Return to Project Guidance & Game development

Who is online

Users browsing this forum: No registered users and 102 guests

cron