Hello, if you have any need, please feel free to consult us, this is my wechat: wx91due
Assignment 11: Adventure Game
Pair Programming
Download the starter code from this shared folderLinks to an external site..
You may want to make a new project for this assignment to help you track and manage the different images or files you use, or to control access apartner has to your files - if you do, make sure to add a Python interpreter andadd Pygame to the project. You should copy and paste the files from thestarter code (or the folder) into your project (from your computer select the files or folder and copy, then go to PyCharm, click on the project name in theproject view, and paste).
You are to make an adventure game.
First, decide on a theme for the game. This will help you decide what the player character is, what the game characters are, and any challenges.
Write a brief description of the theme in a text file for submission as partof Assignment 11a. This should be a few sentences.
The game itself must have at least the following parts:
4. When a level finishes, a new level should be displayed, and the player can again move freely until a start is clicked.• Treat the new level as an independent game. Call pygame.init() and have a game loop.
• This difference must be in both images used and the kind of challenge. This means the code implementing it will also be different in style.
4. You can search online for images. Search something like "key image transparent background".
5. Many of you may want to animate something as a challenge. There are two main ways of moving things around. You can use a series of images, for example a guard with a large transparent border, and the guard shifts position within the image, and you cycle throughimages (and masks) like we did in lab. Or even a whole series of map images. Another approach is to move the rectangle for a guard. You can imagine choosing a position out of a long list of positions as one approach, also using the ideas from lab to cycle through positions. You can also consider moving in one direction until going too far, then using a variable to change it to moving back in another direction. Make sure to cite your sources if you use code or ideas from sources other than class and the Pygame documentation. Do some experiments in code to see if you can get something working before integrating it in the larger game.
• Having an idea you don't have a way to implement is not really a useful idea.
8. You do not need to restart at the current level when you fail (but you can). I would recommend starting at a higher level by editing the code when developing the game so you can skip doing the earlier levels when testing.
While this project uses some new concepts in making an interactive game, the real challenge lies in managing the complexity of the project. You will find that using good variables names helps to develop and debug your code. You may find that breaking the project into parts (for example, by level), can help you manage the complexity. A few comments to guide you as you insert more code may also help.
Implementation
In the provided code, there is a game.py which calls each level and then calls a loss screen if the player did not complete the level or calls a win screen if all three levels are completed. You may modify that file if you want more levels or if you want to restart a level upon a loss (for example, using a while loop). Read the code in that file to get a sense of the overall structure.
The game.py should be run to run the entire game.
You will likely need to modify the game and level files to initialize Pygame and create and use a window. You can add code to game.pyto make the screen and you can add parameters to the level functions to use the same screen.
You can also close a window at the conclusion of the level (pygame.quit()) and then in the next level or win/loss screen do another pygame.init() and make a window for the next level.
There are files for each level (level1, level2, level3) and for the win or loss display screens.
In each level file, add code to the level function to load images as needed and then have a complete Pygame game loop with event checking, game update, and drawing. If the player fails, return False. If the player completes the level, return True.
There is an example level 1 file that is not fully functional. It does not have thestart and end. It does return False if the door is touched. Build on the ideasin this example to make your own unique levels. Do not call this level in your completed game. Modify game.py to call your level1 function instead of this example function.
There is a display_win_or_loss.py file with two functions. Add a complete Pygame game loop in each function and use it to display a win orloss message.
Test each level independently by commenting out code in the game.py file.
When submitting, have a fully functional game.
Use good code style throughout. Add docstrings to functions you write. This project is likely a good place for one line comments in the level functions giving some guidance as to what is going on.
Due Dates
This is a larger project with a mid-project checkpoint.
Tuesday, December 3rd, 5:00PM - meet with a member of the course staff to get credit for Assignment 11a. See the description in Assignment 11a for details. You can submit up to one day late for a 10% penalty. After Wednesday, December 4th at 5:00PM there are no options to get credit for 11a.
Thursday, December 5th, 11:59PM - the project due date. Submit the project on Gradescope.
Saturday, December 7th, 11:59PM - a no penalty late submission due date. Submit the project on Gradescope.
There are no further late days with penalty after Saturday or any ability to use late passes (instead, everyone gets essentially a "free" late pass for this assignment). I am waiving the penalty and extending the late period, not making two round of late days. Please be aware that course staff does notwork over the weekend, so if you have a question or have trouble submitting over the weekend, you will not have support. Try to submit as early as possible to avoid such issues.
Since this assignment is due the last day of classes/course activities (except the final), there will be no opportunity for point recovery for thisassignment.
Make a short video showing a play-through and at least failing on one level. A voiceover is needed to help us understand what is going on. A reasonable way to make a video is to use Zoom and share your screen. Make sure that you share a screen to capture things like any popup windows - if you just share a window, other windows can be missed by the video capture. If you are a team, all of you must participate in making the video (at least by some division of voiceover duties).
If you have a partner, when you submit on Gradescope, one person willsubmit and add the partner to the submission through Gradescope. Youshould double-check your partner has added you to the submission if you arenot the submitter.