Our Services

Get 15% Discount on your First Order

[rank_math_breadcrumb]

(lab) Slide and Catch Game Part IIStart Assignment Points 100Submitting a text entry box, a website url, or a file uploadOverview This week’s project is an extension of the one from last week. You

(lab) Slide and Catch Game Part IIStart Assignment

  • Points 100
  • Submitting a text entry box, a website url, or a file upload

Overview

This week’s project is an extension of the one from last week. 

You should already have a project with the following features:

  • A subclassed Scene for game play
  • An avatar sprite controlled by the user
  • User sprite will move in X or Y axis
  • Use keyboard input to change sprite position
  • At least one target sprite
  • Target sprite is computer controlled
  • It can move from top to bottom of screen
  • Behavior should be somewhat randomized
  • All sprites should consider boundary checking
  • There should be a test for collision between player sprite and target sprites
  • You should have a sound effect in place for handling collisions.

If you did not turn in a game with these features last week, we will provide you with a starting place template you can work with so you won’t fall too far behind

Gameplay labels

The game needs to have some kind of goals and obstacles.  It’s important to explain this to the user so she knows what to do.  We’ll do that in two ways.  First, we’ll add feedback to the game screen. This will allow us to keep track of points, and will also allow us to place a countdown timer on the screen.  Here’s the steps

  • Create a label for showing the score.  Get this label to appear on the game play screen
  • Create an attribute for the game class called score.  Initialize this value to zero.
  • When a collision between the player and target happens, increment the score
  • Make sure the label is always showing the current score
  • When scorekeeping is working, add a second label for the timer
  • Make sure this label is appearing where you want on the screen
  • NOTE: because the timer label will need to update every frame, you may want this to be a subclass of the Label.
  • Add a timer to manage the time
  • Set the timer’s totalTime to the default length so you can easily make a countdown timer
  • Display the timer’s getTimeLeft() value in the label
  • When your specified time limit is over, end the game (scene.stop() could be useful here)
  • Note that you’ll drive yourself crazy testing a game that lasts for 5 minutes each time
  • There’s a reason my examples last for only ten seconds
  • You can always change the time limit later

Adding a state system

The next part of the process is to create a state system.  You’ll need to create a second scene to be the introduction scene. This will have the following features

  • A multilabel containing instructions for game play
  • A label containing the last score
  • A button to play the game
  • A second button to exit the game

Both buttons should stop the scene.  At this point we aren’t worried about how to get the previous score.

Test your new scene in main.  Instantiate and start the intro screen, then instantiate and start the game scene.  At this point you will see the instructions, then the gameplay, and then the entire game will end.

Add a status attribute to the Intro class.  Now modify the buttons so they still both exit the game, but report a different status (play or exit)

Modify your main function to have a standard keepGoing loop. 

Inside the loop, play the intro scene, and then use the status to determine whether you play the game or exit the loop

Modify the Intro scene’s constructor to take a score value in the constructor.  

Modify the main loop so the score from the game is passed to the Intro screen on each pass.

The Game Design Document

You started the game design document last week, but to get to all this new content, you’ll need to make your document more complete.  At this point it should include:

  • Some kind of diagram of game play
  • Label each sprite on the screen indicating what class it will be
  • For each sprite:
    • What image are you hoping to have here?  What’s its size?
    • Is it a standard sprite or custom? Can it be BasicSprite or SuperSprite?
    • How is the sprite born?  Does it die?  How?
    • How does the sprite move? Is it under user or computer control?
    • What specific motion mechanics do you expect?
    • What happens when this sprite leaves the stage?
    • What happens when this sprite collides with any other sprite on the screen?
  • UI
    • How will you explain the game before gameplay begins?
    • What feedback will you give during game play?
    • What UI components will you need?
    • How will they be updated with necessary information?
    • Where will they go on the screen?
  • Game State
    • What are the game states?
    • How do you transfer between them?
    • How do you communicate any needed information between states?
    • How does the entire game eventually end?
  • Sound effects
    • What sound effects do you need?
    • You can record them yourself if you can’t find something good
    • When will the sound effect play?
    • Where is the best place in code for the sound effect to be coded?
  • Background image
    • Will you have a background image?
    • Where will it come from?
    • Can you still see all the gameplay elements clearly?
  • Intellectual property
    • List where each image or sound effect came from
    • If it is original, that’s all you need to say
    • If it is open-source or creative commons, still link the source
    • If it is copyrighted, get something else
    • Placeholder values are fine.

Expectations

I have given you plenty of examples to start with.  If you’re getting lost, please review the videos and examples, especially these:

  • Your first game code examplesLinks to an external site.
  • milestones 1-3 videoLinks to an external site.
  • milestones 4-6 videoLinks to an external site.
  • milestones 7-8 videoLinks to an external site.

You’ll get a better grade by having excellent documentation and adding to the core in some creative ways.  Try to build your own game with your own dynamics.  It’s fine if you don’t get the gameplay perfect on this go-around.  Build a foundation you can build on with all the main mechanics in place. Have Fun!

Share This Post

Email
WhatsApp
Facebook
Twitter
LinkedIn
Pinterest
Reddit

Order a Similar Paper and get 15% Discount on your First Order

Related Questions

TNM1 — Task 2: Multipage Website Prototype Competencies 4040.01.1 : User Interface Design Projects The graduate describes user interface design project constructs. 4040.01.2 : User Interface Design Pr

TNM1 — Task 2: Multipage Website Prototype Competencies 4040.01.1 : User Interface Design Projects The graduate describes user interface design project constructs. 4040.01.2 : User Interface Design Process The graduate describes the user interface design process. 4040.01.3 : User Centered Web Design The graduate explains the relationship between the user and the site design. 4040.01.4 : User Interface

IntroductionUser interface and user experience (UI/UX) designer is one of the most popular job titles in the technology industry. UI/UX designers tend to enjoy the challenges associated with creating

IntroductionUser interface and user experience (UI/UX) designer is one of the most popular job titles in the technology industry. UI/UX designers tend to enjoy the challenges associated with creating products that people love. Industry leaders know that design is a substantial competitive advantage, and they are competing for best talents;

In Units V, VI, and VII, you learned about the components of a computer, how a computer works, the internet, networks and network communications, cloud computing, web development, digital identity, so

In Units V, VI, and VII, you learned about the components of a computer, how a computer works, the internet, networks and network communications, cloud computing, web development, digital identity, social media, e-commerce, ethical behavior, databases, and explored two Microsoft Office applications, PowerPoint and Access.  In this assignment, you will

In the previous assignment, the annotated bibliography, you collected 15 – 20 references. Now, you are to craft an analytical research paper. Using the same themes assigned for the previous assignment

In the previous assignment, the annotated bibliography, you collected 15 – 20 references. Now, you are to craft an analytical research paper. Using the same themes assigned for the previous assignment.  GROUP 1: Context-Aware Computing  Prepare a ten (10) page research paper. In the paper, you are to cover the

This week, you will submit the second project, the Desktop Migration Proposal. Using the requirements analysis your manager provided and the Internet research you conducted, submit your recommendation

This week, you will submit the second project, the Desktop Migration Proposal. Using the requirements analysis your manager provided and the Internet research you conducted, submit your recommendation to the assignment folder. As you are writing your recommendation, ensure your analysis and recommendations align with your manager’s priorities and concerns.

In Units I, II, and III, you learned about the history of computers, application and system software, blockchain, cryptocurrency, computer ethics, and explored two Microsoft Office applications, Word

In Units I, II, and III, you learned about the history of computers, application and system software, blockchain, cryptocurrency, computer ethics, and explored two Microsoft Office applications, Word and Excel.  In this assignment you will demonstrate what you have learned in these three units. This assignment will have five parts. 

Research and brainstorm three (3) proposals for a mobile computing solution. Write up a half-page (double-spaced, approx. 250 words) description of each mobile computing solution proposal. Provide an

Research and brainstorm three (3) proposals for a mobile computing solution.  Write up a half-page (double-spaced, approx. 250 words) description of each mobile computing solution proposal. Provide answers to the following questions: 1) What is the 1 sentence summary of the mobile computing solution? 2) Who and how big is

Creating and Submitting your Portfolio Overview Creating a professional cybersecurity portfolio is essential for showcasing your skills, achievements, and growth. This portfolio will serve as a valuab

Creating and Submitting your Portfolio Overview Creating a professional cybersecurity portfolio is essential for showcasing your skills, achievements, and growth. This portfolio will serve as a valuable tool for presenting yourself to universities, scholarship committees, employers, and beyond. Objective:: To design a professional cybersecurity portfolio that markets your academic and

IntroductionFor this project, you will create a personal portfolio website to demonstrate your ability to use HTML, CSS, and JavaScript and resolve software problems in web development environments. Y

IntroductionFor this project, you will create a personal portfolio website to demonstrate your ability to use HTML, CSS, and JavaScript and resolve software problems in web development environments. You will create three HTML pages: a résumé, a cover letter, and a career goals page. As you make your website, you

IntroductionFor this project, you will create a personal portfolio website to demonstrate your ability to use HTML, CSS, and JavaScript and resolve software problems in web development environments. Y

IntroductionFor this project, you will create a personal portfolio website to demonstrate your ability to use HTML, CSS, and JavaScript and resolve software problems in web development environments. You will create three HTML pages: a résumé, a cover letter, and a career goals page. As you make your website, you

Need to report 1 You will submit two reports generated from your developed database. These reports should be meaningful to your database. The report(s) resolve one of the problems that you originally

Need to report 1 You will submit two reports generated from your developed database. These reports should be meaningful to your database. The report(s) resolve one of the problems that you originally identified in your Database Proposal.  The lay out should be appealing to the eye and the design should

Select any example visualization or infographic and imagine the contextual factors have changed: If the selected project was a static work, what ideas do you have for potentially making it usefully in

Select any example visualization or infographic and imagine the contextual factors have changed: If the selected project was a static work, what ideas do you have for potentially making it usefully interactive? How might you approach the design if it had to work on both mobile/tablet and desktop? If the

Excel 365/2021 Capstone – Level 2 Working with Sales Data These instructions are compatible with both Microsoft Windows and Mac operating systems. In this project, you will work with sales data from T

Excel 365/2021 Capstone – Level 2 Working with Sales Data These instructions are compatible with both Microsoft Windows and Mac operating systems. In this project, you will work with sales data from Top’t Corn, a popcorn company with an online store, multiple food trucks, and two retail stores. You will