@ -75,6 +75,9 @@ void Monster::STRATEGY::GIANT_OCTOPUS(Monster&m,float fElapsedTime,std::string s
if ( ! GFX . count ( takoyakiImgDir ) ) ERR ( std : : format ( " WARNING! Could not find item image {} " , takoyakiImgDir ) ) ;
game - > AddEffect ( std : : make_unique < Effect > ( m . GetPos ( ) , INFINITE , " item_img_directory " _S + " Takoyaki.png " , m . OnUpperLevel ( ) , 1.f , 0.f , vf2d { 4.f , 4.f } , vf2d { } , WHITE ) ) ;
m . SetLifetime ( 4.f ) ;
m . F ( A : : SHOOT_TIMER ) = ConfigFloat ( " Shoot Frequency " ) ;
m . F ( A : : SHOOT_ANIMATION_TIME ) = m . GetAnimation ( " ATTACK " ) . GetTotalAnimationDuration ( ) ;
m . I ( A : : ATTACK_COUNT ) = 0 ;
return false ;
} ) ;
SETPHASE ( IDENTIFY_ARMS ) ;
@ -95,7 +98,12 @@ void Monster::STRATEGY::GIANT_OCTOPUS(Monster&m,float fElapsedTime,std::string s
}
} break ;
case NORMAL : {
m . F ( A : : SHOOT_TIMER ) - = fElapsedTime ;
m . F ( A : : CASTING_TIMER ) - = fElapsedTime ;
if ( m . F ( A : : SHOOT_ANIMATION_TIME ) > 0.f ) {
m . F ( A : : SHOOT_ANIMATION_TIME ) - = fElapsedTime ;
if ( m . F ( A : : SHOOT_ANIMATION_TIME ) < = 0.f ) m . PerformIdleAnimation ( ) ;
}
if ( m . F ( A : : CASTING_TIMER ) < = 0.f ) {
int deadMonsterCount { 0 } ;
std : : vector < vf2d > unoccupiedArmLocs ;
@ -125,6 +133,16 @@ void Monster::STRATEGY::GIANT_OCTOPUS(Monster&m,float fElapsedTime,std::string s
}
m . F ( A : : CASTING_TIMER ) = util : : random_range ( ConfigFloatArr ( " Arm Move Timer " , 0 ) , ConfigFloatArr ( " Arm Move Timer " , 1 ) ) ;
}
if ( m . F ( A : : SHOOT_TIMER ) < = 0.f ) {
if ( m . I ( A : : ATTACK_COUNT ) > = ConfigInt ( " Big Bullet Frequency " ) ) {
CreateBullet ( Bullet ) ( m . GetPos ( ) , util : : pointTo ( m . GetPos ( ) , game - > GetPlayer ( ) - > GetPos ( ) ) * ConfigFloat ( " Big Bullet Speed " ) , ConfigFloat ( " Big Bullet Radius " ) * 1.5f , ConfigFloat ( " Big Bullet Damage " ) , m . OnUpperLevel ( ) , false , ConfigPixel ( " Big Bullet Color " ) , { ConfigFloat ( " Big Bullet Radius " ) , ConfigFloat ( " Big Bullet Radius " ) } ) EndBullet ;
m . I ( A : : ATTACK_COUNT ) = - 1 ;
} else CreateBullet ( Bullet ) ( m . GetPos ( ) , util : : pointTo ( m . GetPos ( ) , game - > GetPlayer ( ) - > GetPos ( ) ) * ConfigFloat ( " Bullet Speed " ) , ConfigFloat ( " Bullet Radius " ) , ConfigFloat ( " Bullet Damage " ) , m . OnUpperLevel ( ) , false , ConfigPixel ( " Bullet Color " ) , { ConfigFloat ( " Bullet Radius " ) , ConfigFloat ( " Bullet Radius " ) } ) EndBullet ;
m . PerformShootAnimation ( ) ;
m . F ( A : : SHOOT_TIMER ) = ConfigFloat ( " Shoot Frequency " ) ;
m . I ( A : : ATTACK_COUNT ) + + ;
}
} break ;
case HURT_ANIMATION : {