diff demos/shooter/scripts/ships/enemies.py @ 479:ab28994820dd

Added some powerups including a spread weapon and an extra life. Fixed the problem where the player could fly off the screen.
author prock@33b003aa-7bff-0310-803a-e67f0ece8222
date Fri, 23 Apr 2010 17:17:02 +0000
parents 6b33d80b468b
children 82d44c471959
line wrap: on
line diff
--- a/demos/shooter/scripts/ships/enemies.py	Thu Apr 22 21:04:13 2010 +0000
+++ b/demos/shooter/scripts/ships/enemies.py	Fri Apr 23 17:17:02 2010 +0000
@@ -50,7 +50,7 @@
 class Saucer1(Ship):
 	def __init__(self, scene, name, instance, findInstance=True):
 		super(Saucer1, self).__init__(scene, name, findInstance)
-		self._instance = instance
+		self.instance = instance
 		self._type = SHTR_ENEMYSHIP
 		self._dir = 0
 		self._time = 500
@@ -90,7 +90,7 @@
 class Saucer2(Ship):
 	def __init__(self, scene, name, instance, findInstance=True):
 		super(Saucer2, self).__init__(scene, name, findInstance)
-		self._instance = instance
+		self.instance = instance
 		self._type = SHTR_ENEMYSHIP
 		self._dir = 0
 		self._time = 1000
@@ -133,7 +133,7 @@
 class DiagSaucer(Ship):
 	def __init__(self, scene, name, direction, instance, findInstance=True):
 		super(DiagSaucer, self).__init__(scene, name, findInstance)
-		self._instance = instance
+		self.instance = instance
 		self._type = SHTR_ENEMYSHIP
 		self.width = 0.2
 		self.height = 0.075
@@ -161,7 +161,7 @@
 class Streaker(Ship):
 	def __init__(self, scene, name, instance, findInstance=True):
 		super(Streaker, self).__init__(scene, name, findInstance)
-		self._instance = instance
+		self.instance = instance
 		self._type = SHTR_ENEMYSHIP
 		self.width = 0.2
 		self.height = 0.2		
@@ -196,7 +196,7 @@
 class Boss(Ship):
 	def __init__(self, scene, name, instance, findInstance=True):
 		super(Boss, self).__init__(scene, name, findInstance)
-		self._instance = instance
+		self.instance = instance
 		self._type = SHTR_LASTBOSS
 		self.width = 0.85
 		self.height = 0.25