完善海蘑菇子弹
This commit is contained in:
parent
110c5a47c4
commit
1d72fc05a2
@ -6,6 +6,7 @@
|
|||||||
"PuffShroom":{"x":0, "y":28, "width":35, "height":38},
|
"PuffShroom":{"x":0, "y":28, "width":35, "height":38},
|
||||||
"PuffShroomSleep":{"x":1, "y":0, "width":39, "height":65},
|
"PuffShroomSleep":{"x":1, "y":0, "width":39, "height":65},
|
||||||
"BulletMushRoom":{"x":0, "y":1, "width":55, "height":21},
|
"BulletMushRoom":{"x":0, "y":1, "width":55, "height":21},
|
||||||
|
"BulletSeaShroom":{"x":0, "y":1, "width":55, "height":21},
|
||||||
"PotatoMine":{"x":0, "y":0, "width":75, "height":55},
|
"PotatoMine":{"x":0, "y":0, "width":75, "height":55},
|
||||||
"Squash":{"x":10, "y":140, "width":80, "height":86},
|
"Squash":{"x":10, "y":140, "width":80, "height":86},
|
||||||
"SquashAim":{"x":10, "y":140, "width":80, "height":86},
|
"SquashAim":{"x":10, "y":140, "width":80, "height":86},
|
||||||
|
|||||||
BIN
resources/graphics/Bullets/BulletSeaShroom/BulletSeaShroom_0.png
Normal file
BIN
resources/graphics/Bullets/BulletSeaShroom/BulletSeaShroom_0.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.0 KiB |
BIN
resources/graphics/Bullets/BulletSeaShroom/BulletSeaShroom_1.png
Normal file
BIN
resources/graphics/Bullets/BulletSeaShroom/BulletSeaShroom_1.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.1 KiB |
BIN
resources/graphics/Bullets/BulletSeaShroom/BulletSeaShroom_2.png
Normal file
BIN
resources/graphics/Bullets/BulletSeaShroom/BulletSeaShroom_2.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.3 KiB |
BIN
resources/graphics/Bullets/BulletSeaShroom/BulletSeaShroom_3.png
Normal file
BIN
resources/graphics/Bullets/BulletSeaShroom/BulletSeaShroom_3.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.2 KiB |
BIN
resources/graphics/Bullets/BulletSeaShroom/BulletSeaShroom_4.png
Normal file
BIN
resources/graphics/Bullets/BulletSeaShroom/BulletSeaShroom_4.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.1 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 1.3 KiB |
@ -78,6 +78,8 @@ class Bullet(pg.sprite.Sprite):
|
|||||||
explode_name = 'BulletMushRoomExplode'
|
explode_name = 'BulletMushRoomExplode'
|
||||||
elif self.name == c.BULLET_PEA_ICE:
|
elif self.name == c.BULLET_PEA_ICE:
|
||||||
explode_name = 'PeaIceExplode'
|
explode_name = 'PeaIceExplode'
|
||||||
|
elif self.name == c.BULLET_SEASHROOM:
|
||||||
|
explode_name = 'BulletSeaShroomExplode'
|
||||||
else:
|
else:
|
||||||
explode_name = 'PeaNormalExplode'
|
explode_name = 'PeaNormalExplode'
|
||||||
|
|
||||||
@ -1214,8 +1216,8 @@ class SeaShroom(Plant):
|
|||||||
|
|
||||||
def attacking(self):
|
def attacking(self):
|
||||||
if (self.current_time - self.shoot_timer) > 1400:
|
if (self.current_time - self.shoot_timer) > 1400:
|
||||||
self.bullet_group.add(Bullet(self.rect.right, self.rect.y + 10, self.rect.y + 10,
|
self.bullet_group.add(Bullet(self.rect.right, self.rect.y + 50, self.rect.y + 50,
|
||||||
c.BULLET_MUSHROOM, c.BULLET_DAMAGE_NORMAL, effect=False))
|
c.BULLET_SEASHROOM, c.BULLET_DAMAGE_NORMAL, effect=False))
|
||||||
self.shoot_timer = self.current_time
|
self.shoot_timer = self.current_time
|
||||||
|
|
||||||
def canAttack(self, zombie):
|
def canAttack(self, zombie):
|
||||||
|
|||||||
@ -256,6 +256,7 @@ BULLET_PEA = 'PeaNormal'
|
|||||||
BULLET_PEA_ICE = 'PeaIce'
|
BULLET_PEA_ICE = 'PeaIce'
|
||||||
BULLET_FIREBALL = 'Fireball'
|
BULLET_FIREBALL = 'Fireball'
|
||||||
BULLET_MUSHROOM = 'BulletMushRoom'
|
BULLET_MUSHROOM = 'BulletMushRoom'
|
||||||
|
BULLET_SEASHROOM = 'BulletSeaShroom'
|
||||||
# 子弹伤害
|
# 子弹伤害
|
||||||
BULLET_DAMAGE_NORMAL = 20
|
BULLET_DAMAGE_NORMAL = 20
|
||||||
BULLET_DAMAGE_FIREBALL_BODY = 27 # 这是火球本体的伤害,注意不是40,本体(27) + 溅射(13)才是40
|
BULLET_DAMAGE_FIREBALL_BODY = 27 # 这是火球本体的伤害,注意不是40,本体(27) + 溅射(13)才是40
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user