2
0
mirror of https://github.com/AxioDL/metaforce.git synced 2025-12-09 01:07:43 +00:00

More gun implementations, and script objects

This commit is contained in:
2016-12-09 18:35:20 -08:00
parent be40ebc8db
commit 5793c8df87
25 changed files with 459 additions and 26 deletions

View File

@@ -8,6 +8,17 @@
namespace urde
{
enum class EGunState
{
Zero,
One,
FreeLook,
ComboFire,
Four,
Fidget,
Six,
Seven
};
class CGunController
{
@@ -15,11 +26,10 @@ class CGunController
CGSFreeLook x4_freeLook;
CGSComboFire x1c_comboFire;
CGSFidget x30_fidget;
u32 x50_ = 0;
EGunState x50_gunState = EGunState::Zero;
u32 x54_ = -1;
union
{
union {
struct
{
bool x58_24_ : 1;
@@ -27,10 +37,24 @@ class CGunController
};
u8 _dummy = 0;
};
public:
CGunController(CModelData& modelData);
};
public:
CGunController(CModelData& modelData) : x0_modelData(modelData), x58_24_(true) {}
void UnLoadFidget();
void LoadFidgetAnimAsync(CStateManager&, s32, s32, s32);
void GetFreeLookSetId() const;
bool IsFidgetLoaded() const;
bool IsComboOver() const;
void EnterFreeLook(CStateManager&, s32, s32);
void EnterComboFire(CStateManager&, s32);
void EnterFidget(CStateManager&, s32, s32, s32);
void EnterStruck(CStateManager&, float);
void EnterIdle(CStateManager&);
bool Update(float, CStateManager&);
void ReturnToDefault(CStateManager&, float);
void ReturnToBasePosition(CStateManager&, float);
void Reset();
};
}
#endif // __URDE_CGUNCONTROLLER_HPP__