本文整理汇总了Python中Ship.block方法的典型用法代码示例。如果您正苦于以下问题:Python Ship.block方法的具体用法?Python Ship.block怎么用?Python Ship.block使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Ship
的用法示例。
在下文中一共展示了Ship.block方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: reInit
# 需要导入模块: import Ship [as 别名]
# 或者: from Ship import block [as 别名]
def reInit(self):
self.sta.name = 'Shimakaze'
self.sta.length = 130
self.sta.propulsion = 205
self.sta.evasion = 0.08
self.sta.health = [36, 36, 36, 36, 36, 36, 36, 36]
self.sta.armor = [59, 59, 59, 59, 59, 59, 59, 59]
self.sta.weapon = [[Arm.cannon460(), Arm.torpedo610(), Arm.torpedo610(), Arm.torpedo610(), Arm.torpedo610(), Arm.torpedo610(), Arm.torpedo610(), Arm.torpedo610(), Arm.torpedo610()], [Arm.cannon460()], [], [Arm.cannon460()], [Arm.cannon460(), Arm.torpedo610(), Arm.torpedo610(), Arm.torpedo610(), Arm.torpedo610(), Arm.torpedo610(), Arm.torpedo610(), Arm.torpedo610(), Arm.torpedo610()], [Arm.cannon460()], [], [Arm.cannon460()]]
self.sta.block = [Ship.block(), Ship.block(), Ship.block(), Ship.block(), Ship.block(), Ship.block(), Ship.block(), Ship.block()]
self.sta.color = (255, 200, 200)
for i in range(0, 8):
self.sta.block[i].number = i
self.sta.block[i].init(self.sta)
for block in self.sta.block:
block.armor += self.sta.level
block.health += self.sta.level
for weapon in block.weapon:
weapon.harm += self.sta.level