KID'S FIRST GAME.

4

  • 13
  • 0
  • 0.068
  • Reply

  • Open in the desktop app ADD TO PLAYLIST

    adoore-eu

    Published on Aug 09, 2023
    About :

    The kids holiday is still running.
    They want to travel but I told them to sit back and do something useful. Visiting Grandma is something worthwhile but with the fuel problem in Nigeria and the high cost of living I decided they shouldn't bother, instead they should learn new skills, maybe, coding skills.

    The idea of the game was for the kids to learn coding skills using what they love. They love to play by games. If they can also learn how to develop it, it's not bad.

    Now this is is a simple game. Just with a few sprites.
    There is a farm at the background, a player-controlled plane with bullets stuck in it, an enemy at the farm , a timer and a score display.

    var farm = createSprite(200, 200);
    farm.setAnimation("farm");

    var fighter = createSprite(200, 325);
    fighter.setAnimation("fighter");
    fighter.scale = 0.3;

    var bullet = createSprite(186, 90);
    bullet.setAnimation("bullet");

    var plane = createSprite(164, 50);
    plane.setAnimation("plane");
    plane.rotation = 180;

    ABOUT THE GAME

    The code was done on studio.code.org which uses a sprite based system for animations

    From the above codes, the sprites have been assigned their storage locations and the respective sprites will display animations representing farm scene, a plane and bullet, and a fighter. The plane too was rotated to 180 degrees.

    Initially, the game was good to be called Boko fighter. As if someone was in a plane fighting back at the Bokoharam 😅 for all the evil works they have perpetuated for such a long time.

    However, the name scared the kids so I told them we shall change it to Sky rescue , Winged wonders or the like, just to make them comfortable to join and learn.

    function draw() {
    if (keyDown("right")) {
    plane.x = plane.x + 5;
    }

    if (keyDown("left")) {
    plane.x = plane.x - 5;
    }

    if (keyDown("space")) {
    bullet.x = plane.x + 22;
    bullet.y = plane.y + 8;
    bullet.velocityY = 40;

    if (timer > 45) {
      fighter.x = randomNumber(10, 380);
      fighter.y = randomNumber(270, 380);
      timer = 0;
    }
    
    timer = timer + 1;
    
    if (bullet.isTouching(fighter)) {
      scores = scores + 1;
    }
    

    It is just a simple game. The player controls the game with just three keys on the keyboard.

    Left Arrow Key-- This is used to control the plane to move towards the left as the fighter moves in that direction and then shoot with the space bar key.

    Right Arrow Key-- This is used to control the plane to move to the right direction as the fighter as he jumps to the right and then shoot.

    Space Bar- This is used to release bullets on the fighter in quick succession before it jumps randomly ( in all direction)

    Each time the bullet sprite touches the fighter, the player's score increases

    The timer waits for no one. It counts and ends in 60seconds. the number of times the bullet hits the target is displayed on the screen as the score.

    If the game runs for about 60seconds, it displays "game over" and the name of the owner displays as well on the screen.( I made it 60sec so that those who try it may may not waste so much time and resource to check it out.

    drawSprites();

    textSize(20);
    text("Scores: " + scores, 30, 30);
    text("Time: " + World.seconds, 320, 30);
    
    if (World.seconds > 20) {
      background("white");
      text("GAME OVER\nYou killed: " + scores, 70, 200);
      text("This game was designed by Adore", 60, 250);
    }
    

    )

    We are still learning, this is just a simple game for kids, just to teach them fundamentals of coding.

    VIDEO

    An accompanying video is uploaded where I explained how different parameters were used and variable names assigned.

    If statement was also used which allows certain instructions to be executed if the criteria are met, but if not met, it jumps to another line of instruction to continue.

    The kids were happy to see a game they joined to create. They are happy to play.

    ![]()

    Thank you so much for your visit and encouragement. As you watch the video, please do not mind the sound of the external keyboard. We time, the kids will learn how to add sounds as the bullet hits.

    Disclaimer: This is not a violent game, the idea of coding is what the kids are learning. Can you try playing my kid"s game and critic it?

    Here is the link.
    The idea of the game can be same for a hunter shooting birds if you like.

    Thanks again for the visit.

    Together, the team hope to bring you more games when possible.😃

    Yours Adore.

    All the images and game are mine. Sprites used for the game are animations from studio.code.org

    Tags :

    Woo! This creator can upvote comments using 3speak's stake today because they are a top performing creator! Leave a quality comment relating to their content and you could receive an upvote worth at least a dollar.

    Their limit for today is $0!
    Comments:
    Time until adoore-eu can give away $0 to their commenters.
    0 Days 0 Hours 0 Minutes 0 Seconds
    Reply:

    To comment on this video please connect a HIVE account to your profile: Connect HIVE Account

    More Videos

    01:10
    5 views 3 years ago $
    08:11
    8 views 2 years ago $
    04:18
    3 views 2 years ago $
    00:10
    4 views 2 years ago $
    01:03
    0 views 4 years ago $