def update(self):
"""Update called every frame"""
#add check for colission here
collideB = self.grid.collisionBottom(self.col, self.y)
if collideB == False:
self.y+=1
elif self.placed != True:
self.placed = True
#self.grid.add_block(collideB[1], self.col, self.blocktype_file)
#print "Placed a " + str(self.type) + " at [" + str(collideB[1]) + "][" + str(self.col) + "]"
if collideB[1] == 0:
#print "GAME OVER!!"
#pygame.quit()
#sys.exit(0)
return True
self.screen.blit(self.block_sample, (self.x,self.y))
评论列表
文章目录