| 1 | package Game::HeroesVsAliens::Projectile::Blue; | ||
| 2 | |||
| 3 | 1 | ▶ | use Moo; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 4 | |||
| 5 | 1 | with 'Game::HeroesVsAliens::Role::Projectile'; | |
| 6 | |||
| 7 | has power => ( | ||
| 8 | is => 'rw', | ||
| 9 | 0 | ▶ | default => sub { 20 } |
|
Subroutine
__ANON__: not called CC=1 SCAR=6.9
| |||
| 10 | 1 | ); | |
| 11 | |||
| 12 | has sprite => ( | ||
| 13 | is => 'rw', | ||
| 14 | default => sub { | ||
| 15 | 0 | ▶ | my $sprite = SDLx::Sprite::Animated->new( |
|
Subroutine
__ANON__: not called CC=1 SCAR=6.9
| |||
| 16 | image => $_[0]->resource_directory . 'resources/boy-hero-projectile.png', | ||
| 17 | width => 32, | ||
| 18 | height => 32, | ||
| 19 | ); | ||
| 20 | } | ||
| 21 | 1 | ); | |
| 22 | |||
| 23 | has explode_sprite => ( | ||
| 24 | is => 'rw', | ||
| 25 | default => sub { | ||
| 26 | 0 | ▶ | my $sprite = SDLx::Sprite::Animated->new( |
|
Subroutine
__ANON__: not called CC=1 SCAR=6.9
| |||
| 27 | image => $_[0]->resource_directory . 'resources/boy-hero-explode-projectile.png', | ||
| 28 | width => 32, | ||
| 29 | height => 32, | ||
| 30 | ); | ||
| 31 | } | ||
| 32 | 1 | ); | |
| 33 | |||
| 34 | 1 | 1; | |