MCPcopy Create free account
hub / github.com/geekcomputers/Python / __init__

Method __init__

PongPong_Game/pong/paddle.py:9–15  ·  view source on GitHub ↗
(self, *args, **kwargs)

Source from the content-addressed store, hash-verified

7
8class Paddle(pyglet.shapes.Rectangle):
9 def __init__(self, *args, **kwargs):
10 super(Paddle, self).__init__(*args, **kwargs)
11
12 self.acc_left, self.acc_right = 0.0, 0.0
13 self.rightx = 0
14 self.key_handler = key.KeyStateHandler()
15 self.event_handlers = [self, self.key_handler]
16
17 def update(self, win_size: Tuple, border: float, other_object, dt):
18 newlx = self.x + self.acc_left

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected