Add README.org

This commit is contained in:
Joseph Ferano 2024-07-31 05:56:15 +07:00
parent 3b5942dd2f
commit d1a24b08a1
2 changed files with 10 additions and 2 deletions

8
README.org Normal file
View File

@ -0,0 +1,8 @@
#+OPTIONS: toc:nil
* gaming-pads
** About
This is a project to study the fundamentals of game programming.
** License
gaming-pads is licensed under the terms of the MIT license. For more information,
see the included LICENSE file.

View File

@ -94,10 +94,10 @@ def rect_values(r: Rect):
def init(): def init():
for n in range(num_balls): for n in range(num_balls):
# px = random.randrange(ball_r, screen_width - ball_r)
# py = random.randrange(ball_r, screen_height - ball_r)
px = random.randrange(ball_r, 50) px = random.randrange(ball_r, 50)
py = random.randrange(ball_r, 50) py = random.randrange(ball_r, 50)
# px = random.randrange(ball_r, screen_width - ball_r)
# py = random.randrange(ball_r, screen_height - ball_r)
angle = random.uniform(0, 360) angle = random.uniform(0, 360)
vx = math.cos(angle) * ball_speed * random.uniform(1, 3) vx = math.cos(angle) * ball_speed * random.uniform(1, 3)
vy = math.sin(angle) * ball_speed * random.uniform(1, 3) vy = math.sin(angle) * ball_speed * random.uniform(1, 3)