Mercurial > touhou
changeset 139:3af65541dfd3
Add EoSD's hitboxes
author | Thibaut Girka <thib@sitedethib.com> |
---|---|
date | Sun, 25 Sep 2011 19:59:41 +0200 |
parents | 429de58498f9 |
children | a9d46c4b5764 |
files | pytouhou/game/bullettype.py pytouhou/game/games.py |
diffstat | 2 files changed, 12 insertions(+), 10 deletions(-) [+] |
line wrap: on
line diff
--- a/pytouhou/game/bullettype.py +++ b/pytouhou/game/bullettype.py @@ -1,6 +1,7 @@ class BulletType(object): def __init__(self, anm_wrapper, anim_index, cancel_anim_index, launch_anim2_index, launch_anim4_index, launch_anim8_index, + hitbox_size, launch_anim_penalties=(0.5, 0.4, 1./3.), launch_anim_offsets=(0, 1, 1, 1, 1, 2, 2, 2, 2, 3, 3, 3, 4, 4, 4, 0)): self.anm_wrapper = anm_wrapper @@ -9,6 +10,7 @@ class BulletType(object): self.launch_anim2_index = launch_anim2_index self.launch_anim4_index = launch_anim4_index self.launch_anim8_index = launch_anim8_index + self.hitbox_size = hitbox_size self.launch_anim_penalties = launch_anim_penalties self.launch_anim_offsets = launch_anim_offsets
--- a/pytouhou/game/games.py +++ b/pytouhou/game/games.py @@ -20,16 +20,16 @@ class EoSDGame(Game): def __init__(self, resource_loader, players, stage, rank, difficulty): etama3 = resource_loader.get_anm_wrapper(('etama3.anm',)) etama4 = resource_loader.get_anm_wrapper(('etama4.anm',)) - bullet_types = [BulletType(etama3, 0, 11, 14, 15, 16), - BulletType(etama3, 1, 12, 17, 18, 19), - BulletType(etama3, 2, 12, 17, 18, 19), - BulletType(etama3, 3, 12, 17, 18, 19), - BulletType(etama3, 4, 12, 17, 18, 19), - BulletType(etama3, 5, 12, 17, 18, 19), - BulletType(etama3, 6, 13, 20, 20, 20), - BulletType(etama3, 7, 13, 20, 20, 20), - BulletType(etama3, 8, 13, 20, 20, 20), - BulletType(etama4, 0, 1, 2, 2, 2)] + bullet_types = [BulletType(etama3, 0, 11, 14, 15, 16, hitbox_size=4), + BulletType(etama3, 1, 12, 17, 18, 19, hitbox_size=6), + BulletType(etama3, 2, 12, 17, 18, 19, hitbox_size=4), + BulletType(etama3, 3, 12, 17, 18, 19, hitbox_size=6), + BulletType(etama3, 4, 12, 17, 18, 19, hitbox_size=5), + BulletType(etama3, 5, 12, 17, 18, 19, hitbox_size=4), + BulletType(etama3, 6, 13, 20, 20, 20, hitbox_size=16), + BulletType(etama3, 7, 13, 20, 20, 20, hitbox_size=11), + BulletType(etama3, 8, 13, 20, 20, 20, hitbox_size=9), + BulletType(etama4, 0, 1, 2, 2, 2, hitbox_size=32)] player00 = resource_loader.get_anm_wrapper(('player00.anm',)) player01 = resource_loader.get_anm_wrapper(('player01.anm',))