metaforce/Runtime/Weapon/WeaponCommon.hpp

74 lines
1.9 KiB
C++
Raw Normal View History

#ifndef __URDE_WEAPONCOMMON_HPP__
#define __URDE_WEAPONCOMMON_HPP__
#include "RetroTypes.hpp"
#include "DataSpec/DNACommon/Tweaks/ITweakPlayerGun.hpp"
2017-09-02 04:06:05 +00:00
#include "Audio/CSfxManager.hpp"
2017-08-26 04:36:25 +00:00
#include <set>
2017-09-04 02:22:46 +00:00
#include <Runtime/CPlayerState.hpp>
namespace urde
{
2017-08-26 04:36:25 +00:00
class CAnimData;
class CToken;
class CPrimitive;
2017-09-02 04:06:05 +00:00
class CStateManager;
enum class EWeaponType
{
None = -1,
Power = 0,
2017-05-20 07:41:49 +00:00
Ice = 1,
Wave = 2,
Plasma = 3,
Bomb = 4,
PowerBomb = 5,
Missile = 6,
BoostBall = 7,
Phazon = 8,
AI = 9,
PoisonWater = 10,
Lava = 11,
Hot = 12,
Unused1 = 13,
2017-08-20 05:23:22 +00:00
OrangePhazon = 14
};
2017-08-26 04:36:25 +00:00
namespace NWeaponTypes
{
enum class EGunAnimType
{
2017-09-02 04:06:05 +00:00
BasePosition,
Shoot,
ChargeUp,
ChargeLoop,
ChargeShoot,
2017-08-26 04:36:25 +00:00
FromMissile,
ToMissile,
2017-09-02 04:06:05 +00:00
MissileShoot,
2017-08-26 04:36:25 +00:00
MissileReload,
2017-08-31 02:42:37 +00:00
FromBeam,
2017-09-02 04:06:05 +00:00
ToBeam
2017-08-26 04:36:25 +00:00
};
void primitive_set_to_token_vector(const CAnimData& animData, const std::set<CPrimitive>& primSet,
std::vector<CToken>& tokensOut, bool preLock);
void unlock_tokens(std::vector<CToken>& anims);
void lock_tokens(std::vector<CToken>& anims);
bool are_tokens_ready(const std::vector<CToken>& anims);
2017-09-04 02:22:46 +00:00
void get_token_vector(const CAnimData& animData, int begin, int end, std::vector<CToken>& tokensOut, bool preLock);
void get_token_vector(const CAnimData& animData, int animIdx, std::vector<CToken>& tokensOut, bool preLock);
2017-09-02 04:06:05 +00:00
void do_sound_event(std::pair<u16, CSfxHandle>& sfxHandle, float& pitch, bool doPitchBend, u32 soundId,
float weight, u32 flags, float falloff, float maxDist, float minVol, float maxVol,
const zeus::CVector3f& posToCam, const zeus::CVector3f& pos, TAreaId aid,
CStateManager& mgr);
2017-09-04 02:22:46 +00:00
CAssetId get_asset_id_from_name(const char* name);
CPlayerState::EPlayerSuit get_current_suit(const CStateManager& mgr);
CSfxHandle play_sfx(u16 sfx, bool underwater, bool looped, float pan);
2017-08-26 04:36:25 +00:00
}
}
#endif // __URDE_WEAPONCOMMON_HPP__