Example #1
0
		def createSmoke(left):
			rand = Ctrl.getRandom()
			for _ in range(self.smokeRepCounter.repeatCount):
				pos = self.getVariantVector(
					self.core.locator.position, 
					Std.Vector2DF(6, 24))
				if left:
					pos.x += 150 - 76/2
				else:
					pos.x -= 150 - 76/2
				pos.y += 40
				
				baseSize = Std.Vector2DF(48, 48)
				sizeRate = rand.getFloat(-0.5, 0.5)
				correctedSize = baseSize + baseSize*sizeRate
				
				smoke = Auxs.createSmoke(
					pos, 
					correctedSize, 
					1, 
					Ctrl.DrawPriority.enemy2, 
					0.2)
				smoke.locator.speed.y = 2