![]() fill(( 0, 0, 0)) #clears screen with black If currentScreen != "lose": #if the player is not losing #FUNCTION TO HANDLE LOGIC AND DRAW SCENE EVERY FRAMEĭef drawScene( zombiesList, plantsActionList, bulletsList, plantsRechargeList, shovellingPlant, selectingPlant, sunAmount, plant, currentScreen, loseX): #user can change to different screens though clicking buttons on the menu or losing in the main game. #contains many other while running loops, and the currentScreen of the game determines which while loop to run what aspect of the game (menu, help, main game screen). we use other functions in the while running loop of the game as well, such as checking if user clicked on a sun.the game runs on a main while loop that #colliding with a lawnmower and if a lawnmower is moving across the screen, if player is currently losing, and we over all draw the entire scene using the drawScene #to stop selecting or shovelling the plant, if bullet is hitting a zombie,if zombie is eating a plant and to reduce the plant's health if is is, if zombie is #update the position of the zombies and bullets every frame, as well as check if user is placing or selecting a plant, if user right clicks #all the main functions to fun the game are mostly called from the drawScene function we animate the sprites of the zombies and plants and ![]() the goal of this game is to try to survive for as many waves as possible ![]() #with a timer and you have to use diff plants to try to defeat them. #using sun currency which you get from planting sunflowers or from it falling from the sky due to a timer game is played with a mouse only waves of zombies will be spawned #this goal of this game is to plant a variety of plants on the field to defend your house from the incoming zombies you purchase plants #FSE Game - Plants vs Zombies - Phillip Pham (Period 9) - Grade 11 ![]()
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |