New Super Mario Bros. U Headers
Loading...
Searching...
No Matches
Enemy Class Reference

#include <Enemy.h>

Inherits ActorMultiState.

Inherited by BalloonHangActor, Birikyu, Boss, BrosBase, BunDemoKameck, CarryEnemy, Koton, KuriboBase, LkuriboBase, and Nokonoko.

Public Types

enum  FumiType { cFumiType_Hit = 0 , cFumiType_Fumi , cFumiType_MameFumi , cFumiType_SpinFumi }
 Defines the classification of player-enemy stomp and collision interactions. More...
enum  FumiSeType { cFumiSeType_Normal = 0 , cFumiSeType_Step , cFumiSeType_NoEffect }
enum  EnFlag { cEnFlag_Shell = 1 << 0 , cEnFlag_Carry = 1 << 1 , cEnFlag_16 = 1 << 16 , cEnFlag_NoCeilCheckPlayer = 1 << 24 }
Public Types inherited from Actor
enum  ActorType {
  cActorType_Generic = 0 , cActorType_Player , cActorType_Yoshi , cActorType_Enemy ,
  cActorType_ChibiYoshi
}
enum  CarryFlag {
  cCarryFlag_Release = 1 << 0 , cCarryFlag_Throw = 1 << 1 , cCarryFlag_ThrowHard = 1 << 2 , cCarryFlag_None = 0 ,
  cCarryFlag_All = cCarryFlag_Release | cCarryFlag_Throw | cCarryFlag_ThrowHard
}
enum  ScreenOutFlag {
  cScreenOutFlag_SkipNone = 0 , cScreenOutFlag_SkipDeletion = 1 << 1 , cScreenOutFlag_SkipCameraCheck = 1 << 2 , cScreenOutFlag_SkipRideCheck = 1 << 3 ,
  cScreenOutFlag_SkipTottenCheck = 1 << 4
}
 Flags to pass to screenOutCheck to skip checks or actions during the evaluation. More...
Public Types inherited from ActorBase
enum  MainState { cState_None = 0 , cState_Failed , cState_Success , cState_Wait }
 Represents the execution state of a main operation, and whether it was skipped. More...
enum  Result { cResult_Wait = 0 , cResult_Success , cResult_Failed }
 Defines signals to pass to ActorMgr when performing create and delete operations on the actor. More...
typedef sead::OffsetList< ActorBaseList

Public Member Functions

 Enemy (const ActorCreateParam &param)
 ~Enemy () override=default
void changeState (const StateID &state_id) override
virtual bool vf18C ()
virtual bool setDamage (ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other)
virtual bool checkComboClap (s32 combo_cnt)
virtual bool createIceActor ()
 Callback for spawning ice blocks when frozen by an ice flower.
virtual void setIceAnm ()
virtual void returnAnm_Ice ()
virtual void returnState_Ice ()
virtual void calcMdl_Base ()
virtual bool vf1CC ()
virtual bool enemyDamageCheck (ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other)
virtual bool playerDamageCheck (ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other)
virtual bool enemyPreDamageCheck (bool *dead, ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other)
virtual void hitYoshiEat (ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other)
virtual bool yoshiDamageCheck (ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other)
virtual bool chibiYoshiDamageCheck (ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other)
virtual bool etcDamageCheck (ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other)
virtual void vsEnemyHitCheck_Normal (ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other)
virtual void vsPlayerHitCheck_Normal (ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other)
virtual void vsYoshiHitCheck_Normal (ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other)
virtual void vsChibiYoshiHitCheck_Normal (ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other)
virtual bool hitCallback_Star (ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other)
virtual bool hitCallback_Slip (ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other)
virtual bool hitCallback_Spin (ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other)
virtual bool hitCallback_WireNet (ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other)
virtual bool hitCallback_HipAttk (ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other)
virtual bool hitCallback_YoshiHipAttk (ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other)
virtual bool hitCallback_PenguinSlide (ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other)
virtual bool hitCallback_Cannon (ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other)
virtual bool hitCallback_AttackUnk25 (ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other)
virtual bool hitCallback_Shell (ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other)
virtual bool hitCallback_Fire (ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other)
virtual bool hitCallback_Ice (ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other)
virtual bool hitCallback_YoshiBullet (ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other)
virtual bool hitCallback_YoshiFire (ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other)
virtual bool hitCallback_ChibiYoshiUnk (ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other)
virtual bool hitCallback_ChibiYoshiLight (ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other)
virtual bool hitCallback_ChibiYoshiStar (ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other)
virtual bool hitCallback_AttackUnk27 (bool *dead, ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other)
virtual void setDeathInfo_Quake (s32)
virtual void setDeathInfo_IceBreak ()
virtual bool setDeathInfo_Star (ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other)
virtual bool isQuakeDamage ()
virtual void setDeathSound_Fire ()
virtual void setDeathSound_HipAttk ()
virtual void fumiJumpSet (Actor *)
virtual void fumiScoreSet (Actor *)
virtual void yoshiFumiJumpSet (Actor *)
virtual void yoshiFumiScoreSet (Actor *)
virtual void mameFumiJumpSet (Actor *)
virtual void fumiSE (Actor *)
virtual void fumiEffect (Actor *)
virtual void spinfumiSE (Actor *)
void spinfumiEffect (Actor *)
virtual void mamefumiSE ()
virtual void mamefumiEffect (Actor *)
virtual void yoshifumiSE (Actor *)
virtual void hipatkEffect (const sead::Vector3f &effect_pos)
virtual void vf34C ()
virtual bool checkDispIn ()
virtual void setAwaHit (Actor *awa)
virtual void awaCatchMove (Actor *awa)
virtual void setAwaCatchEnd (Actor *awa)
virtual void setAwaInvalid (Actor *awa)
void setDeathInfo_Fall (DirType direction, s32 player_no=-1, ScoreMgr::ScoreType score_type=ScoreMgr::cScoreType_Invalid)
void setDeathInfo_Fall (const sead::Vector2f *speeds, DirType direction, s32 player_no=-1, ScoreMgr::ScoreType score_type=ScoreMgr::cScoreType_Invalid)
void setDeathInfo_Fumi (Actor *player, const sead::Vector2f &speed, const StateID &state_id)
void setDeathInfo_Fumi (Actor *player, const sead::Vector2f &speed)
void setDeathInfo_FumiFall (Actor *player, const sead::Vector2f &speed)
void setDeathInfo_FumiOther (Actor *player, const sead::Vector2f &speed)
void setDeathInfo_SpinFumi (Actor *)
void setDeathInfo_YoshiFumi (Actor *)
void startSound (const char *name)
FumiType fumiCheck (ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other, FumiSeType se_type)
 Process a collision with a player and return which type occurred.
s32 calcComboPlFumiCnt (Actor *player)
void bound (f32, f32, f32)
void calcMdl_Normal ()
bool isDead () const
void hitdamageEffect (const sead::Vector3f &effect_pos)
Angle applyWaterRollDec (Angle ang)
void killIce ()
void fumistepSE (Actor *)
void yoshifumistepSE (Actor *)
void spinFumiJumpSet (Actor *actor)
void spinFumiScoreSet (Actor *)
Public Member Functions inherited from ActorMultiState
 ActorMultiState (const ActorCreateParam &param)
 ~ActorMultiState () override
void executeState ()
bool isState (const StateID &state_id) const
bool isOldState (const StateID &state_id) const
bool isMainState (const StateID &state_id) const
Public Member Functions inherited from ActorCollision
ActorBgCollisionCheckgetBgCheck () override
Public Member Functions inherited from Actor
virtual void setPlayerNo (s8 id)
s8 getPlayerNo () const
virtual void removeCollisionCheck ()
virtual void reviveCollisionCheck ()
virtual void setCarryFall (Actor *, s32)
virtual bool isSpinLiftUpEnable ()
virtual void setSpinLiftUpActor (Actor *player)
virtual void vfC4 ()
virtual void vfCC ()
bool checkCarried (s32 *player_no)
s32 getComboCnt () const
void clrComboCnt ()
void incComboCnt ()
void slideComboSE (s32 combo_cnt, bool combo_type_2)
s32 searchNearPlayer (sead::Vector2f &out)
DirType getPlayerDirLR (const sead::Vector3f &position)
DirType getPlayerDirUD (const sead::Vector3f &position)
DirType getPlayerDirLR ()
DirType getPlayerDirUD ()
bool screenOutCheck (u16 flag)
 Checks if the actor is out of gameplay and optionally deletes it.
virtual void allEnemyDeathEffSet ()
virtual void waterSplashEffect (const sead::Vector3f &pos)
virtual void yoganSplashEffect (const sead::Vector3f &pos)
virtual void yoganWaveSplashEffect (const sead::Vector3f &pos)
virtual void poisonSplashEffect (const sead::Vector3f &pos)
f32 getEffectZPos () const
bool checkEat () const
void deleteActor (bool manual_deleted)
 Schedule this actor for deletion on the next frame.
ActorCollisionCheckgetCollisionCheck ()
const ActorCollisionCheckgetCollisionCheck () const
bool isExecEnable () const
bool isDrawEnable () const
DirType getDirection () const
void setDirection (DirType dir)
u8 getLayer () const
f32 getSpeedF () const
void setSpeedF (f32 speedF)
f32 getMaxSpeedF () const
void setMaxSpeedF (f32 maxSpeedF)
f32 getMaxFallSpeed () const
void setMaxFallSpeed (f32 maxFallSpeed)
f32 getAccelY () const
void setAccelY (f32 accelY)
f32 getAccelF () const
void setAccelF (f32 accelF)
sead::Vector3fgetPos ()
const sead::Vector3fgetPos () const
sead::Vector2fgetPos2D ()
const sead::Vector2fgetPos2D () const
sead::Vector3f getCenterPos () const
sead::Vector2f getCenterPos2D () const
f32 getCenterX () const
f32 getCenterY () const
f32 getCenterZ () const
sead::Vector3fgetSpeedVec ()
const sead::Vector3fgetSpeedVec () const
sead::Vector3fgetSpeedMaxVec ()
const sead::Vector3fgetSpeedMaxVec () const
sead::Vector3fgetScale ()
const sead::Vector3fgetScale () const
Angle3getAngle ()
const Angle3getAngle () const
ActorType getActorType () const
void setKind (ActorType type)
bool getManualDeletedFlag () const
CarryFlag getCarryFlag () const
u8 getSwitchFlag0 () const
u8 getSwitchFlag1 () const
u32 getProfFlag () const
Public Member Functions inherited from ActorBase
bool isActive () const
 Whether this actor has been successfully created and is now active.
void deleteRequest ()
 Schedule this actor for deletion on the next frame.
bool isRequestedDelete () const
 Whether this actor has been scheduled for deletion on the next frame.
ActorUniqueID getActorUniqueID () const
 The unique identifier handle for this actor.
s32 getProfileID () const
 The specific profile ID which this actor was instantiated from.
ProfilegetProfile () const
 The specific profile which this actor was instantiated from.
bool isCreatedImmediately () const
 Whether the actor was created with ActorMgr::createImmediately(), rather than deferred with ActorMgr::createLater().
bool isMapActor () const
 Whether the actor was spawned from the level with ActorCreateMgr, rather than dynamically spawned by another actor.
u32 getParam0 () const
 Level designer configuration. Also known as "nybbles" or "spritedata".
u32 getParam1 () const
 Level designer configuration. Also known as "nybbles" or "spritedata".
ActorParamEx1 getParamEx () const
 Extra level designer configuration. Also known as "nybbles" or "spritedata".
const ListgetChildList () const
 sead::OffsetList used for holding child actors spawned by this actor. Managed automatically if param.parent_id is set when spawning.
sead::HeapgetActorHeap () const
 The personal heap for this actor.
ActorBasegetParent () const
template<typename T>
T * getParent () const
 The parent actor pointer if this actor is a child, nullptr otherwise.
void removeChild (ActorBase *child)
 Disconnects a child from this actor's family tree.

Static Public Member Functions

static bool ceilCheck (f32 pos_y, ActorCollisionCheck *cc)
static void normal_collcheck (ActorCollisionCheck *cc_self, ActorCollisionCheck *cc_other)
static void fireballInvalid (ActorCollisionCheck *cc_other)
static void iceballInvalid (ActorCollisionCheck *cc_other)

Static Public Attributes

static const f32 cDieFallInitSpeedX [cDirType_NumX]
static const f32 cFumiJumpSpeed
static const f32 cDefaultGravity
static const f32 cDefaultMaxFallSpeed
static const f32 cDieFallInitSpeedY
static const f32 cDieFallMaxFallSpeed
static const f32 cDieFallGravity
static const Angle cBaseAngleY [cDirType_NumX]
 Maps a 2D direction to a "facing" Y-angle.
static const s8 cEnMuki [cDirType_NumX]
 Maps a 2D direction to a sign multiplier (1 or -1).
static const s32 cNoHitPlayerTimerDefault = 5

Protected Member Functions

bool preExecute () override
 Callback invoked before the execute operation.
void blockHitInit_ () override
void setSmokeDamage_ (Actor *) override
bool setTouchDrcDamage_ (const sead::Vector2f &pos) override
Protected Member Functions inherited from ActorCollision
 ActorCollision (const ActorCreateParam &param)
void postCreate (MainState state) override
 Callback invoked unconditionally after the create phase completes. It executes even if preCreate() bypassed the main create() operation.
void postExecute (MainState state) override
 Callback invoked unconditionally after the execute phase completes. It executes even if preExecute() bypassed the main execute() operation.
Result doDelete () override
 Main deletion callback for the actor.
virtual void setWaterFunsui_ (bool enable)
virtual bool isWaterFunsui_ () const
virtual void beginFunsui_ ()
virtual void endFunsui_ (f32 speed_y)
virtual bool isFunsui_ () const
virtual void vf134 (f32 speed)
virtual bool vf13C ()
virtual void vf144 (s32)
virtual void setFunsuiPos_ (sead::Vector2f dst)
virtual void setFunsuiSpeedY_ (f32 speed)
virtual bool smokeDamageEnable_Yogan_ (f32 surface_pos_y)
virtual bool smokeDamageEnable_Poison_ (f32 surface_pos_y)
virtual void getBox_ (sead::BoundBox2f &box)
 ~ActorCollision () override
BgCheckFlag bgCheck_ ()
bool bgCheckFoot_ () const
bool bgCheckWall_ () const
void clampMoveDistance_ (BgCollision &bg_collision)
bool isHitBgCollision_ (const BgCollision &bg_collision) const
void calcSpeedY_ ()
void calcFallSpeed_ ()
void posMove_ ()
void posMoveCalcJump_ ()
void calcJumpSpeedF_ ()
WaterType checkWater_ (f32 *surface_pos_y)
void enterWater_ ()
bool hasamareBgCheck_ ()
void checkSnapToGround_ (f32 y_check_distance, const ActorBgCollisionCheck::Sensor &foot_sensor)
void snapToGround_ (f32 y_check_distance, const ActorBgCollisionCheck::Sensor &foot_sensor, bool extended, bool force)
void registerInGamescene_ ()
bool checkForSuitableGround_ (const sead::Vector2f &offset) const
Protected Member Functions inherited from Actor
 Actor (const ActorCreateParam &param)
 ~Actor () override
bool preDraw () override
 Callback invoked before the draw operation.
virtual bool drawCullCheck_ ()
void splashEffect_ (const sead::Vector3f &pos, EffectID effect_id, u8 wave_scale, const char *sound_label)
void setAreaNo_ ()
void calcSpeedX_ ()
void calcSpeedY_ (f32 accel_y, f32 speed_max_y)
void calcSpeedY_ ()
void calcSpeedF_ (f32 accelF, f32 max_speedF)
void calcSpeedF_ ()
void calcFallSpeed_ (f32 accel_y, f32 max_fall_speed)
void calcFallSpeed_ ()
void posMove_ (sead::Vector3f &delta)
void posMove_ (sead::Vector2f &delta_xy, f32 delta_z)
void posMove_ ()
void carryFukidashiCheck_ (s32 action)
void carryFukidashiCheck_ (s32 action, const sead::Vector2f &range)
void carryFukidashiCancel_ (s32 action, s32 player_no)
bool isEnablePressLR_ (const ActorBgCollisionCheck &bc)
bool isEnablePressUD_ (const ActorBgCollisionCheck &bc)
bool setPressBreakLR_ (const ActorBgCollisionCheck &bc)
bool setPressBreakUD_ (const ActorBgCollisionCheck &bc)
bool setPressIceHeadBreak_ (const ActorBgCollisionCheck &bc)
bool setPressBreakIce_ (const BgCollision *bg_collision)
bool setPressBreakBlockDRC_ (const BgCollision *bg_collision)
Protected Member Functions inherited from ActorBase
 ActorBase (const ActorCreateParam &param)
 Constructs an actor from configuration data.
virtual ~ActorBase ()
 Destroys the actor and orphans all of its children.
virtual bool preCreate ()
 Callback invoked before the create operation.
virtual Result create ()
 Main initialization/setup callback for the actor.
virtual bool execute ()
 Main execution/logic callback for the actor. Called every frame (the game runs at exactly 60 FPS).
virtual void finalUpdate ()
 Callback which is called after all other actors have finished executing for this frame.
virtual bool draw ()
 Main rendering callback for the actor. Called every frame (the game runs at exactly 60 FPS).
virtual void postDraw (MainState state)
 Callback invoked unconditionally after the draw phase completes. It executes even if preDraw() bypassed the main draw() operation.
virtual bool preDelete ()
 Callback invoked before the delete operation.
virtual void postDelete (MainState state)
 Unconditionally called callback for after the delete operation.
void setActive_ (bool active)

Protected Attributes

EnemyDeathInfo mDeathInfo
sead::SafeArray< u16, 4 > mNoHitPlayerTimer
sead::BitFlag32 mEnFlag
IceMgr mIceMgr
EnemyChibiYoshiAwaData mChibiYoshiAwaData
EnemyFumiProc mFumiProc
u16 _186c
u16 _186e
u32 _1870
u8 mDieFallDirection
u8 mPreIceDirection
Combo mCombo
u8 _187c
u8 _187d
s8 _187e
Protected Attributes inherited from ActorMultiState
FStateStateMgr< ActorMultiStatemStateMgr
Protected Attributes inherited from ActorCollision
ActorBgCollisionObjCheck mBgCheckObj
f32 mJumpSpeedF
f32 mJumpAccelF
sead::Vector3fmWaterCheckPos
bool mUseWaterTypeOverride
WaterType mWaterTypeOverride
f32 _1774
sead::Vector2f mBgSpeed
sead::Vector2f mBgSpeedPrev
f32 mWaterSpeedMaxY
f32 mWaterMaxFallSpeed
f32 mWaterGravity
bool mCheckWaterNeeded
bool mIsInQuicksand
bool mIsSubmerged
bool mNoWaterCalc
u8 mWaterCalcType
u8 mNoLavaSplashTimer
bool mIsWaterFunsui
bool mIsOnGround
u32 mJumpFrame
Protected Attributes inherited from Actor
DirType mDirection
s8 mPlayerNo
s8 mControllerLytPlayerNo
u8 mLayer
sead::BitFlag8 mCollisionMask
f32 mSpeedF
f32 mMaxSpeedF
f32 mMaxFallSpeed
f32 mAccelY
f32 mAccelF
sead::Vector3f mPos
sead::Vector3f mSpeed
sead::Vector3f mSpeedMax
sead::Vector3f mScale
Angle3 mAngle
Angle3 mAnglePrev
sead::Vector2f mPosDelta
ActorCollisionCheck mCollisionCheck
sead::Vector2f mVisibleAreaOffset
sead::Vector2f mVisibleAreaSize
sead::Vector2f mSize
ActorCullRange mCullLimit
u8 mAreaNo
u8 mActorType
bool mIsExecEnable
bool mIsDrawEnable
bool mManualDeletedFlag
u8 _211
u8 mCarryFlag
u8 mSwitchFlag0
u8 mSwitchFlag1
u16 mCreateFlag
u32 mBumpDamageTimer
u32 mBumpDirection
u8 _220
DirType mCarryDirection
u32 mThrowPlayerNo
s32 mComboCnt
u32 mProfFlag
sead::Vector3f mCenterOffset
sead::Vector3f mPosPrev
sead::Vector3f mPosPrevPostExec
sead::Vector3f mPosPrev2
EatDatamEatDataPtr
ChibiYoshiEatDatamChibiYoshiEatDataPtr
PropelPartsmPropelParts
u8 * _270
f32 mAddSpeedF
ChibiYoshiAwaDatamChibiYoshiAwaDataPtr
Protected Attributes inherited from ActorBase
sead::HeapmActorHeap
 Personal heap for this actor of type sead::FrameHeap. Capacity of 0x20200, but profiles in the player whitelist get 0x1A0200.
ActorUniqueID mActorUniqueID
 The unique identifier handle for this actor.
ProfilemActorProfile
 The specific profile which this actor was instantiated from.
bool mCreatedImmediately
 Whether the actor was created with ActorMgr::createImmediately(), rather than deferred with ActorMgr::createLater().
bool mIsMapActor
 Whether the actor was spawned from the level with ActorCreateMgr, rather than dynamically spawned by another actor.
bool mIsActive
 Whether the create operation has completed and the actor is executing.
bool mDeleteRequestFlag
 Whether to delete this actor on the next frame.
u32 mParam0
 Level designer configuration. Also known as "nybbles" or "spritedata".
u32 mParam1
 Level designer configuration. Also known as "nybbles" or "spritedata".
ActorParamEx1 mParamEx
 Extra level designer configuration. Also known as "nybbles" or "spritedata".
List mChildList
 sead::OffsetList used for holding child actors spawned by this actor. Managed automatically if param.parent_id is set when spawning.
sead::ListNode mChildNode
 Implementation detail. Used to track our position in the parent's mChildList.
ActorBasemParent
 The parent actor if this actor is a child. Automatically set to nullptr if orphaned.
sead::ListNode mExecuteNode
 Implementation detail. Used to track our position in ActorMgr lists.
sead::ListNode mDrawNode
 Implementation detail. Used to track our position in ActorMgr mDrawManage list.
sead::BitFlag32 mFlag

Additional Inherited Members

Protected Types inherited from ActorCollision
enum  BgCheckFlag { cBgCheckFlag_Foot = 1 << 0 , cBgCheckFlag_Head = 1 << 1 , cBgCheckFlag_Wall = 1 << 2 , cBgCheckFlag_None = 0 }
enum  WaterCalcType { cWaterCalcType_Normal = 0 , cWaterCalcType_EnablePreCheck , cWaterCalcType_ForceOut }
Static Protected Attributes inherited from Actor
static const f32 cCullXLimit
static const f32 cCullYLimit

Member Enumeration Documentation

◆ FumiType

Defines the classification of player-enemy stomp and collision interactions.

Note
"Fumi" (踏み) translates to "stomp" in Japanese.
Enumerator
cFumiType_Hit 

Lateral Impact: Moving into the enemy (also includes penguin slides & slope slides).

cFumiType_Fumi 

Standard Stomp: Jumping onto the enemy (e.g. normal jumps, ground pounds).

cFumiType_MameFumi 

Mini Stomp: Jumping onto the enemy as Mini ("Mame") Mario. Also includes Mini Mario's spin-jump.

cFumiType_SpinFumi 

Spin Stomp: Spin-jumping onto the enemy. Also includes Propeller Mario drills.

◆ FumiSeType

Enumerator
cFumiSeType_Normal 
cFumiSeType_Step 
cFumiSeType_NoEffect 

◆ EnFlag

Enumerator
cEnFlag_Shell 
cEnFlag_Carry 
cEnFlag_16 
cEnFlag_NoCeilCheckPlayer 

Constructor & Destructor Documentation

◆ Enemy()

Enemy::Enemy ( const ActorCreateParam & param)

◆ ~Enemy()

Enemy::~Enemy ( )
overridedefault

Member Function Documentation

◆ preExecute()

bool Enemy::preExecute ( )
overrideprotectedvirtual

Callback invoked before the execute operation.

Returns
Whether to continue to the main execute callback, rather than skip to postExecute().

Returns true by default unless the game is paused or frozen. See EventMgr::isJoin().

Address: 0x02002F04

Reimplemented from ActorCollision.

◆ blockHitInit_()

void Enemy::blockHitInit_ ( )
overrideprotectedvirtual

Reimplemented from Actor.

Reimplemented in KuriboBase, and MechaKoopa.

◆ setSmokeDamage_()

void Enemy::setSmokeDamage_ ( Actor * )
overrideprotectedvirtual

Reimplemented from ActorCollision.

◆ setTouchDrcDamage_()

bool Enemy::setTouchDrcDamage_ ( const sead::Vector2f & pos)
overrideprotectedvirtual

Reimplemented from ActorCollision.

◆ changeState()

void Enemy::changeState ( const StateID & state_id)
overridevirtual

Reimplemented from ActorMultiState.

◆ vf18C()

virtual bool Enemy::vf18C ( )
inlinevirtual

Reimplemented in Bomhei, and MechaKoopa.

◆ setDamage()

virtual bool Enemy::setDamage ( ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other )
virtual

Reimplemented in BrosBase, and KuriboBase.

◆ checkComboClap()

virtual bool Enemy::checkComboClap ( s32 combo_cnt)
virtual

◆ createIceActor()

virtual bool Enemy::createIceActor ( )
virtual

Callback for spawning ice blocks when frozen by an ice flower.

Returns
Forward the return value of the createIce() method call.

Implement this function by calling mIceMgr.createIce() with your custom IceInfo.

@endcode

Address: 0x023304F8

Reimplemented in Birikyu, Bomhei, Boss, BrosBase, Kuribo, MechaKoopa, and PataKuribo.

◆ setIceAnm()

virtual void Enemy::setIceAnm ( )
virtual

Reimplemented in BrosBase, Kuribo, and MechaKoopa.

◆ returnAnm_Ice()

virtual void Enemy::returnAnm_Ice ( )
virtual

Reimplemented in Kuribo.

◆ returnState_Ice()

virtual void Enemy::returnState_Ice ( )
virtual

Reimplemented in Bomhei, Boss, BrosBase, Kuribo, and PataKuribo.

◆ calcMdl_Base()

virtual void Enemy::calcMdl_Base ( )
virtual

Reimplemented in Bomhei, Boss, BrosBase, KuriboBase, and MechaKoopa.

◆ vf1CC()

virtual bool Enemy::vf1CC ( )
virtual

◆ enemyDamageCheck()

virtual bool Enemy::enemyDamageCheck ( ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other )
virtual

◆ playerDamageCheck()

virtual bool Enemy::playerDamageCheck ( ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other )
virtual

◆ enemyPreDamageCheck()

virtual bool Enemy::enemyPreDamageCheck ( bool * dead,
ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other )
virtual

◆ hitYoshiEat()

virtual void Enemy::hitYoshiEat ( ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other )
virtual

Reimplemented in KuriboBase.

◆ yoshiDamageCheck()

virtual bool Enemy::yoshiDamageCheck ( ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other )
virtual

◆ chibiYoshiDamageCheck()

virtual bool Enemy::chibiYoshiDamageCheck ( ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other )
virtual

◆ etcDamageCheck()

virtual bool Enemy::etcDamageCheck ( ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other )
virtual

Reimplemented in Bomhei, and MechaKoopa.

◆ vsEnemyHitCheck_Normal()

virtual void Enemy::vsEnemyHitCheck_Normal ( ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other )
virtual

Reimplemented in Bomhei, Kuribo, KuriboBase, and MechaKoopa.

◆ vsPlayerHitCheck_Normal()

virtual void Enemy::vsPlayerHitCheck_Normal ( ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other )
virtual

Reimplemented in Birikyu, Boss, BrosBase, CarryEnemy, and KuriboBase.

◆ vsYoshiHitCheck_Normal()

virtual void Enemy::vsYoshiHitCheck_Normal ( ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other )
virtual

Reimplemented in Birikyu, Bomhei, Boss, BrosBase, Koton, and KuriboBase.

◆ vsChibiYoshiHitCheck_Normal()

virtual void Enemy::vsChibiYoshiHitCheck_Normal ( ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other )
virtual

Reimplemented in KuriboBase.

◆ hitCallback_Star()

virtual bool Enemy::hitCallback_Star ( ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other )
virtual

Reimplemented in Boss, and BrosBase.

◆ hitCallback_Slip()

virtual bool Enemy::hitCallback_Slip ( ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other )
virtual

Reimplemented in Boss.

◆ hitCallback_Spin()

virtual bool Enemy::hitCallback_Spin ( ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other )
virtual

Reimplemented in Bomhei, Boss, BrosBase, Kuribo, MechaKoopa, and PataKuribo.

◆ hitCallback_WireNet()

virtual bool Enemy::hitCallback_WireNet ( ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other )
virtual

Reimplemented in Birikyu, and Boss.

◆ hitCallback_HipAttk()

virtual bool Enemy::hitCallback_HipAttk ( ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other )
virtual

Reimplemented in Birikyu, Bomhei, Boss, BrosBase, Kuribo, MechaKoopa, and PataKuribo.

◆ hitCallback_YoshiHipAttk()

virtual bool Enemy::hitCallback_YoshiHipAttk ( ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other )
virtual

Reimplemented in Bomhei, KuriboBase, and PataKuribo.

◆ hitCallback_PenguinSlide()

virtual bool Enemy::hitCallback_PenguinSlide ( ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other )
virtual

Reimplemented in Birikyu, Boss, and Koton.

◆ hitCallback_Cannon()

virtual bool Enemy::hitCallback_Cannon ( ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other )
virtual

Reimplemented in Birikyu.

◆ hitCallback_AttackUnk25()

virtual bool Enemy::hitCallback_AttackUnk25 ( ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other )
virtual

◆ hitCallback_Shell()

virtual bool Enemy::hitCallback_Shell ( ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other )
virtual

Reimplemented in Boss, CarryEnemy, and Koton.

◆ hitCallback_Fire()

virtual bool Enemy::hitCallback_Fire ( ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other )
virtual

Reimplemented in Birikyu, Bomhei, Boss, Koton, and MechaKoopa.

◆ hitCallback_Ice()

virtual bool Enemy::hitCallback_Ice ( ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other )
virtual

Reimplemented in Bomhei, Boss, BrosBase, CarryEnemy, Koton, and PataKuribo.

◆ hitCallback_YoshiBullet()

virtual bool Enemy::hitCallback_YoshiBullet ( ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other )
virtual

Reimplemented in BrosBase.

◆ hitCallback_YoshiFire()

virtual bool Enemy::hitCallback_YoshiFire ( ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other )
virtual

Reimplemented in Bomhei.

◆ hitCallback_ChibiYoshiUnk()

virtual bool Enemy::hitCallback_ChibiYoshiUnk ( ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other )
virtual

Reimplemented in KuriboBase.

◆ hitCallback_ChibiYoshiLight()

virtual bool Enemy::hitCallback_ChibiYoshiLight ( ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other )
virtual

Reimplemented in BrosBase.

◆ hitCallback_ChibiYoshiStar()

virtual bool Enemy::hitCallback_ChibiYoshiStar ( ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other )
virtual

◆ hitCallback_AttackUnk27()

virtual bool Enemy::hitCallback_AttackUnk27 ( bool * dead,
ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other )
virtual

Reimplemented in CarryEnemy.

◆ setDeathInfo_Quake()

virtual void Enemy::setDeathInfo_Quake ( s32 )
virtual

Reimplemented in Boss.

◆ setDeathInfo_IceBreak()

virtual void Enemy::setDeathInfo_IceBreak ( )
virtual

Reimplemented in Boss.

◆ setDeathInfo_Star()

virtual bool Enemy::setDeathInfo_Star ( ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other )
virtual

◆ isQuakeDamage()

virtual bool Enemy::isQuakeDamage ( )
virtual
Returns
Enemy is on ground and can be damaged by quake (e.g. POW block).

@endcode

Address: 0x0232E2EC

Reimplemented in Boss.

◆ setDeathSound_Fire()

virtual void Enemy::setDeathSound_Fire ( )
virtual

◆ setDeathSound_HipAttk()

virtual void Enemy::setDeathSound_HipAttk ( )
virtual

◆ fumiJumpSet()

virtual void Enemy::fumiJumpSet ( Actor * )
virtual

◆ fumiScoreSet()

virtual void Enemy::fumiScoreSet ( Actor * )
virtual

Reimplemented in Bomhei, and Boss.

◆ yoshiFumiJumpSet()

virtual void Enemy::yoshiFumiJumpSet ( Actor * )
virtual

◆ yoshiFumiScoreSet()

virtual void Enemy::yoshiFumiScoreSet ( Actor * )
virtual

◆ mameFumiJumpSet()

virtual void Enemy::mameFumiJumpSet ( Actor * )
virtual

◆ fumiSE()

virtual void Enemy::fumiSE ( Actor * )
virtual

◆ fumiEffect()

virtual void Enemy::fumiEffect ( Actor * )
virtual

◆ spinfumiSE()

virtual void Enemy::spinfumiSE ( Actor * )
virtual

◆ spinfumiEffect()

void Enemy::spinfumiEffect ( Actor * )

◆ mamefumiSE()

virtual void Enemy::mamefumiSE ( )
virtual

◆ mamefumiEffect()

virtual void Enemy::mamefumiEffect ( Actor * )
virtual

◆ yoshifumiSE()

virtual void Enemy::yoshifumiSE ( Actor * )
virtual

◆ hipatkEffect()

virtual void Enemy::hipatkEffect ( const sead::Vector3f & effect_pos)
virtual

◆ vf34C()

virtual void Enemy::vf34C ( )
virtual

◆ checkDispIn()

virtual bool Enemy::checkDispIn ( )
virtual
Returns
Enemy is inside the camera view.

@endcode

Address: 0x0232A2FC

◆ setAwaHit()

virtual void Enemy::setAwaHit ( Actor * awa)
virtual

Reimplemented in KuriboBase.

◆ awaCatchMove()

virtual void Enemy::awaCatchMove ( Actor * awa)
virtual

◆ setAwaCatchEnd()

virtual void Enemy::setAwaCatchEnd ( Actor * awa)
virtual

◆ setAwaInvalid()

virtual void Enemy::setAwaInvalid ( Actor * awa)
virtual

◆ ceilCheck()

bool Enemy::ceilCheck ( f32 pos_y,
ActorCollisionCheck * cc )
static

◆ normal_collcheck()

void Enemy::normal_collcheck ( ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other )
static

◆ fireballInvalid()

void Enemy::fireballInvalid ( ActorCollisionCheck * cc_other)
inlinestatic

◆ iceballInvalid()

void Enemy::iceballInvalid ( ActorCollisionCheck * cc_other)
static

◆ setDeathInfo_Fall() [1/2]

void Enemy::setDeathInfo_Fall ( DirType direction,
s32 player_no = -1,
ScoreMgr::ScoreType score_type = ScoreMgr::cScoreType_Invalid )

◆ setDeathInfo_Fall() [2/2]

void Enemy::setDeathInfo_Fall ( const sead::Vector2f * speeds,
DirType direction,
s32 player_no = -1,
ScoreMgr::ScoreType score_type = ScoreMgr::cScoreType_Invalid )

◆ setDeathInfo_Fumi() [1/2]

void Enemy::setDeathInfo_Fumi ( Actor * player,
const sead::Vector2f & speed,
const StateID & state_id )

◆ setDeathInfo_Fumi() [2/2]

void Enemy::setDeathInfo_Fumi ( Actor * player,
const sead::Vector2f & speed )
inline

◆ setDeathInfo_FumiFall()

void Enemy::setDeathInfo_FumiFall ( Actor * player,
const sead::Vector2f & speed )
inline

◆ setDeathInfo_FumiOther()

void Enemy::setDeathInfo_FumiOther ( Actor * player,
const sead::Vector2f & speed )
inline

◆ setDeathInfo_SpinFumi()

void Enemy::setDeathInfo_SpinFumi ( Actor * )

◆ setDeathInfo_YoshiFumi()

void Enemy::setDeathInfo_YoshiFumi ( Actor * )

◆ startSound()

void Enemy::startSound ( const char * name)

◆ fumiCheck()

FumiType Enemy::fumiCheck ( ActorCollisionCheck * cc_self,
ActorCollisionCheck * cc_other,
FumiSeType se_type )

Process a collision with a player and return which type occurred.

Parameters
se_typeWhich type of sounds/particles to play for this collision.

@endcode

Address: 0x02329B88

◆ calcComboPlFumiCnt()

s32 Enemy::calcComboPlFumiCnt ( Actor * player)

◆ bound()

void Enemy::bound ( f32 ,
f32 ,
f32  )

◆ calcMdl_Normal()

void Enemy::calcMdl_Normal ( )

◆ isDead()

bool Enemy::isDead ( ) const

◆ hitdamageEffect()

void Enemy::hitdamageEffect ( const sead::Vector3f & effect_pos)

◆ applyWaterRollDec()

Angle Enemy::applyWaterRollDec ( Angle ang)

◆ killIce()

void Enemy::killIce ( )
inline

◆ fumistepSE()

void Enemy::fumistepSE ( Actor * )
inline

◆ yoshifumistepSE()

void Enemy::yoshifumistepSE ( Actor * )
inline

◆ spinFumiJumpSet()

void Enemy::spinFumiJumpSet ( Actor * actor)
inline

◆ spinFumiScoreSet()

void Enemy::spinFumiScoreSet ( Actor * )

Member Data Documentation

◆ cDieFallInitSpeedX

const f32 Enemy::cDieFallInitSpeedX[cDirType_NumX]
static

◆ cFumiJumpSpeed

const f32 Enemy::cFumiJumpSpeed
static

◆ cDefaultGravity

const f32 Enemy::cDefaultGravity
static

◆ cDefaultMaxFallSpeed

const f32 Enemy::cDefaultMaxFallSpeed
static

◆ cDieFallInitSpeedY

const f32 Enemy::cDieFallInitSpeedY
static

◆ cDieFallMaxFallSpeed

const f32 Enemy::cDieFallMaxFallSpeed
static

◆ cDieFallGravity

const f32 Enemy::cDieFallGravity
static

◆ cBaseAngleY

const Angle Enemy::cBaseAngleY[cDirType_NumX]
static

Maps a 2D direction to a "facing" Y-angle.

Applies a slight rotational bias towards the camera that prevents the actor from facing perfectly perpendicular to the viewer. This ensures actors remain visually clear and recognizable when facing either direction.

Warning
Only indexable with cDirType_Right and cDirType_Left. Anything else is out of bounds.

@endcode

Address: 0x10200DD8

◆ cEnMuki

const s8 Enemy::cEnMuki[cDirType_NumX]
static

Maps a 2D direction to a sign multiplier (1 or -1).

Useful for compacting ternaries for left/right->negative/positive into a multiplication operation.

// Instead of branching:
float speed = (mDirection == cDirType_Right) ? 2.0f : -2.0f;
// Use multiplication:
float speed = cEnMuki[mDirection] * 2.0f;
@ cDirType_Right
Definition Direction.h:7
DirType mDirection
Definition Actor.h:479
static const s8 cEnMuki[cDirType_NumX]
Maps a 2D direction to a sign multiplier (1 or -1).
Definition Enemy.h:79
Warning
Only indexable with cDirType_Right and cDirType_Left. Anything else is out of bounds.

@endcode

Address: 0x10200DD8

◆ cNoHitPlayerTimerDefault

const s32 Enemy::cNoHitPlayerTimerDefault = 5
static

◆ mDeathInfo

EnemyDeathInfo Enemy::mDeathInfo
protected

◆ mNoHitPlayerTimer

sead::SafeArray< u16, 4 > Enemy::mNoHitPlayerTimer
protected

◆ mEnFlag

sead::BitFlag32 Enemy::mEnFlag
protected

◆ mIceMgr

IceMgr Enemy::mIceMgr
protected

◆ mChibiYoshiAwaData

EnemyChibiYoshiAwaData Enemy::mChibiYoshiAwaData
protected

◆ mFumiProc

EnemyFumiProc Enemy::mFumiProc
protected

◆ _186c

u16 Enemy::_186c
protected

◆ _186e

u16 Enemy::_186e
protected

◆ _1870

u32 Enemy::_1870
protected

◆ mDieFallDirection

u8 Enemy::mDieFallDirection
protected

◆ mPreIceDirection

u8 Enemy::mPreIceDirection
protected

◆ mCombo

Combo Enemy::mCombo
protected

◆ _187c

u8 Enemy::_187c
protected

◆ _187d

u8 Enemy::_187d
protected

◆ _187e

s8 Enemy::_187e
protected