| 1 | #pragma once |
| 2 | |
| 3 | #include <math/seadQuat.h> |
| 4 | #include <math/seadVector.h> |
| 5 | #include <prim/seadEnum.h> |
| 6 | |
| 7 | namespace al { |
| 8 | struct ActorInitInfo; |
| 9 | class LiveActor; |
| 10 | class HitSensor; |
| 11 | class SensorMsg; |
| 12 | } // namespace al |
| 13 | class Shine; |
| 14 | |
| 15 | namespace rs { |
| 16 | // TODO: Replace this with SEAD_ENUM_EX when its ValueArray constructor matches |
| 17 | SEAD_ENUM(ItemType, None = -1, Coin, Coin2D, CoinBlow, CoinBlowVeryLittle, , |
| 18 | , Coin3, Coin5, Coin10, Coin10Auto, Coin5Count, Coin100, LifeUpItem, |
| 19 | LifeUpItemBack, LifeUpItem2D, LifeMaxUpItem, LifeMaxUpItem2D, Shine, AirBubble, DotMarioCat, |
| 20 | KuriboMini3, KuriboMini8, CoinStackBound, Random); |
| 21 | |
| 22 | ItemType::ValueType getItemType(const al::ActorInitInfo& info); |
| 23 | ItemType::ValueType getItemType(const char* name); |
| 24 | bool isItemTypeKuriboMini(s32* out, s32 type); |
| 25 | |
| 26 | void initItemByPlacementInfo(al::LiveActor* actor, const al::ActorInitInfo& info, |
| 27 | bool isAppearAbove); |
| 28 | bool tryInitItemByPlacementInfo(al::LiveActor* actor, const al::ActorInitInfo& info, |
| 29 | bool isAppearAbove); |
| 30 | void initItem2DByPlacementInfo(al::LiveActor* actor, const al::ActorInitInfo& info); |
| 31 | bool tryInitItem2DByPlacementInfo(al::LiveActor* actor, const al::ActorInitInfo& info); |
| 32 | bool tryInitItem(al::LiveActor* actor, s32 itemType, const al::ActorInitInfo& info, |
| 33 | bool isAppearAbove); |
| 34 | |
| 35 | Shine* (const al::ActorInitInfo& info); |
| 36 | Shine* initShineByPlacementInfo(const al::ActorInitInfo& info); |
| 37 | Shine* tryInitLinkShine(const al::ActorInitInfo& info, const char* name, s32 linkIndex); |
| 38 | Shine* tryInitLinkShineHintPhoto(const al::ActorInitInfo& info, const char* name, s32 linkIndex); |
| 39 | Shine* initLinkShine(const al::ActorInitInfo& info, const char* name, s32 linkIndex); |
| 40 | Shine* initLinkShopShine(const al::ActorInitInfo& info, const char* name); |
| 41 | Shine* initLinkShineChipShine(const al::ActorInitInfo& info); |
| 42 | Shine* initLinkBossShine(const al::ActorInitInfo& info); |
| 43 | |
| 44 | void createShineEffectInsideObject(Shine* shine, const al::LiveActor* actor, |
| 45 | const al::ActorInitInfo& info); |
| 46 | |
| 47 | void (Shine* shine); |
| 48 | void (Shine* shine, const al::LiveActor* actor); |
| 49 | void (Shine* shine, const sead::Vector3f& trans); |
| 50 | void (Shine* shine); |
| 51 | void (Shine* shine, const al::LiveActor* actor); |
| 52 | void (Shine* shine, const sead::Vector3f& trans); |
| 53 | void (Shine* shine); |
| 54 | void appearPopupShineGrandByBoss(Shine* shine, s32 a2); |
| 55 | void appearWaitShine(Shine* shine); |
| 56 | void appearWaitShine(Shine* shine, const sead::Vector3f& trans); |
| 57 | |
| 58 | bool isEndAppearShine(const Shine* shine); |
| 59 | bool isGotShine(const Shine* shine); |
| 60 | bool isAliveShine(const Shine* shine); |
| 61 | bool isMainShine(const Shine* shine); |
| 62 | |
| 63 | void updateHintTrans(const Shine* shine, const sead::Vector3f& trans); |
| 64 | void appearShineAndJoinBossDemo(Shine* shine, const char* name, const sead::Quatf& quat, |
| 65 | const sead::Vector3f& trans); |
| 66 | void endShineBossDemo(Shine* shine); |
| 67 | void endShineBossDemoAndStartFall(Shine* shine, f32 a2); |
| 68 | |
| 69 | void setAppearItemFactorByMsg(const al::LiveActor* actor, const al::SensorMsg* msg, |
| 70 | const al::HitSensor* sensor); |
| 71 | void setAppearItemFactorAndOffsetByMsg(const al::LiveActor* actor, const al::SensorMsg* msg, |
| 72 | const al::HitSensor* sensor); |
| 73 | void setAppearItemFactorAndOffsetForCombo(const al::LiveActor* actor, const al::SensorMsg* msg, |
| 74 | const al::HitSensor* sensor, bool isSuperCombo); |
| 75 | void appearItemFromObj(al::LiveActor* actor, const sead::Vector3f& trans, const sead::Quatf& quat, |
| 76 | f32 offset); |
| 77 | void appearItemFromObj(al::LiveActor* actor, al::HitSensor* sensor, f32 offset); |
| 78 | void appearItemFromObj(al::LiveActor* actor, al::HitSensor* sensor, const sead::Vector3f& offset); |
| 79 | void appearItemFromObjGravity(al::LiveActor* actor, al::HitSensor* sensor, |
| 80 | const sead::Vector3f& offset); |
| 81 | void appearRandomItemFromObj(al::LiveActor* actor, al::HitSensor* sensor, f32 offset); |
| 82 | bool tryAppearMultiCoinFromObj(al::LiveActor* actor, const sead::Vector3f& trans, s32 step, |
| 83 | f32 offsetAbove); |
| 84 | bool tryAppearMultiCoinFromObj(al::LiveActor* actor, const sead::Vector3f& trans, |
| 85 | const sead::Quatf& quat, s32 step, f32 offsetAbove); |
| 86 | bool tryAppearMultiCoinFromObj(al::LiveActor* actor, al::HitSensor* sensor, s32 step, |
| 87 | f32 offsetAbove); |
| 88 | bool tryAppearMultiCoinFromObj(al::LiveActor* actor, al::HitSensor* sensor, s32 step, |
| 89 | const sead::Vector3f& offset); |
| 90 | |
| 91 | void syncCoin2DAnimFrame(al::LiveActor* actor, const char* name); |
| 92 | |
| 93 | const char* getStageCoinCollectArchiveName(const al::LiveActor* actor); |
| 94 | const char* getStageCoinCollectEmptyArchiveName(const al::LiveActor* actor); |
| 95 | const char* getStageCoinCollect2DArchiveName(const al::LiveActor* actor); |
| 96 | const char* getStageCoinCollect2DEmptyArchiveName(const al::LiveActor* actor); |
| 97 | |
| 98 | s32 getStageShineAnimFrame(const al::LiveActor* actor); |
| 99 | s32 getStageShineAnimFrame(const al::LiveActor* actor, s32 worldId); |
| 100 | s32 getStageShineAnimFrame(const al::LiveActor* actor, const char* stageName); |
| 101 | void setStageShineAnimFrame(al::LiveActor* actor, const char* stageName, s32 shineAnimFrame, |
| 102 | bool isMatAnim); |
| 103 | |
| 104 | const char* getStageShineArchiveName(const al::LiveActor* actor, const char* stageName); |
| 105 | const char* getStageShineEmptyArchiveName(const al::LiveActor* actor, const char* stageName); |
| 106 | |
| 107 | void setMaterialAsEmptyModel(al::LiveActor* actor); |
| 108 | void setProjectionMtxAsEmptyModel2d(al::LiveActor* actor, const sead::Vector2f& vec); |
| 109 | void addDemoRacePrizeCoin(al::LiveActor* actor); |
| 110 | |
| 111 | } // namespace rs |
| 112 | |
| 113 | namespace StageSceneFunction { |
| 114 | void appearPlayerDeadCoin(al::LiveActor* actor); |
| 115 | } |
| 116 | |