# Need help to make very simple game

**URL:** https://discourse.processing.org/t/need-help-to-make-very-simple-game/21857
**Category:** Coding Questions
**Tags:** homework
**Created:** [June 14, 2020, 6:08am UTC](https://discourse.processing.org/t/need-help-to-make-very-simple-game/21857 "2020-06-14T06:08:18Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![malik2712](https://avatars.discourse-cdn.com/v4/letter/m/82dd89/32.png) [@malik2712](https://discourse.processing.org/u/malik2712)
#### Post date: [June 14, 2020, 6:08am UTC](https://discourse.processing.org/t/need-help-to-make-very-simple-game/21857/1 "2020-06-14T06:08:19Z")

</div>

> please format code with \</\> button \* [homework policy](https://discourse.processing.org/faq/#homework) \* [asking questions](https://discourse.processing.org/t/2147)

I just need code made to run that game in processing It’s for an assessment due tomorrow I need to make a little game in the coding app processing I need some to write me a code for such game

Game Specifications :

1. At the start of the game - Emoji is having a sad face ☹, as it runs out of the toilet paper rolls, so it has to start his chase for the toilet paper roll.
2. Lane/section design - There is a maze with three (3) horizontal sections/lanes( top, middle, and bottom) on the screen filled with three different colours. In this assignment, we will only work on top and bottom lanes. We will do the middle lane/ section game logic in Assignment3.
3. Visual colour effect- The colours of the horizontal sections/ lanes are changing at the constant speed/rate.
4. Emoji (sad face ) enters the top horizontal lane from the left side of the screen. He enters and then runs at a certain speed/ rate on a horizontal path and should bounce back from the boundary of the lane.
5. Toilet paper roll – only one roll of the toilet paper is available and is placed at a random location within the top horizontal section of the maze. The toilet paper roll also runs at a certain speed/rate in any direction ( you prefer) and when it touches the boundary of the lane, it should bounce and get placed at random (x, y) location in the lane and start moving again. The speed/ rate of the toilet paper roll remains the same in the program, you can’t increase or decrease the speed/rate of the toilet paper roll.
6. Emoji Movements – At the start of the game the mousePressed event is disabled and you are allowed to use only the keyPressed events to move the emoji ( sad face ) up, down, left, right( feel free to use any key for the event) but after 15 keyPressed events, the mousePressed event gets activated and remains activated for the rest of the game. MousePressed event puts the emoji at the mouse pressed location.
7. Count the keyPressed event- Each key pressed event is counted and the count is displayed in the left corner of the third/bottom horizontal section/lane. Also, you are required to display a message to inform the player, when the mousePressed event gets activated like- “Mouse event is activated now” which is after 15 counts of keyPressed event( Step 6).
8. Catch the roll –Emoji catches the roll when he collides with the roll.
9. Game end– When Emoji catches the roll, he becomes one little smiling face😊 ( change the sad face of the Emoji to one smiling face). Emoji and toilet paper roll stop  
moving.

 ![image](https://canada1.discourse-cdn.com/flex036/uploads/processingfoundation1/original/2X/8/82a6291b0d5b5a57eb753fb46ce63d1812647b15.jpeg)

---

<div class="post-metadata">

### Author: ![TfGuy44](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/tfguy44/32/41_2.png) [@TfGuy44](https://discourse.processing.org/u/TfGuy44)
#### Post date: [June 14, 2020, 7:32am UTC](https://discourse.processing.org/t/need-help-to-make-very-simple-game/21857/2 "2020-06-14T07:32:13Z")

</div>

And what code have you written for it so far?

---

<div class="post-metadata">

### Author: ![malik2712](https://avatars.discourse-cdn.com/v4/letter/m/82dd89/32.png) [@malik2712](https://discourse.processing.org/u/malik2712)
#### Post date: [June 14, 2020, 9:35am UTC](https://discourse.processing.org/t/need-help-to-make-very-simple-game/21857/3 "2020-06-14T09:35:46Z")

</div>

I don’t know how to start

---

<div class="post-metadata">

### Author: ![debxyz](https://avatars.discourse-cdn.com/v4/letter/d/58956e/32.png) [@debxyz](https://discourse.processing.org/u/debxyz)
#### Post date: [June 14, 2020, 12:30pm UTC](https://discourse.processing.org/t/need-help-to-make-very-simple-game/21857/4 "2020-06-14T12:30:34Z")

</div>

Hello @malik2712

Just to clarify, you don’t know how to set up the base structure of:

the setup and draw functions, and, declare and initialize the variables?

---

<div class="post-metadata">

### Author: ![glv](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/glv/32/18785_2.png) [@glv](https://discourse.processing.org/u/glv)
#### Post date: [June 14, 2020, 2:38pm UTC](https://discourse.processing.org/t/need-help-to-make-very-simple-game/21857/5 "2020-06-14T14:38:53Z")

</div>

> [@malik2712](#):
>
> don’t know how to start

One of the best tools in a programmers tool chest is knowing the resources available to you and learning to navigate and use them.

This is a very short list:

> **Resources \< Click here to expand !**
>
> I encourage you to review the resources available here:
> 
> - The Processing _website_ has references, examples, tutorials, etc.  
> [https://processing.org/](https://processing.org/)
> - The Processing PDE (IDE) has lots to offer!  
> An exploration of the tabs will reveal what is available; libraries, tools and local examples there.
> - The Coding Train  
> [https://www.youtube.com/channel/UCvjgXvBlbQiydffZU7m1\_aw](https://www.youtube.com/channel/UCvjgXvBlbQiydffZU7m1_aw)  
> [https://thecodingtrain.com/](https://thecodingtrain.com/)
> - Happy Coding  
> [Processing Tutorials - Happy Coding](https://happycoding.io/tutorials/processing/)
> - The source code can give insight if you are adventurous:  
> [GitHub - processing/processing: Source code for the Processing Core and Development Environment (PDE)](https://github.com/processing/processing)  
> Many of the Processing functions are here:  
> [processing/core/src/processing/core/PApplet.java at master · processing/processing · GitHub](https://github.com/processing/processing/blob/master/core/src/processing/core/PApplet.java)
> - The Processing Foundation  
> [https://processingfoundation.org/](https://processingfoundation.org/)  
> Check out the tabs.  
> In the education tab, there is a reference to the Coding Train.
> - And the Internet. `:)`

`:)`

---

<div class="post-metadata">

### Author: ![paulgoux](https://avatars.discourse-cdn.com/v4/letter/p/b9bd4f/32.png) [@paulgoux](https://discourse.processing.org/u/paulgoux)
#### Post date: [June 14, 2020, 3:18pm UTC](https://discourse.processing.org/t/need-help-to-make-very-simple-game/21857/6 "2020-06-14T15:18:18Z")

</div>

asking for help whilst providing no code!! is like saying.

![tenor](https://canada1.discourse-cdn.com/flex036/uploads/processingfoundation1/original/2X/6/6092a484f86cc4d778634d2e5d3aa9828eb67f4a.gif)
