+ 8

What should i learn in Python before learning pygame?

And is it possible to use pygame in android?

8th Oct 2020, 4:49 PM
‎Keshav
‎Keshav - avatar
26 Answers
0
Hello Pygame is basically a set of functions in a class which do different stuff. If you understand Python well, all you have to do is call those functions depending on what you want to draw. I would suggest going through the pygame documentation to understand what every function does. You don't need to memorize them - no one can. Just know that those are set of labels which tell us what each stuff does. Also, watch some tutorials to get a better idea. Again, you need to be good at Python otherwise you are going to have trouble using pygame. I really highly recommend it. Took it this past summer, and it was a blast. You start off with a very basic text game, rock-paper-scissors-lizard-spock, and then get introduced to a custom simple GUI package to build visual games. 8 week course, and all the weekly assignments are games. You work up through building a stopwatch, a memory game, Blackjack, a very basic Pong type game, and then culminate in a simple space shooter game where you work with sprites and sound effects. You also learn OOP along the way, which is cool. The level is also "just right." At the end, they point you toward other resources for further development, including the Pygame package others mentioned. I hope this will help to you
19th Oct 2020, 4:02 AM
Ishan Shah
Ishan Shah - avatar
+ 6
Learn the Python basics first. E.g. Python tutorial on Sololearn.
9th Oct 2020, 1:13 AM
Sonic
Sonic - avatar
+ 4
Akbar thanks 😄
8th Oct 2020, 4:57 PM
‎Keshav
‎Keshav - avatar
+ 3
Çrèàtìvè Sàt what is turtle? Is it some kind of library
10th Oct 2020, 2:18 PM
‎Keshav
‎Keshav - avatar
+ 2
Martin Taylor I'm not learning Python from Sololearn I'm studying on my own like reading books. So don't consider my profile i don't learn Python on Sololearn. I have covered almost the basics of the Python that's why i asked this question. Thanks
10th Oct 2020, 2:17 PM
‎Keshav
‎Keshav - avatar
+ 2
Çrèàtìvè Sàt as you mentioned turtle now i remembered that someone on GitHub posted a code in which some "automatic" drawings were made. Maybe that's what turtle is.
10th Oct 2020, 2:24 PM
‎Keshav
‎Keshav - avatar
+ 2
And that code seems very simple if i understand the functions of turtle
10th Oct 2020, 2:26 PM
‎Keshav
‎Keshav - avatar
+ 2
🐢 See some tutorials on YouTube for clarification You can edit this Example for turtle . This the simple program in and it is very easy to understand https://code.sololearn.com/c7SiWM11ID5R/?ref=app 🐢
10th Oct 2020, 2:26 PM
Çrèàtìvè Sàt
Çrèàtìvè Sàt - avatar
+ 1
Martin Taylor i have almost covered the basics now i wants to learn something different. Like pygame or Django
10th Oct 2020, 3:50 AM
‎Keshav
‎Keshav - avatar
+ 1
I would suggest "turtle" 🐢
10th Oct 2020, 10:17 AM
Çrèàtìvè Sàt
Çrèàtìvè Sàt - avatar
+ 1
Yes, “Turtle” is a python module which is like a drawing board, which lets you command a turtle to draw all over it! You can use functions like turtle. forward(...) and turtle. left(...) which can move the turtle around. Before you can use turtle, you have to import it.
10th Oct 2020, 2:21 PM
Çrèàtìvè Sàt
Çrèàtìvè Sàt - avatar
+ 1
Turtle is used for graphics
10th Oct 2020, 2:21 PM
Çrèàtìvè Sàt
Çrèàtìvè Sàt - avatar
+ 1
And it is very beginner friendly
10th Oct 2020, 2:22 PM
Çrèàtìvè Sàt
Çrèàtìvè Sàt - avatar
+ 1
Use repl.it a online editor for turtle
10th Oct 2020, 2:29 PM
Çrèàtìvè Sàt
Çrèàtìvè Sàt - avatar
+ 1
See the turtle documentation by python here https://docs.python.org/3/library/turtle.html
10th Oct 2020, 2:31 PM
Çrèàtìvè Sàt
Çrèàtìvè Sàt - avatar
+ 1
Yes
10th Oct 2020, 2:32 PM
Çrèàtìvè Sàt
Çrèàtìvè Sàt - avatar
+ 1
When you run the code it will draw something in a white board (a screen)
10th Oct 2020, 2:33 PM
Çrèàtìvè Sàt
Çrèàtìvè Sàt - avatar
10th Oct 2020, 2:36 PM
‎Keshav
‎Keshav - avatar
+ 1
Yes, paste the lines of code in repl.it in browser to see the effect . Its simple
10th Oct 2020, 2:39 PM
Çrèàtìvè Sàt
Çrèàtìvè Sàt - avatar
+ 1
Ishan Shah thanks bhai But which course are you talking about?
19th Oct 2020, 4:06 AM
‎Keshav
‎Keshav - avatar