Skip to content

Commit 575ba69

Browse files
committed
added 'what-is-pygame' page
1 parent e9a2f9d commit 575ba69

File tree

5 files changed

+95
-4
lines changed

5 files changed

+95
-4
lines changed

guide/intro/chapter-1/index.html

Lines changed: 82 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,85 @@
44
next_page: [/guide/intro/chapter-2, Opening A Window]
55
---
66

7-
<body></body>
7+
<body>
8+
<p>In this article, we'll go over what pygame is and how to install it.</p>
9+
10+
<h2>Table of contents</h2>
11+
<p></p>
12+
<ol id="toc">
13+
<!--
14+
To be filled by javascript
15+
-->
16+
</ol>
17+
18+
<h2><a id="introduction" class="js">Introduction</a></h2>
19+
<p>
20+
It's time to get started on your pygame journey, but what is pygame? Well
21+
pygame is "a free and open-source cross-platform library for the development
22+
of multimedia applications like video games using Python". As the
23+
description suggests, it's mostly used to make video games - which is why in
24+
this book we'll be learning techniques relevant to making games
25+
</p>
26+
27+
<p>
28+
Pygame provides the very basic utility to draw and manipulate pixels on to
29+
the screen, much like <a href="https://www.libsdl.org/">SDL2</a>, but with
30+
extended features in various forms that makes it easier to use. Given this
31+
nature, you generally have a lot of control on how you want your code to
32+
run, so it may have a bit of a learning curve. But fear not! After reading
33+
this book you should be able to use pygame just fine, as long as you get
34+
your practice in 🔫
35+
</p>
36+
37+
<p>
38+
In this book we'll aim to cover how to do basic things with pygame, with
39+
little exercises in between to make sure you're not falling off, goodluck
40+
</p>
41+
42+
<h2><a id="pygame-ce" class="js">Pygame-CE</a></h2>
43+
<p>
44+
So pygame currently has two major distributors, the original one and a fork
45+
of the project. What is a fork? Well it means it's a copy of the project, and
46+
in this case they branched off to be two completely separate packages now.
47+
</p>
48+
<p>
49+
<a href="https://github.com/pygame-community/pygame-ce">pygame-ce</a> is the
50+
fork of the original pygame, which got created due to all the active
51+
developers of the original project being banned by the "owner". Well,
52+
pygame-ce has no "owner", it follows a more democratic approach to managing
53+
itself now.
54+
</p>
55+
<p>
56+
So what happened to all the active developers of the original pygame? They
57+
formed pygame-ce! That's right, so pygame-ce is being developed by the same
58+
people (and more) as the original pygame, and with a more democratic model
59+
have been able to push releases way more easily and introduce many more
60+
features.
61+
</p>
62+
<p>
63+
For all sane purposes, we will be using <code>pygame-ce</code> in this book
64+
and we advise the same. It has had more performance improvements, code
65+
features, and active development than the original pygame for a while now. It
66+
is recommended to use only <code>pygame-ce</code> from now onwards by most
67+
Python communities.
68+
</p>
69+
70+
<h2><a id="installation" class="js">Installation</a></h2>
71+
<p>
72+
Now that you know what pygame-ce is, let's install it.
73+
74+
{% highlight python %}
75+
pip uninstall pygame
76+
pip install pygame-ce
77+
{% endhighlight %}
78+
In order for pygame-ce to work, pygame needs to be uninstalled first.
79+
This is because both upstream pygame and pygame-ce share the import name,
80+
and so upstream pygame must be removed <u>first</u>.
81+
</p>
82+
<p>
83+
I simply included it as the first step in order to install pygame-ce in a foolproof manner with no issues,
84+
but I must remind you that a pre-requisite of using this site is knowing how to manage your
85+
environment, so please do learn that if you havent already
86+
</p>
87+
88+
</body>

guide/obscure/blend-modes/index.html

Whitespace-only changes.

guide/obscure/pixelarray/index.html

Whitespace-only changes.

guide/obscure/set-mode-flags/index.html

Whitespace-only changes.

index.html

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,19 @@ <h1>Prerequisites</h1>
2121
what you need to know:
2222
</p>
2323
<ul>
24-
<li>Variables, loops and conditions</li>
25-
<li>Functions</li>
26-
<li>How objects work in Python</li>
24+
<ul>
25+
<li>
26+
Basic control flow keywords such as - for, while, break, if, elif, else
27+
</li>
28+
<li>Functions</li>
29+
<li>Understanding how types and instances work</li>
30+
<li>Knowing how to access and modify attributes of objects</li>
31+
<li>Familiarity with basic OOP(Object Oriented Programming)</li>
32+
<li>
33+
Knowing how to manage your packages (using pip, knowing whether you're
34+
in a venv or not)
35+
</li>
36+
</ul>
2737
</ul>
2838

2939
<p>

0 commit comments

Comments
 (0)