MCPcopy Create free account
hub / github.com/Mrinank-Bhowmick/python-beginner-projects / __init__

Method __init__

projects/Space Shooter/main.py:239–253  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

237
238class Objects:
239 def __init__(self):
240 # Initial location of the spaceship
241 self.x = 40
242 self.y = (Display().windows.get_height() - Display.spaceship.get_width()) / 2
243 # List of lasers
244 self.laser_list = []
245 # List of enemies
246 self.enemies_list = []
247 # How many initial enemies there should be
248 self.enemy_count = 3
249 # Background location
250 self.background_list = [[0, 0], [1800, 0]]
251 self.score = 0
252 # Condition
253 self.condition = 10
254
255 def objects(self):
256 # Background

Callers

nothing calls this directly

Calls 1

DisplayClass · 0.70

Tested by

no test coverage detected