[Solved] SOLVED:CSCI 210 Homework 3

30 $

File Name: SOLVED:CSCI_210_Homework_3.zip
File Size: 244.92 KB

SKU: [Solved] SOLVED:CSCI 210 Homework 3 Category: Tag:

Or Upload Your Assignment Here:


PurposeThis assignment focuses on:● Programming in Python● Using Pygame● Understanding event-handling in Pygame● Understanding using infinite loops in a gameThis is an individual assignment. You must work on your own. You may contact the instructor if youhave difficulty with the assignment. Start early so you may ask for help in class, if you run into anyproblems.AssignmentExtend the Tamagochi you created in Homework 2 by incorporating a game-like interface usingPygame. Create a loop which captures the user input, updates your Tamagochi’s state and renders theresulting state to the screen. Make sure to use the same keyboard input as was used in Homework 2(i.e., ‘F’ adds food, ‘T’ add or removes a toy, ‘Q’ quits the game). Note that you will not need toimplement the ‘N’othing command.Implementation of the game will have the following constraints:1. Make sure the game runs at 30 FPS maximum.2. Every frame, the Tamagochi looses 3 nutrition points. Nutrition will never go below 0.3. When food is added, set the amount of food to 1000 units. When the Tamagochi is eating,he/she consumes 5 units of food per frame (subtract this from the amount of food, and add it tonutrition). So, food should be completely consumed in roughly 6 seconds or so.4. Make sure each state is distinguishable with different sprites. Also, make sure that food andtoys are displayed with a sprite.5. Each state of the Tamagochi should be animated with at least two images. You can simply swapbetween the images every 15 frames or so (keep a variable with the number of frames untilswitching images, for instance).6. Place a background image in the game (rather than filling with black).You can simply copy over the functionality from Homework 2, rather than importing the file.Your program should be legible and easily understood. This includes ensuring that variable andfunction names reflect what the variable / function does, and appropriately commenting your code.Furthermore, your program must have the following comment header (or something equivalent):## Author:

Reviews

There are no reviews yet.

Only logged in customers who have purchased this product may leave a review.

Shopping Cart
[Solved] SOLVED:CSCI 210 Homework 3
30 $