Project 7: using functions for images and
moving things
Due: Monday
Dec 15th at 11:59pm
Summary:
In this project you will use dearpygui to draw stuff and move things.
Details:
For this project we will implement a game-like project that is similar to
the one my wife wanted students to make for some years:
For this project commit and push often! A
significant part of the credit will be assigned to seeing the changes of
your project over time. I will look at the commits and the
commit comments (so update you commit comments each time you commit and
push - and do that often)
You are a parent getting your child to the car after going to
<venue> (in her original it was the grocery store). You need to get
you and the child to the car safely and without crying.
The layout looks like this

And again a little while later

- The high level requirements:
- use keyboard navigation to move the child
- if one of the vehicles (trucks in mine) hits the child, you lose the
game
- if the child goes to the car without petting one of the dogs, the
child cries, you lose the game
- if the child pets the bear the child gets bitten, the child cries,
you lose the game
- if you make it to the car without the child getting hit or bitten
and manage to pet the dog - then you win at parenting, you win the
game
- More Details:
- the top level is the store, put a sign on the store and a door on
the store
- start the player at the door. (as per the top image)
- the bottom area is the parking area
- put your car in the parking area
- make sure the parking spots are marked/demarcated
- the second to the top area has vehicles moving along the road.
- there must be at least three vehicles
- the vehicles should move in one direction till they exit the
window, at which point the begin again from the other side of the
window
- the second to the bottom has vehicles moving along the road
- there must be at least three vehicles
- the vehicles here move in the opposite direction from those
previously mentioned
- the middle zone is the grassy median between the two road lanes
- there are two dogs here. They move back and forth across the
window, but don't leave, instead they move in the other direction
- you can use a single image, if the dog moves backwards that is
fine
- the dogs move together, maintaining a fixed distance apart.
- the single bear travels the length of the window and then moves in
the other direction.
- move the player using keyboard movement in the four cardinal
directions
- if the player loses, report this in big text on the window
- if the player wins report this in big text on the window
Feel free to use whatever images you want, but be sure to include them in
your github project.
For those who want to use some default images here
is a small zip file of images.
Of course put this into git and onto github sooner rather than later.
Additional requirements:
- Your code must be commented. you don't have to comment every line,
but you need to explain to me what you are doing in the code.
- You must use DearPyGUI,
- You cannot use classes - a feature we haven't used in this class.
- you must have at least 4 functions that you made and you call in your
code.
- you must call at least one of them by positional arguments
- and you must call one of your functions by keyword argument
- Again - commit and push often because the changes over
time will be a big part of the project grade.
Submission:
As with the previous project, to submit
the project to me, share it with me on github. My github id is jsantore.
You can see directions for doing this here.