Skip to content
Snippets Groups Projects
Commit 2d35537b authored by Lama Amro's avatar Lama Amro :face_palm_tone3:
Browse files

Update Lama.md

parent e8d0cc97
No related branches found
No related tags found
No related merge requests found
...@@ -17,11 +17,12 @@ This made it easy for me to write good codes. I was following a coding method wh ...@@ -17,11 +17,12 @@ This made it easy for me to write good codes. I was following a coding method wh
I thought that keeping each code separate and dedicated to specific game objects is easier to understand and track these small functionalities. I thought that keeping each code separate and dedicated to specific game objects is easier to understand and track these small functionalities.
An example of a good code is the code responsible of the movement of the object, i started with just simple movement in one direction and i learned myself up to move in 3D. An example of a good code is the code responsible of the movement of the object, i started with just simple movement in one direction and i learned myself up to move in 3D.
![goodCode2](/uploads/c659757ae2d6916a9bccc8230597d8a2/goodCode2.png)
![goodCode2](/uploads/0536e87ce2f12a08e916ea86d804b319/goodCode2.png)
Also the Playscene code, as it was just small functions as portions in the main code, and i just assigned each portion to whatever buttin i need. Also the Playscene code, as it was just small functions as portions in the main code, and i just assigned each portion to whatever buttin i need.
![good_code_1](/uploads/f9a0e47a552165a05fb621ab1e6487c9/good_code_1.png) ![good_code_1](/uploads/d34a2cf68d60cd7e607748b9d3b4a5fd/good_code_1.png)
# Bad code # Bad code
Some of the codes i wrote were functioning but not in the way i wanted. Example of a bad code i wrote is the Markmine code, which marks a tile that has a mine under to avoid explosion. The marking opject's position depends on the character's position, which is hard to get it exactly in the centre of the tile, so the marking object does not alway appear in the perfect position to cover the tile. Some of the codes i wrote were functioning but not in the way i wanted. Example of a bad code i wrote is the Markmine code, which marks a tile that has a mine under to avoid explosion. The marking opject's position depends on the character's position, which is hard to get it exactly in the centre of the tile, so the marking object does not alway appear in the perfect position to cover the tile.
![badcode1](/uploads/fa9150a169598d99a63889b1d3d1de90/badcode1.png) ![badcode1](/uploads/fa9150a169598d99a63889b1d3d1de90/badcode1.png)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment