-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added headers for Strollin' Stus and the classes it depends on #10
Merged
Merged
Changes from 5 commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
770649d
Added scripts to allow for small enemys and stus
Halleester 0a8ae62
Fix to Stu manager
Halleester c5191c2
Fixes
Halleester fc301ce
Updates to enemy and gooper blooper headers, added hamukuri headers a…
Halleester 22b54ee
Merge branch 'main' into hamukuri
Halleester 8ade33d
Fixed variable name
Halleester bd2fe8b
Fixed the var name for real
Halleester File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,142 @@ | ||
#pragma once | ||
|
||
#include <Dolphin/types.h> | ||
#include <JSystem/JDrama/JDRActor.hxx> | ||
#include <JSystem/JGeometry/JGMVec.hxx> | ||
#include <SMS/Enemy/WalkerEnemy.hxx> | ||
#include <SMS/MapObj/MapObjBase.hxx> | ||
#include <SMS/System/Params.hxx> | ||
|
||
struct THamuKuriSaveLoadParams : TWalkerEnemyParams { | ||
|
||
THamuKuriSaveLoadParams(const char *prm) | ||
: TWalkerEnemyParams(prm), SMS_TPARAM_INIT(mSLWaterCoeff, 25.0f), | ||
SMS_TPARAM_INIT(mSLWaterAttackCoeff, 2.0f), SMS_TPARAM_INIT(mSLFirstVelocityY, 8.0f), | ||
SMS_TPARAM_INIT(mSLVelocityRate, 0.8f), SMS_TPARAM_INIT(mSLBoundNum, 2), | ||
SMS_TPARAM_INIT(mSLSearchActorTimer, 500), SMS_TPARAM_INIT(mSLCanSearchDist, 800.0f), | ||
SMS_TPARAM_INIT(mSLJitabataTimer, 200), SMS_TPARAM_INIT(mSLFirstKickVelocityY, 2.0f), | ||
SMS_TPARAM_INIT(mSLFlyTimer, 500), SMS_TPARAM_INIT(mSLTrampleBonusNum, 3), | ||
SMS_TPARAM_INIT(mSLCrashBonusNum, 3), SMS_TPARAM_INIT(mSLSerialCrashFrame, 15), | ||
SMS_TPARAM_INIT(mSLKyoroTimer, 500) { | ||
load(prm); | ||
} | ||
|
||
TParamRT<f32> mSLWaterCoeff; | ||
TParamRT<f32> mSLWaterAttackCoeff; | ||
TParamRT<f32> mSLFirstVelocityY; | ||
TParamRT<f32> mSLVelocityRate; | ||
TParamRT<u32> mSLBoundNum; | ||
TParamRT<u32> mSLSearchActorTimer; | ||
TParamRT<f32> mSLCanSearchDist; | ||
TParamRT<u32> mSLJitabataTimer; | ||
TParamRT<f32> mSLFirstKickVelocityY; | ||
TParamRT<u32> mSLFlyTimer; | ||
TParamRT<u32> mSLTrampleBonusNum; | ||
TParamRT<u32> mSLCrashBonusNum; | ||
TParamRT<u32> mSLSerialCrashFrame; | ||
TParamRT<u32> mSLKyoroTimer; | ||
}; | ||
|
||
class THamuKuri : public TWalkerEnemy { | ||
|
||
public: | ||
THamuKuri(const char *); | ||
virtual ~THamuKuri(); | ||
|
||
virtual void attackToMario() override; | ||
virtual void behaveToFindMario() override; | ||
virtual void behaveToWater(THitActor *) override; | ||
virtual void bind() override; | ||
virtual void endHitWaterJump() override; | ||
virtual void genRandomItem() override; | ||
virtual const char **getBasNameTable() const override; | ||
virtual f32 getGravityY() const override; | ||
virtual Mtx44 *getTakingMtx() override; | ||
virtual void init(TLiveManager *) override; | ||
virtual void initAttacker(THitActor *) override; | ||
virtual bool isCollidMove(THitActor *) override; | ||
virtual u32 isFindMario(f32) override; | ||
virtual bool isHitValid(u32) override; //(ulong) | ||
virtual bool isResignationAttack() override; | ||
virtual void moveObject() override; | ||
virtual void reset() override; | ||
virtual void setAfterDeadEffect() override; | ||
virtual void setBckAnm(int) override; | ||
virtual void setDeadAnm() override; | ||
virtual void setGenerateAnm() override; | ||
virtual void setMActorAndKeeper() override; | ||
virtual void setRunAnm() override; | ||
virtual void setWaitAnm() override; | ||
virtual void setWalkAnm() override; | ||
virtual void walkBehavior(int, f32) override; | ||
|
||
virtual void setRollAnm(); | ||
virtual void setCrashAnm(); | ||
virtual u8 canDoJitabata(); // uint | ||
virtual void onHaveCap(); | ||
|
||
void forceRoll(JGeometry::TVec3<f32> &, bool); | ||
void jumpToSearchActor(); | ||
void makeCapFly(TMapObjBase *); | ||
/*f32 mCapGravityY; | ||
f32 mCapSpeed; | ||
f32 mLandAnimFrameNum; | ||
f32 mVGenerateGravityY;*/ | ||
void selectCapHolder(); | ||
void setBehaviour(); | ||
|
||
|
||
f32 _194; | ||
u32 hasCapOn; // 0x198 | ||
u32 _19C; // int | ||
u8 _1A0; | ||
u8 _1A1; | ||
u8 _1A2; | ||
u8 _1A3; | ||
u8 _1A4; | ||
u8 _1A5; | ||
u8 _1A6; //padding? | ||
u8 _1A7; //padding? | ||
u32 _1A8; // padding? | ||
|
||
u32 _1AC[0x34 / 4]; // unknown | ||
|
||
u32 _1E0; | ||
|
||
u32 _1E4[0xC / 4]; // Unknown | ||
|
||
u32 _1F0; | ||
u32 _1F4; //TNerveWalkerGenerate* | ||
u32 _1F8; | ||
|
||
u32 _1FC; // Unknown | ||
|
||
TVec3f _200; // 0x200 - 0x20B, detah particle related? | ||
}; | ||
|
||
extern THamuKuri *hamukurianm_bastable; | ||
|
||
class THamuKuriManager : public TSmallEnemyManager { | ||
public: | ||
THamuKuriManager(const char *); | ||
virtual ~THamuKuriManager(); | ||
|
||
virtual THamuKuri *createEnemyInstance() override; | ||
virtual void createModelData() override; | ||
virtual void load(JSUMemoryInputStream &) override; | ||
virtual void loadAfter() override; | ||
virtual void perform(u32, JDrama::TGraphics *) override; | ||
virtual void createAnmData() override; | ||
|
||
void checkSerialKill(); | ||
void requestSerialKill(THamuKuri *); | ||
void setSearchHamuKuri(); | ||
|
||
/*const f32 mSearchActSw;*/ | ||
|
||
u32 _60; // Something to do with 1up | ||
u32 _64; // Something to do with 1up | ||
u32 _68; // Something to do with 1up | ||
u32 _6C; | ||
u32 _70; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,171 @@ | ||
#pragma once | ||
|
||
#include <Dolphin/types.h> | ||
#include <SMS/Manager/EnemyManager.hxx> | ||
#include <SMS/Enemy/SpineEnemy.hxx> | ||
#include <SMS/System/Params.hxx> | ||
|
||
struct TSmallEnemyParams : TSpineEnemyParams { | ||
|
||
TSmallEnemyParams(const char *prm) | ||
: TSpineEnemyParams(prm), SMS_TPARAM_INIT(mSLJumpForce, 5.0f), | ||
SMS_TPARAM_INIT(mSLSearchLength, 600.0f), SMS_TPARAM_INIT(mSLSearchHeight, 600.0f), | ||
SMS_TPARAM_INIT(mSLSearchAware, 150.0f), SMS_TPARAM_INIT(mSLSearchAngle, 140.0f), | ||
SMS_TPARAM_INIT(mSLGiveUpLength, 1000.0f), SMS_TPARAM_INIT(mSLGiveUpHeight, 650.0f), | ||
SMS_TPARAM_INIT(mSLAttackWait, 0), SMS_TPARAM_INIT(mSLFreezeWait, 50), | ||
SMS_TPARAM_INIT(mSLDamageRadius, 115), SMS_TPARAM_INIT(mSLDamageHeight, 100), | ||
SMS_TPARAM_INIT(mSLAttackRadius, 90), SMS_TPARAM_INIT(mSLAttackHeight, 60), | ||
SMS_TPARAM_INIT(mSLTurnSpeedLow, 0.9f), SMS_TPARAM_INIT(mSLTurnSpeedHigh, 1.0f), | ||
SMS_TPARAM_INIT(mSLBodyScaleLow, 1.0f), SMS_TPARAM_INIT(mSLBodyScaleHigh, 1.6f), | ||
SMS_TPARAM_INIT(mSLGenItemRate, 10.0f), SMS_TPARAM_INIT(mSLGenEggRate, 50.0f), | ||
SMS_TPARAM_INIT(mSLPolluteRange, 5), SMS_TPARAM_INIT(mSLWaitTime, 100), | ||
SMS_TPARAM_INIT(mSLPolluteRMin, 1), SMS_TPARAM_INIT(mSLPolluteRMax, 3), | ||
SMS_TPARAM_INIT(mSLPolluteCycle, 300), SMS_TPARAM_INIT(mSLStampRange, 5), | ||
SMS_TPARAM_INIT(mSLPolluteInterval, 60), SMS_TPARAM_INIT(mSLGenerateOnlyDead, 0) { | ||
load(prm); | ||
} | ||
|
||
TParamRT<f32> mSLJumpForce; | ||
TParamRT<f32> mSLSearchLength; | ||
TParamRT<f32> mSLSearchHeight; | ||
TParamRT<f32> mSLSearchAware; | ||
TParamRT<f32> mSLSearchAngle; | ||
TParamRT<f32> mSLGiveUpLength; | ||
TParamRT<f32> mSLGiveUpHeight; | ||
TParamRT<u32> mSLAttackWait; | ||
TParamRT<u32> mSLFreezeWait; | ||
TParamRT<u32> mSLDamageRadius; | ||
TParamRT<u32> mSLDamageHeight; | ||
TParamRT<u32> mSLAttackRadius; | ||
TParamRT<u32> mSLAttackHeight; | ||
TParamRT<f32> mSLTurnSpeedLow; | ||
TParamRT<f32> mSLTurnSpeedHigh; | ||
TParamRT<f32> mSLBodyScaleLow; | ||
TParamRT<f32> mSLBodyScaleHigh; | ||
TParamRT<f32> mSLGenItemRate; | ||
TParamRT<f32> mSLGenEggRate; | ||
TParamRT<u8> mSLPolluteRange; | ||
TParamRT<u32> mSLWaitTime; | ||
TParamRT<u32> mSLPolluteRMin; | ||
TParamRT<u32> mSLPolluteRMax; | ||
TParamRT<u32> mSLPolluteCycle; | ||
TParamRT<u8> mSLStampRange; | ||
TParamRT<u32> mSLPolluteInterval; | ||
TParamRT<u8> mSLGenerateOnlyDead; | ||
}; | ||
|
||
class TSmallEnemy : public TSpineEnemy { | ||
|
||
public: | ||
TSmallEnemy(const char *name); | ||
~TSmallEnemy(); | ||
|
||
virtual void load(JSUMemoryInputStream &) override; | ||
virtual void perform(u32, JDrama::TGraphics *) override; | ||
virtual bool receiveMessage(THitActor *, u32) override; | ||
virtual void init(TLiveManager *) override; | ||
virtual void reset() override; | ||
virtual void moveObject() override; | ||
virtual void kill() override; | ||
virtual void updateAnmSound() override; | ||
virtual void loadAfter() override; | ||
|
||
virtual void genRandomItem(); | ||
virtual void genEventCoin(); | ||
virtual void generateItem(); | ||
virtual bool isEatenByYosshi(); | ||
virtual void setBehavior(); | ||
virtual void jumpBehavior(); | ||
virtual void behaveToWater(THitActor *); | ||
virtual u32 changeByJuice(); // unknown4 | ||
virtual u8 changeMove(); // uint | ||
virtual u32 getChangeBlockTime(); | ||
virtual void scalingChangeActor(); | ||
virtual void changeOut(); | ||
virtual void behaveToTaken(THitActor *); | ||
virtual void behaveToRelease(); | ||
virtual void setGenerateAnm(); | ||
virtual void setWalkAnm(); | ||
virtual void setDeadAnm(); | ||
virtual void setFreezeAnm(); | ||
virtual void setMeltAnm(); | ||
virtual void setWaitAnm(); | ||
virtual void setRunAnm(); | ||
virtual void attackToMario(); | ||
virtual void forceKill(); | ||
virtual void setMActorAndKeeper(); | ||
virtual void initAttacker(THitActor *); | ||
virtual bool isHitValid(u32); //(ulong) | ||
virtual bool isCollidMove(THitActor *); | ||
virtual bool isInhibitedForceMove(); | ||
virtual void endHitWaterJump(); | ||
virtual void sendAttackMsgToMario(); | ||
virtual void decHpByWater(THitActor *); | ||
virtual void setBckAnm(int); | ||
virtual void setDeadEffect(); | ||
virtual void setAfterDeadEffect(); | ||
virtual u32 doKeepDistance(); | ||
virtual void generateEffectColumWater(); | ||
virtual u32 isFindMario(f32); | ||
|
||
void behaveToHitOthers(THitActor *); | ||
void expandCollision(); | ||
u32 isEaten(); // 1 or 0 | ||
u32 isFindMarioFromParam(f32) const; | ||
u32 isHitWallInBound(); | ||
u32 isMarioInWater() const; | ||
|
||
/* const bool mIsAmpPolluter; | ||
const bool mIsPolluter;*/ | ||
|
||
u32 _150; | ||
f32 _154; | ||
f32 _158; | ||
u32 _15C; // int | ||
u32 _160; | ||
u8 _164; | ||
u8 _165; | ||
u8 _166; // padding? | ||
u8 _167; // padding? | ||
f32 _168; // code address | ||
f32 _16C; // code address | ||
f32 _170; // code address | ||
u32 _174; | ||
u32 _178; | ||
u32 _17C; | ||
u32 _180; | ||
u8 _184; | ||
u8 _185; | ||
u8 _186; // padding? | ||
u8 _187; // padding? | ||
f32 _188; // code address | ||
u32 _18C; | ||
u32 _190; // code address, seems to be called for setting an anm index? | ||
}; | ||
|
||
class TSmallEnemyManager : public TEnemyManager { | ||
public: | ||
TSmallEnemyManager(const char *); | ||
virtual ~TSmallEnemyManager(); | ||
|
||
virtual void createEnemies(int) override; | ||
virtual void load(JSUMemoryInputStream &) override; | ||
virtual void createModelData() override; | ||
virtual void loadAfter() override; | ||
|
||
virtual void initSetEnemies(); | ||
|
||
int getHolder(int); | ||
|
||
/*const f32 mBlockMoveSpeed; | ||
const f32 mBlockWaitMoveY; | ||
const u32 mBlockWaitTime; | ||
const f32 mBlockXZScale; | ||
const f32 mBlockYScale; | ||
const u32 mChangeBlockTime; | ||
const u8 mTestJuiceType;*/ | ||
|
||
u32 _54; // code executed after adding enemies | ||
u32 _58; // something texStamp Replated | ||
u32 _5C; // 60 | ||
}; |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
mHasCapOn