doomsday: Fix a crash when no spawn points are available

This commit is contained in:
Joey Z 2014-04-19 22:14:59 -04:00
parent f554b7f312
commit 5325d79255

View file

@ -335,6 +335,9 @@ class DistributedSafezoneInvasionAI(DistributedObjectAI, FSM):
'''
def spawnOne(self, suitType, levelOffset=0):
# Pick a spawnpoint:
if not self.spawnPoints:
return
pointId = random.choice(self.spawnPoints)
self.spawnPoints.remove(pointId)