RuntimeCommon: Make use of bitfield initializers where applicable

Continues and finishes the migration towards initializing all bitfield
members where applicable
This commit is contained in:
Lioncash 2020-04-21 03:22:41 -04:00
parent d3a44259c3
commit fa3e639a9d
129 changed files with 467 additions and 866 deletions

View File

@ -60,16 +60,16 @@ public:
s16 xa_prio;
// CSfxHandle xc_handle;
TAreaId x10_area;
bool x14_24_isActive : 1;
bool x14_25_isPlaying : 1;
bool x14_24_isActive : 1 = true;
bool x14_25_isPlaying : 1 = false;
bool x14_26_looped : 1;
bool x14_27_inArea : 1;
bool x14_28_isReleased : 1;
bool x14_27_inArea : 1 = true;
bool x14_28_isReleased : 1 = false;
bool x14_29_useAcoustics : 1;
protected:
bool m_isEmitter : 1;
bool m_isClosed : 1;
bool m_isEmitter : 1 = false;
bool m_isClosed : 1 = false;
public:
virtual ~CBaseSfxWrapper() = default;
@ -112,14 +112,8 @@ public:
CBaseSfxWrapper(bool looped, s16 prio, /*const CSfxHandle& handle,*/ bool useAcoustics, TAreaId area)
: xa_prio(prio)
, /*xc_handle(handle),*/ x10_area(area)
, x14_24_isActive(true)
, x14_25_isPlaying(false)
, x14_26_looped(looped)
, x14_27_inArea(true)
, x14_28_isReleased(false)
, x14_29_useAcoustics(useAcoustics)
, m_isEmitter(false)
, m_isClosed(false) {}
, x14_29_useAcoustics(useAcoustics) {}
};
class CSfxEmitterWrapper : public CBaseSfxWrapper {

View File

@ -446,9 +446,9 @@ public:
private:
dspadpcm_header x0_header;
std::string x60_fileName; // arg1
bool x70_24_unclaimed : 1;
bool x70_25_headerReadCancelled : 1;
u8 x70_26_headerReadState : 2; // 0: not read 1: reading 2: read
bool x70_24_unclaimed : 1 = true;
bool x70_25_headerReadCancelled : 1 = false;
u8 x70_26_headerReadState : 2 = 0; // 0: not read 1: reading 2: read
s8 x71_companionRight = -1;
s8 x72_companionLeft = -1;
float x73_volume = 0.f;
@ -460,13 +460,11 @@ private:
static std::array<CDSPStreamManager, 4> g_Streams;
public:
CDSPStreamManager() : x70_24_unclaimed(true), x70_25_headerReadCancelled(false), x70_26_headerReadState(0) {}
CDSPStreamManager() = default;
CDSPStreamManager(std::string_view fileName, s32 handle, float volume, bool oneshot)
: x60_fileName(fileName)
, x70_24_unclaimed(!CDvdFile::FileExists(fileName))
, x70_25_headerReadCancelled(false)
, x70_26_headerReadState(0)
, x73_volume(volume)
, x74_oneshot(oneshot)
, x78_handleId(handle) {}

View File

@ -57,34 +57,11 @@ CBallCamera::CBallCamera(TUniqueId uid, TUniqueId watchedId, const zeus::CTransf
, x250_ballCameraCentroidDistanceSpring(g_tweakBall->GetBallCameraCentroidDistanceSpringConstant(),
g_tweakBall->GetBallCameraCentroidDistanceSpringMax(),
g_tweakBall->GetBallCameraCentroidDistanceSpringTardis())
, x37c_camSpline(false)
, x41c_ballCameraChaseSpring(g_tweakBall->GetBallCameraChaseSpringConstant(),
g_tweakBall->GetBallCameraChaseSpringMax(), g_tweakBall->GetBallCameraChaseSpringTardis())
, x448_ballCameraBoostSpring(g_tweakBall->GetBallCameraBoostSpringConstant(),
g_tweakBall->GetBallCameraBoostSpringMax(),
g_tweakBall->GetBallCameraBoostSpringTardis()) {
x18c_24_ = true;
x18c_25_chaseAllowed = true;
x18c_26_boostAllowed = true;
x18c_27_obscureAvoidance = true;
x18c_28_volumeCollider = true;
x18c_29_clampAttitude = false;
x18c_30_clampAzimuth = false;
x18c_31_clearLOS = true;
x18d_24_prevClearLOS = true;
x18d_25_avoidGeometryFull = false;
x18d_26_lookAtBall = false;
x18d_27_forceProcessing = false;
x18d_28_obtuseDirection = false;
x18d_29_noElevationInterp = false;
x18d_30_directElevation = false;
x18d_31_overrideLookDir = false;
x18e_24_noElevationVelClamp = false;
x18e_25_noSpline = false;
x18e_26_ = false;
x18e_27_nearbyDoorClosed = false;
x18e_28_nearbyDoorClosing = false;
x190_curMinDistance = g_tweakBall->GetBallCameraMinSpeedDistance();
x194_targetMinDistance = g_tweakBall->GetBallCameraMinSpeedDistance();
x198_maxDistance = g_tweakBall->GetBallCameraMaxSpeedDistance();

View File

@ -79,27 +79,27 @@ private:
};
EBallCameraBehaviour x188_behaviour = EBallCameraBehaviour::Default;
bool x18c_24_ : 1;
bool x18c_25_chaseAllowed : 1;
bool x18c_26_boostAllowed : 1;
bool x18c_27_obscureAvoidance : 1;
bool x18c_28_volumeCollider : 1;
bool x18c_29_clampAttitude : 1;
bool x18c_30_clampAzimuth : 1;
bool x18c_31_clearLOS : 1;
bool x18d_24_prevClearLOS : 1;
bool x18d_25_avoidGeometryFull : 1;
bool x18d_26_lookAtBall : 1;
bool x18d_27_forceProcessing : 1;
bool x18d_28_obtuseDirection : 1;
bool x18d_29_noElevationInterp : 1;
bool x18d_30_directElevation : 1;
bool x18d_31_overrideLookDir : 1;
bool x18e_24_noElevationVelClamp : 1;
bool x18e_25_noSpline : 1;
bool x18e_26_ : 1;
bool x18e_27_nearbyDoorClosed : 1;
bool x18e_28_nearbyDoorClosing : 1;
bool x18c_24_ : 1 = true;
bool x18c_25_chaseAllowed : 1 = true;
bool x18c_26_boostAllowed : 1 = true;
bool x18c_27_obscureAvoidance : 1 = true;
bool x18c_28_volumeCollider : 1 = true;
bool x18c_29_clampAttitude : 1 = false;
bool x18c_30_clampAzimuth : 1 = false;
bool x18c_31_clearLOS : 1 = true;
bool x18d_24_prevClearLOS : 1 = true;
bool x18d_25_avoidGeometryFull : 1 = false;
bool x18d_26_lookAtBall : 1 = false;
bool x18d_27_forceProcessing : 1 = false;
bool x18d_28_obtuseDirection : 1 = false;
bool x18d_29_noElevationInterp : 1 = false;
bool x18d_30_directElevation : 1 = false;
bool x18d_31_overrideLookDir : 1 = false;
bool x18e_24_noElevationVelClamp : 1 = false;
bool x18e_25_noSpline : 1 = false;
bool x18e_26_ : 1 = false;
bool x18e_27_nearbyDoorClosed : 1 = false;
bool x18e_28_nearbyDoorClosing : 1 = false;
float x190_curMinDistance;
float x194_targetMinDistance;
float x198_maxDistance;
@ -153,7 +153,7 @@ private:
bool x370_24_reevalSplineEnd : 1;
float x374_splineCtrl = 0.f;
float x378_splineCtrlRange;
CCameraSpline x37c_camSpline;
CCameraSpline x37c_camSpline{false};
CMaterialList x3c8_collisionExcludeList = {EMaterialTypes::NoStepLogic};
bool x3d0_24_camBehindFloorOrWall : 1;
float x3d4_elevInterpTimer = 0.f;

View File

@ -21,13 +21,7 @@
namespace urde {
float CCameraManager::sFirstPersonFOV = 55.f;
CCameraManager::CCameraManager(TUniqueId curCameraId)
: x0_curCameraId(curCameraId)
, xa0_24_pendingRumble(false)
, xa0_25_rumbling(false)
, xa0_26_inWater(false)
, x3b8_24_(false)
, x3b8_25_(false) {
CCameraManager::CCameraManager(TUniqueId curCameraId) : x0_curCameraId(curCameraId) {
CSfxManager::AddListener(CSfxManager::ESfxChannels::Game, zeus::skZero3f, zeus::skZero3f, {1.f, 0.f, 0.f},
{0.f, 0.f, 1.f}, 50.f, 50.f, 1000.f, 1, 1.f);
sFirstPersonFOV = g_tweakGame->GetFirstPersonFOV();

View File

@ -40,9 +40,9 @@ class CCameraManager {
float x94_fogDensityFactor = 1.f;
float x98_fogDensitySpeed = 0.f;
float x9c_fogDensityFactorTarget = 1.f;
bool xa0_24_pendingRumble : 1;
bool xa0_25_rumbling : 1;
bool xa0_26_inWater : 1;
bool xa0_24_pendingRumble : 1 = false;
bool xa0_25_rumbling : 1 = false;
bool xa0_26_inWater : 1 = false;
TUniqueId xa2_spindleCamId = kInvalidUniqueId;
TUniqueId xa4_pathCamId = kInvalidUniqueId;
TUniqueId xa6_camHintId = kInvalidUniqueId;
@ -50,8 +50,8 @@ class CCameraManager {
rstl::reserved_vector<std::pair<s32, TUniqueId>, 64> xac_cameraHints;
rstl::reserved_vector<TUniqueId, 64> x2b0_inactiveCameraHints;
rstl::reserved_vector<TUniqueId, 64> x334_activeCameraHints;
bool x3b8_24_ : 1;
bool x3b8_25_ : 1;
bool x3b8_24_ : 1 = false;
bool x3b8_25_ : 1 = false;
float x3bc_curFov = 60.f;
void SetPathCamera(TUniqueId id, CStateManager& mgr);

View File

@ -20,7 +20,6 @@ CFirstPersonCamera::CFirstPersonCamera(TUniqueId uid, const zeus::CTransform& xf
nearz, farz, aspect, watchedObj, false, 0)
, x188_orbitCameraSpeed(orbitCameraSpeed)
, x190_gunFollowXf(xf) {
x1c6_24_deferBallTransitionProcessing = false;
DataSpec::DNAMP1::tw_fov->addListener([this](hecl::CVar* cv) { _fovListener(cv); });
}

View File

@ -14,7 +14,7 @@ class CFirstPersonCamera : public CGameCamera {
zeus::CTransform x190_gunFollowXf;
float x1c0_pitch = 0.f;
TUniqueId x1c4_pitchId = kInvalidUniqueId;
bool x1c6_24_deferBallTransitionProcessing : 1;
bool x1c6_24_deferBallTransitionProcessing : 1 = false;
zeus::CVector3f x1c8_closeInVec;
float x1d4_closeInTimer = 0.f;
void _fovListener(hecl::CVar* cv);

View File

@ -18,7 +18,6 @@ CGameCamera::CGameCamera(TUniqueId uid, bool active, std::string_view name, cons
, x164_zfar(zfar)
, x168_aspect(aspect)
, x16c_controllerIdx(controllerIdx)
, x170_24_perspDirty(true)
, x170_25_disablesInput(disableInput)
, x180_perspInterpStartFov(fovy)
, x184_perspInterpEndFov(fovy) {

View File

@ -22,7 +22,7 @@ protected:
float x164_zfar;
float x168_aspect;
u32 x16c_controllerIdx;
bool x170_24_perspDirty : 1;
bool x170_24_perspDirty : 1 = true;
bool x170_25_disablesInput : 1;
float x174_delayTime = 0.f;
float x178_perspInterpRemTime = 0.f;

View File

@ -14,8 +14,7 @@ CInterpolationCamera::CInterpolationCamera(TUniqueId uid, const zeus::CTransform
: CGameCamera(uid, false, "Interpolation Camera",
CEntityInfo(kInvalidAreaId, CEntity::NullConnectionList, kInvalidEditorId), xf,
CCameraManager::ThirdPersonFOV(), CCameraManager::NearPlane(), CCameraManager::FarPlane(),
CCameraManager::Aspect(), kInvalidUniqueId, false, 0)
, x1d8_24_sinusoidal{false} {}
CCameraManager::Aspect(), kInvalidUniqueId, false, 0) {}
void CInterpolationCamera::Accept(IVisitor& visitor) { visitor.Visit(this); }

View File

@ -16,7 +16,7 @@ class CInterpolationCamera : public CGameCamera {
float x1d0_positionSpeed = 0.f;
float x1d4_rotationSpeed = 0.f;
float x1d8_ = 0.f;
bool x1d8_24_sinusoidal : 1;
bool x1d8_24_sinusoidal : 1 = false;
float x1dc_closeInAngle = M_PIF * 2.f;
bool InterpolateSinusoidal(zeus::CTransform& xf, const zeus::CVector3f& targetOrigin, const zeus::CVector3f& lookPos,

View File

@ -18,17 +18,10 @@ s32 CActorLights::sFrameSchedulerCount = 0;
CActorLights::CActorLights(u32 areaUpdateFramePeriod, const zeus::CVector3f& actorPosBias, int maxDynamicLights,
int maxAreaLights, bool ambientChannelOverflow, bool layer2, bool disableWorldLights,
float positionUpdateThreshold)
: x298_24_dirty(true)
, x298_25_castShadows(true)
, x298_26_hasAreaLights(false)
, x298_27_findShadowLight(false)
, x298_28_inArea(!disableWorldLights && maxAreaLights > 0)
: x298_28_inArea(!disableWorldLights && maxAreaLights > 0)
, x298_29_ambienceGenerated(ambientChannelOverflow)
, x298_30_layer2(layer2)
, x298_31_disableWorldLights(disableWorldLights)
, x299_24_inBrightLight(true)
, x299_25_useBrightLightLag(false)
, x299_26_ambientOnly(false)
, x2a8_areaUpdateFramePeriod(areaUpdateFramePeriod)
, x2ac_actorPosBias(actorPosBias)
, x2b8_maxAreaLights(maxAreaLights)

View File

@ -20,17 +20,17 @@ class CActorLights {
std::vector<CLight> x144_dynamicLights;
zeus::CColor x288_ambientColor = zeus::skBlack;
TAreaId x294_aid = kInvalidAreaId;
bool x298_24_dirty : 1;
bool x298_25_castShadows : 1;
bool x298_26_hasAreaLights : 1;
bool x298_27_findShadowLight : 1;
bool x298_24_dirty : 1 = true;
bool x298_25_castShadows : 1 = true;
bool x298_26_hasAreaLights : 1 = false;
bool x298_27_findShadowLight : 1 = false;
bool x298_28_inArea : 1;
bool x298_29_ambienceGenerated : 1;
bool x298_30_layer2 : 1;
bool x298_31_disableWorldLights : 1;
bool x299_24_inBrightLight : 1;
bool x299_25_useBrightLightLag : 1;
bool x299_26_ambientOnly : 1;
bool x299_24_inBrightLight : 1 = true;
bool x299_25_useBrightLightLag : 1 = false;
bool x299_26_ambientOnly : 1 = false;
bool x29a_findNearestDynamicLights = false;
s32 x29c_shadowLightArrIdx = -1;
s32 x2a0_shadowLightIdx = -1;

View File

@ -55,14 +55,6 @@ CAnimData::CAnimData(CAssetId id, const CCharacterInfo& character, int defaultAn
, x1fc_transMgr(std::move(transMgr))
, x204_charIdx(charIdx)
, x208_defaultAnim(defaultAnim)
, x220_24_animating(false)
, x220_25_loop(false)
, x220_26_aligningPos(false)
, x220_27_(false)
, x220_28_(false)
, x220_29_animationJustStarted(false)
, x220_30_poseBuilt(false)
, x220_31_poseCached(false)
, x224_pose(layout->GetSegIdList().GetList().size())
, x2fc_poseBuilder(CLayoutDescription{layout})
, m_drawInstCount(drawInstCount) {

View File

@ -124,14 +124,14 @@ private:
u32 x214_passedParticleCount = 0;
u32 x218_passedSoundCount = 0;
s32 x21c_particleLightIdx = 0;
bool x220_24_animating : 1;
bool x220_25_loop : 1;
bool x220_26_aligningPos : 1;
bool x220_27_ : 1;
bool x220_28_ : 1;
bool x220_29_animationJustStarted : 1;
bool x220_30_poseBuilt : 1;
bool x220_31_poseCached : 1;
bool x220_24_animating : 1 = false;
bool x220_25_loop : 1 = false;
bool x220_26_aligningPos : 1 = false;
bool x220_27_ : 1 = false;
bool x220_28_ : 1 = false;
bool x220_29_animationJustStarted : 1 = false;
bool x220_30_poseBuilt : 1 = false;
bool x220_31_poseCached : 1 = false;
CPoseAsTransforms x224_pose;
CHierarchyPoseBuilder x2fc_poseBuilder;

View File

@ -9,10 +9,7 @@ s32 CAnimTreeTweenBase::sAdvancementDepth = 0;
CAnimTreeTweenBase::CAnimTreeTweenBase(bool b1, const std::weak_ptr<CAnimTreeNode>& a,
const std::weak_ptr<CAnimTreeNode>& b, int flags, std::string_view name)
: CAnimTreeDoubleChild(a, b, name), x1c_flags(flags) {
x20_24_b1 = b1;
x20_25_cullSelector = 0;
}
: CAnimTreeDoubleChild(a, b, name), x1c_flags(flags), x20_24_b1{b1} {}
void CAnimTreeTweenBase::VGetWeightedReaders(
rstl::reserved_vector<std::pair<float, std::weak_ptr<IAnimReader>>, 16>& out, float w) const {

View File

@ -14,7 +14,7 @@ class CAnimTreeTweenBase : public CAnimTreeDoubleChild {
protected:
int x1c_flags;
bool x20_24_b1 : 1;
u8 x20_25_cullSelector : 2;
u8 x20_25_cullSelector : 2 = 0;
public:
CAnimTreeTweenBase(bool, const std::weak_ptr<CAnimTreeNode>& a, const std::weak_ptr<CAnimTreeNode>& b, int,

View File

@ -15,12 +15,7 @@ CBodyController::CBodyController(CActor& actor, float turnSpeed, EBodyType bodyT
: x0_actor(actor)
, x2a4_bodyStateInfo(actor, bodyType)
, x2f4_bodyType(bodyType)
, x2fc_turnSpeed(turnSpeed)
, x300_24_animationOver(false)
, x300_25_active(false)
, x300_26_frozen(false)
, x300_27_hasBeenFrozen(false)
, x300_28_playDeathAnims(true) {
, x2fc_turnSpeed(turnSpeed) {
x2a4_bodyStateInfo.x18_bodyController = this;
}

View File

@ -28,11 +28,11 @@ class CBodyController {
EBodyType x2f4_bodyType;
s32 x2f8_curAnim = -1;
float x2fc_turnSpeed;
bool x300_24_animationOver : 1;
bool x300_25_active : 1;
bool x300_26_frozen : 1;
bool x300_27_hasBeenFrozen : 1;
bool x300_28_playDeathAnims : 1;
bool x300_24_animationOver : 1 = false;
bool x300_25_active : 1 = false;
bool x300_26_frozen : 1 = false;
bool x300_27_hasBeenFrozen : 1 = false;
bool x300_28_playDeathAnims : 1 = true;
float x304_intoFreezeDur = 0.f;
float x308_frozenDur = 0.f;
float x30c_breakoutDur = 0.f;

View File

@ -146,15 +146,12 @@ public:
class CBSLoopAttack : public CBodyState {
pas::ELoopState x4_state = pas::ELoopState::Invalid;
pas::ELoopAttackType x8_loopAttackType = pas::ELoopAttackType::Invalid;
bool xc_24_waitForAnimOver : 1;
bool xc_25_advance : 1;
bool xc_24_waitForAnimOver : 1 = false;
bool xc_25_advance : 1 = false;
pas::EAnimationState GetBodyStateTransition(float dt, const CBodyController& bc) const;
public:
CBSLoopAttack() {
xc_24_waitForAnimOver = false;
xc_25_advance = false;
}
CBSLoopAttack() = default;
bool CanShoot() const override { return true; }
void Start(CBodyController& bc, CStateManager& mgr) override;
pas::EAnimationState UpdateBody(float dt, CBodyController& bc, CStateManager& mgr) override;
@ -164,12 +161,12 @@ public:
class CBSLoopReaction : public CBodyState {
pas::ELoopState x4_state = pas::ELoopState::Invalid;
pas::EReactionType x8_reactionType = pas::EReactionType::Invalid;
bool xc_24_loopHit : 1;
bool xc_24_loopHit : 1 = false;
pas::EAnimationState GetBodyStateTransition(float dt, const CBodyController& bc) const;
bool PlayExitAnimation(CBodyController& bc, CStateManager& mgr) const;
public:
CBSLoopReaction() { xc_24_loopHit = false; }
CBSLoopReaction() = default;
void Start(CBodyController& bc, CStateManager& mgr) override;
pas::EAnimationState UpdateBody(float dt, CBodyController& bc, CStateManager& mgr) override;
void Shutdown(CBodyController&) override {}
@ -202,23 +199,18 @@ class CBSJump : public CBodyState {
zeus::CVector3f xc_waypoint1;
zeus::CVector3f x18_velocity;
zeus::CVector3f x24_waypoint2;
bool x30_24_bodyForceSet : 1;
bool x30_25_wallJump : 1;
bool x30_26_wallBounceRight : 1;
bool x30_27_wallBounceComplete : 1;
bool x30_28_startInJumpLoop : 1;
bool x30_24_bodyForceSet : 1 = false;
bool x30_25_wallJump : 1 = false;
bool x30_26_wallBounceRight : 1 = false;
bool x30_27_wallBounceComplete : 1 = false;
bool x30_28_startInJumpLoop : 1 = false;
pas::EAnimationState GetBodyStateTransition(float dt, const CBodyController& bc) const;
bool CheckForWallJump(CBodyController& bc, CStateManager& mgr);
void CheckForLand(CBodyController& bc, CStateManager& mgr);
void PlayJumpLoop(CStateManager& mgr, CBodyController& bc);
public:
CBSJump()
: x30_24_bodyForceSet(false)
, x30_25_wallJump(false)
, x30_26_wallBounceRight(false)
, x30_27_wallBounceComplete(false)
, x30_28_startInJumpLoop(false) {}
CBSJump() = default;
bool IsMoving() const override { return true; }
bool ApplyHeadTracking() const override { return false; }
bool CanShoot() const override;
@ -238,7 +230,7 @@ class CBSHurled : public CBodyState {
float x18_curTime = 0.f;
mutable zeus::CVector3f x1c_lastTranslation;
mutable float x28_landedDur = 0.f;
bool x2c_24_needsRecover : 1;
bool x2c_24_needsRecover : 1 = false;
pas::EAnimationState GetBodyStateTransition(float dt, CBodyController& bc) const;
void Recover(CStateManager& mgr, CBodyController& bc, pas::EHurledState state);
void PlayStrikeWallAnimation(CBodyController& bc, CStateManager& mgr);
@ -247,7 +239,7 @@ class CBSHurled : public CBodyState {
bool ShouldStartLand(float dt, CBodyController& bc) const;
public:
CBSHurled() { x2c_24_needsRecover = false; }
CBSHurled() = default;
bool IsMoving() const override { return true; }
bool IsInAir(const CBodyController&) const override { return true; }
bool ApplyHeadTracking() const override { return false; }
@ -278,13 +270,13 @@ public:
};
class CBSScripted : public CBodyState {
bool x4_24_loopAnim : 1;
bool x4_25_timedLoop : 1;
bool x4_24_loopAnim : 1 = false;
bool x4_25_timedLoop : 1 = false;
float x8_remTime = 0.f;
pas::EAnimationState GetBodyStateTransition(float dt, const CBodyController& bc) const;
public:
CBSScripted() : x4_24_loopAnim(false), x4_25_timedLoop(false) {}
CBSScripted() = default;
bool ApplyHeadTracking() const override { return false; }
void Start(CBodyController& bc, CStateManager& mgr) override;
pas::EAnimationState UpdateBody(float dt, CBodyController& bc, CStateManager& mgr) override;
@ -310,8 +302,8 @@ class CBSWallHang : public CBodyState {
pas::EWallHangState x4_state = pas::EWallHangState::Invalid;
TUniqueId x8_wpId = kInvalidUniqueId;
zeus::CVector3f xc_launchVel;
bool x18_24_launched : 1;
bool x18_25_needsExit : 1;
bool x18_24_launched : 1 = false;
bool x18_25_needsExit : 1 = false;
pas::EAnimationState GetBodyStateTransition(float dt, const CBodyController& bc) const;
void FixInPlace(CBodyController& bc);
bool CheckForLand(CBodyController& bc, CStateManager& mgr);
@ -319,7 +311,7 @@ class CBSWallHang : public CBodyState {
void SetLaunchVelocity(CBodyController& bc);
public:
CBSWallHang() : x18_24_launched(false), x18_25_needsExit(false) {}
CBSWallHang() = default;
bool IsMoving() const override { return true; }
bool CanShoot() const override { return x4_state == pas::EWallHangState::WallHang; }
bool IsInAir(const CBodyController& bc) const override;

View File

@ -63,24 +63,15 @@ class CBCJumpCmd : public CBodyStateCmd {
pas::EJumpType x8_type = pas::EJumpType::Normal;
zeus::CVector3f xc_waypoint1;
zeus::CVector3f x18_waypoint2;
bool x24_24_wallJump : 1;
bool x24_25_startInJumpLoop : 1;
bool x24_24_wallJump : 1 = false;
bool x24_25_startInJumpLoop : 1 = false;
public:
explicit CBCJumpCmd() : CBodyStateCmd(EBodyStateCmd::Jump) {
x24_24_wallJump = false;
x24_25_startInJumpLoop = false;
}
explicit CBCJumpCmd() : CBodyStateCmd(EBodyStateCmd::Jump) {}
explicit CBCJumpCmd(const zeus::CVector3f& wp1, pas::EJumpType type, bool startInLoop = false)
: CBodyStateCmd(EBodyStateCmd::Jump), x8_type(type), xc_waypoint1(wp1) {
x24_24_wallJump = false;
x24_25_startInJumpLoop = startInLoop;
}
: CBodyStateCmd(EBodyStateCmd::Jump), x8_type(type), xc_waypoint1(wp1), x24_25_startInJumpLoop{startInLoop} {}
explicit CBCJumpCmd(const zeus::CVector3f& wp1, const zeus::CVector3f& wp2, pas::EJumpType type)
: CBodyStateCmd(EBodyStateCmd::Jump), x8_type(type), xc_waypoint1(wp1), x18_waypoint2(wp2) {
x24_24_wallJump = true;
x24_25_startInJumpLoop = false;
}
: CBodyStateCmd(EBodyStateCmd::Jump), x8_type(type), xc_waypoint1(wp1), x18_waypoint2(wp2), x24_24_wallJump{true} {}
pas::EJumpType GetJumpType() const { return x8_type; }
const zeus::CVector3f& GetJumpTarget() const { return xc_waypoint1; }
const zeus::CVector3f& GetSecondJumpTarget() const { return x18_waypoint2; }
@ -92,30 +83,22 @@ class CBCGenerateCmd : public CBodyStateCmd {
pas::EGenerateType x8_type = pas::EGenerateType::Invalid;
zeus::CVector3f xc_targetPos;
s32 x18_animId = -1;
bool x1c_24_targetTransform : 1;
bool x1c_25_overrideAnim : 1;
bool x1c_24_targetTransform : 1 = false;
bool x1c_25_overrideAnim : 1 = false;
public:
explicit CBCGenerateCmd() : CBodyStateCmd(EBodyStateCmd::Generate) {
x1c_24_targetTransform = false;
x1c_25_overrideAnim = false;
}
explicit CBCGenerateCmd() : CBodyStateCmd(EBodyStateCmd::Generate) {}
explicit CBCGenerateCmd(pas::EGenerateType type)
: CBodyStateCmd(EBodyStateCmd::Generate), x8_type(type) {
x1c_24_targetTransform = false;
x1c_25_overrideAnim = false;
}
: CBodyStateCmd(EBodyStateCmd::Generate), x8_type(type) {}
explicit CBCGenerateCmd(pas::EGenerateType type, s32 animId)
: CBodyStateCmd(EBodyStateCmd::Generate), x8_type(type), x18_animId(animId) {
x1c_24_targetTransform = false;
x1c_25_overrideAnim = animId != -1;
}
: CBodyStateCmd(EBodyStateCmd::Generate), x8_type(type), x18_animId(animId), x1c_25_overrideAnim{animId != -1} {}
explicit CBCGenerateCmd(pas::EGenerateType type, const zeus::CVector3f& vec, bool targetTransform = false,
bool overrideAnim = false)
: CBodyStateCmd(EBodyStateCmd::Generate), x8_type(type), xc_targetPos(vec) {
x1c_24_targetTransform = targetTransform;
x1c_25_overrideAnim = overrideAnim;
}
: CBodyStateCmd(EBodyStateCmd::Generate)
, x8_type(type)
, xc_targetPos(vec)
, x1c_24_targetTransform{targetTransform}
, x1c_25_overrideAnim{overrideAnim} {}
pas::EGenerateType GetGenerateType() const { return x8_type; }
const zeus::CVector3f& GetExitTargetPos() const { return xc_targetPos; }
bool HasExitTargetPos() const { return x1c_24_targetTransform; }
@ -206,20 +189,14 @@ public:
class CBCScriptedCmd : public CBodyStateCmd {
s32 x8_anim = -1;
bool xc_24_loopAnim : 1;
bool xc_25_timedLoop : 1;
bool xc_24_loopAnim : 1 = false;
bool xc_25_timedLoop : 1 = false;
float x10_loopDur = 0.f;
public:
explicit CBCScriptedCmd() : CBodyStateCmd(EBodyStateCmd::Scripted) {
xc_24_loopAnim = false;
xc_25_timedLoop = false;
}
explicit CBCScriptedCmd() : CBodyStateCmd(EBodyStateCmd::Scripted) {}
explicit CBCScriptedCmd(int i, bool b1, bool b2, float f)
: CBodyStateCmd(EBodyStateCmd::Scripted), x8_anim(i), x10_loopDur(f) {
xc_24_loopAnim = b1;
xc_25_timedLoop = b2;
}
: CBodyStateCmd(EBodyStateCmd::Scripted), x8_anim(i), xc_24_loopAnim{b1}, xc_25_timedLoop{b2}, x10_loopDur(f) {}
s32 GetAnimId() const { return x8_anim; }
bool IsLooped() const { return xc_24_loopAnim; }
bool GetUseLoopDuration() const { return xc_25_timedLoop; }

View File

@ -15,8 +15,6 @@ CBoneTracking::CBoneTracking(const CAnimData& animData, std::string_view bone,
: x14_segId(animData.GetCharLayoutInfo().GetSegIdFromString(bone))
, x1c_maxTrackingAngle(maxTrackingAngle)
, x20_angSpeed(angSpeed)
, x36_24_active(false)
, x36_25_hasTrackedRotation(false)
, x36_26_noParent(True(flags & EBoneTrackingFlags::NoParent))
, x36_27_noParentOrigin(True(flags & EBoneTrackingFlags::NoParentOrigin))
, x36_28_noHorizontalAim(True(flags & EBoneTrackingFlags::NoHorizontalAim))

View File

@ -33,8 +33,8 @@ class CBoneTracking {
float x20_angSpeed;
std::optional<zeus::CVector3f> x24_targetPosition;
TUniqueId x34_target = kInvalidUniqueId;
bool x36_24_active : 1;
bool x36_25_hasTrackedRotation : 1;
bool x36_24_active : 1 = false;
bool x36_25_hasTrackedRotation : 1 = false;
bool x36_26_noParent : 1;
bool x36_27_noParentOrigin : 1;
bool x36_28_noHorizontalAim : 1;

View File

@ -21,10 +21,10 @@ class CIkChain {
zeus::CQuaternion x24_holdRot;
zeus::CVector3f x34_holdPos;
float x40_time = 0.f;
bool x44_24_activated : 1;
bool x44_24_activated : 1 = false;
public:
CIkChain() : x44_24_activated(false) {}
CIkChain() = default;
bool GetActive() const { return x44_24_activated; }
void Update(float);

View File

@ -25,16 +25,14 @@ CModelData::~CModelData() = default;
CModelData::CModelData() {}
CModelData CModelData::CModelDataNull() { return CModelData(); }
CModelData::CModelData(const CStaticRes& res, int instCount)
: x0_scale(res.GetScale()), x14_24_renderSorted(false), x14_25_sortThermal(false), m_drawInstCount(instCount) {
CModelData::CModelData(const CStaticRes& res, int instCount) : x0_scale(res.GetScale()), m_drawInstCount(instCount) {
x1c_normalModel = g_SimplePool->GetObj({SBIG('CMDL'), res.GetId()});
if (!x1c_normalModel)
Log.report(logvisor::Fatal, FMT_STRING("unable to find CMDL {}"), res.GetId());
m_normalModelInst = x1c_normalModel->MakeNewInstance(0, instCount);
}
CModelData::CModelData(const CAnimRes& res, int instCount)
: x0_scale(res.GetScale()), x14_24_renderSorted(false), x14_25_sortThermal(false), m_drawInstCount(instCount) {
CModelData::CModelData(const CAnimRes& res, int instCount) : x0_scale(res.GetScale()), m_drawInstCount(instCount) {
TToken<CCharacterFactory> factory = g_CharFactoryBuilder->GetFactory(res);
x10_animData =
factory->CreateCharacter(res.GetCharacterNodeId(), res.CanLoop(), factory, res.GetDefaultAnim(), instCount);

View File

@ -62,8 +62,8 @@ class CModelData {
zeus::CVector3f x0_scale;
bool xc_ = false;
std::unique_ptr<CAnimData> x10_animData;
bool x14_24_renderSorted : 1;
bool x14_25_sortThermal : 1;
bool x14_24_renderSorted : 1 = false;
bool x14_25_sortThermal : 1 = false;
zeus::CColor x18_ambientColor;
TLockedToken<CModel> x1c_normalModel;

View File

@ -10,10 +10,7 @@
namespace urde {
CParticleDatabase::CParticleDatabase() {
xb4_24_updatesEnabled = true;
xb4_25_anySystemsDrawnWithModel = false;
}
CParticleDatabase::CParticleDatabase() = default;
void CParticleDatabase::CacheParticleDesc(const SObjectTag& tag) {}

View File

@ -28,8 +28,8 @@ class CParticleDatabase {
std::map<std::string, std::unique_ptr<CParticleGenInfo>> x78_rendererDraw;
std::map<std::string, std::unique_ptr<CParticleGenInfo>> x8c_firstDraw;
std::map<std::string, std::unique_ptr<CParticleGenInfo>> xa0_lastDraw;
bool xb4_24_updatesEnabled : 1;
bool xb4_25_anySystemsDrawnWithModel : 1;
bool xb4_24_updatesEnabled : 1 = true;
bool xb4_25_anySystemsDrawnWithModel : 1 = false;
static void SetModulationColorAllActiveEffectsForParticleDB(
const zeus::CColor& color, std::map<std::string, std::unique_ptr<CParticleGenInfo>>& map);

View File

@ -62,9 +62,6 @@ CRagDoll::CRagDoll(float normalGravity, float floatingGravity, float overTime, u
: x44_normalGravity(normalGravity)
, x48_floatingGravity(floatingGravity)
, x50_overTimer(overTime)
, x68_24_prevMovingSlowly(false)
, x68_25_over(false)
, x68_26_primed(false)
, x68_27_continueSmallMovements(bool(flags & 0x1))
, x68_28_noOverTimer(bool(flags & 0x2))
, x68_29_noAiCollision(bool(flags & 0x4)) {}

View File

@ -26,15 +26,12 @@ protected:
zeus::CVector3f x20_velocity;
zeus::CVector3f x2c_impactResponseDelta;
float x38_impactFrameVel = 0.f;
bool x3c_24_impactPending : 1;
bool x3c_25_ : 1;
bool x3c_24_impactPending : 1 = false;
bool x3c_25_ : 1 = false;
public:
CRagDollParticle(CSegId id, const zeus::CVector3f& curPos, float radius, const zeus::CVector3f& prevPos)
: x0_id(id), x4_curPos(curPos), x10_radius(radius), x14_prevPos(prevPos) {
x3c_24_impactPending = false;
x3c_25_ = false;
}
: x0_id(id), x4_curPos(curPos), x10_radius(radius), x14_prevPos(prevPos) {}
CSegId GetBone() const { return x0_id; }
const zeus::CVector3f& GetPosition() const { return x4_curPos; }
zeus::CVector3f& Position() { return x4_curPos; }
@ -94,9 +91,9 @@ protected:
float x54_impactVel = 0.f;
zeus::CVector3f x58_averageVel;
float x64_angTimer = 0.f;
bool x68_24_prevMovingSlowly : 1;
bool x68_25_over : 1;
bool x68_26_primed : 1;
bool x68_24_prevMovingSlowly : 1 = false;
bool x68_25_over : 1 = false;
bool x68_26_primed : 1 = false;
bool x68_27_continueSmallMovements : 1;
bool x68_28_noOverTimer : 1;
bool x68_29_noAiCollision : 1;

View File

@ -166,9 +166,7 @@ CMovingAABoxComponents::CMovingAABoxComponents(const zeus::CAABox& aabb, const z
}
}
CMetroidAreaCollider::COctreeLeafCache::COctreeLeafCache(const CAreaOctTree& octTree) : x0_octTree(octTree) {
x908_24_overflow = false;
}
CMetroidAreaCollider::COctreeLeafCache::COctreeLeafCache(const CAreaOctTree& octTree) : x0_octTree(octTree) {}
void CMetroidAreaCollider::COctreeLeafCache::AddLeaf(const CAreaOctTree::Node& node) {
if (x4_nodeCache.size() == x4_nodeCache.capacity()) {

View File

@ -120,7 +120,7 @@ public:
friend class CMetroidAreaCollider;
const CAreaOctTree& x0_octTree;
rstl::reserved_vector<CAreaOctTree::Node, 64> x4_nodeCache;
bool x908_24_overflow : 1;
bool x908_24_overflow : 1 = false;
public:
explicit COctreeLeafCache(const CAreaOctTree& octTree);
@ -173,12 +173,11 @@ public:
class CAreaCollisionCache {
zeus::CAABox x0_aabb;
rstl::reserved_vector<CMetroidAreaCollider::COctreeLeafCache, 3> x18_leafCaches;
bool x1b40_24_leafOverflow : 1;
bool x1b40_25_cacheOverflow : 1;
bool x1b40_24_leafOverflow : 1 = false;
bool x1b40_25_cacheOverflow : 1 = false;
public:
explicit CAreaCollisionCache(const zeus::CAABox& aabb)
: x0_aabb(aabb), x1b40_24_leafOverflow(false), x1b40_25_cacheOverflow(false) {}
explicit CAreaCollisionCache(const zeus::CAABox& aabb) : x0_aabb(aabb) {}
void ClearCache();
const zeus::CAABox& GetCacheBounds() const { return x0_aabb; }
void SetCacheBounds(const zeus::CAABox& aabb) { x0_aabb = aabb; }

View File

@ -681,18 +681,8 @@ void CBooRenderer::LoadBallFade() {
}
CBooRenderer::CBooRenderer(IObjectStore& store, IFactory& resFac)
: x8_factory(resFac), xc_store(store), x2a8_thermalRand(20)
, x318_24_refectionDirty(false)
, x318_25_drawWireframe(false)
, x318_26_requestRGBA6(false)
, x318_27_currentRGBA6(false)
, x318_28_disableFog(false)
, x318_29_thermalVisor(false)
, x318_30_inAreaDraw(false)
, x318_31_persistRGBA6(false)
, m_thermalHotPass(false) {
: x8_factory(resFac), xc_store(store), x2a8_thermalRand(20) {
g_Renderer = this;
xee_24_ = true;
m_staticEntropy = store.GetObj("RandomStaticEntropy");

View File

@ -105,7 +105,7 @@ class CBooRenderer final : public IRenderer {
u32 xe0_pvsAreaIdx = 0;
// boo::ITextureS* xe4_blackTex = nullptr;
bool xee_24_ : 1;
bool xee_24_ : 1 = true;
boo::ObjToken<boo::ITexture> m_clearTexture;
boo::ObjToken<boo::ITexture> m_blackTexture;
@ -152,15 +152,15 @@ class CBooRenderer final : public IRenderer {
// std::unique_ptr<CTexture> x314_phazonSuitMask;
CPhazonSuitFilter m_phazonSuitFilter;
bool x318_24_refectionDirty : 1;
bool x318_25_drawWireframe : 1;
bool x318_26_requestRGBA6 : 1;
bool x318_27_currentRGBA6 : 1;
bool x318_28_disableFog : 1;
bool x318_29_thermalVisor : 1;
bool x318_30_inAreaDraw : 1;
bool x318_31_persistRGBA6 : 1;
bool m_thermalHotPass : 1;
bool x318_24_refectionDirty : 1 = false;
bool x318_25_drawWireframe : 1 = false;
bool x318_26_requestRGBA6 : 1 = false;
bool x318_27_currentRGBA6 : 1 = false;
bool x318_28_disableFog : 1 = false;
bool x318_29_thermalVisor : 1 = false;
bool x318_30_inAreaDraw : 1 = false;
bool x318_31_persistRGBA6 : 1 = false;
bool m_thermalHotPass : 1 = false;
void GenerateFogVolumeRampTex(boo::IGraphicsDataFactory::Context& ctx);
void GenerateSphereRampTex(boo::IGraphicsDataFactory::Context& ctx);

View File

@ -6,7 +6,7 @@
namespace urde {
class CDrawablePlaneObject : public CDrawable {
friend class Buckets;
u16 x24_targetBucket;
u16 x24_targetBucket = 0;
float x28_farDist;
zeus::CPlane x2c_plane;
bool x3c_24_invertTest : 1;
@ -15,10 +15,11 @@ class CDrawablePlaneObject : public CDrawable {
public:
CDrawablePlaneObject(EDrawableType dtype, float closeDist, float farDist, const zeus::CAABox& aabb, bool invertTest,
const zeus::CPlane& plane, bool zOnly, void* data)
: CDrawable(dtype, 0, closeDist, aabb, data), x24_targetBucket(0), x28_farDist(farDist), x2c_plane(plane) {
x3c_24_invertTest = invertTest;
x3c_25_zOnly = zOnly;
}
: CDrawable(dtype, 0, closeDist, aabb, data)
, x28_farDist(farDist)
, x2c_plane(plane)
, x3c_24_invertTest{invertTest}
, x3c_25_zOnly{zOnly} {}
const zeus::CPlane& GetPlane() const { return x2c_plane; }
};
} // namespace urde

View File

@ -55,9 +55,7 @@ CLight::CLight(const zeus::CVector3f& pos, const zeus::CVector3f& dir, const zeu
, x2c_distQ(distQ)
, x30_angleC(angleC)
, x34_angleL(angleL)
, x38_angleQ(angleQ)
, x4c_24_intensityDirty(true)
, x4c_25_radiusDirty(true) {}
, x38_angleQ(angleQ) {}
CLight::CLight(ELightType type, const zeus::CVector3f& pos, const zeus::CVector3f& dir, const zeus::CColor& color,
float cutoff)
@ -65,9 +63,7 @@ CLight::CLight(ELightType type, const zeus::CVector3f& pos, const zeus::CVector3
, xc_dir(dir)
, x18_color(color)
, x1c_type(type)
, x20_spotCutoff(cutoff)
, x4c_24_intensityDirty(true)
, x4c_25_radiusDirty(true) {
, x20_spotCutoff(cutoff) {
switch (type) {
case ELightType::Spot: {
const float cosCutoff = std::cos(zeus::degToRad(cutoff));

View File

@ -37,16 +37,13 @@ class CLight {
u32 x40_lightId = 0; // Serves as unique key
mutable float x44_cachedRadius = 0.f;
mutable float x48_cachedIntensity = 0.f;
mutable bool x4c_24_intensityDirty : 1;
mutable bool x4c_25_radiusDirty : 1;
mutable bool x4c_24_intensityDirty : 1 = true;
mutable bool x4c_25_radiusDirty : 1 = true;
float CalculateLightRadius() const;
public:
CLight() {
x4c_24_intensityDirty = true;
x4c_25_radiusDirty = true;
}
CLight() = default;
CLight(const zeus::CVector3f& pos, const zeus::CVector3f& dir, const zeus::CColor& color, float distC, float distL,
float distQ, float angleC, float angleL, float angleQ);

View File

@ -143,8 +143,8 @@ private:
zeus::CAABox x20_aabb;
CBooSurface* x38_firstUnsortedSurface = nullptr;
CBooSurface* x3c_firstSortedSurface = nullptr;
bool x40_24_texturesLoaded : 1;
bool x40_25_modelVisible : 1;
bool x40_24_texturesLoaded : 1 = false;
bool x40_25_modelVisible : 1 = false;
u8 x41_mask;
u32 x44_areaInstanceIdx = UINT32_MAX;

View File

@ -178,8 +178,6 @@ CBooModel::CBooModel(TToken<CModel>& token, CModel* parent, std::vector<CBooSurf
, m_pipelines(&shader.m_shaders)
, x1c_textures(shader.x0_textures)
, x20_aabb(aabb)
, x40_24_texturesLoaded(false)
, x40_25_modelVisible(0)
, x41_mask(renderMask)
, m_staticVbo(vbo)
, m_staticIbo(ibo) {

View File

@ -143,8 +143,6 @@ CMoviePlayer::CMoviePlayer(const char* path, float preLoadSeconds, bool loop, bo
: CDvdFile(path)
, xec_preLoadSeconds(preLoadSeconds)
, xf4_24_loop(loop)
, xf4_25_hasAudio(false)
, xf4_26_fieldFlip(false)
, m_deinterlace(deinterlace) {
/* Read THP header information */
u8 buf[64];

View File

@ -100,8 +100,8 @@ private:
float xec_preLoadSeconds;
u32 xf0_preLoadFrames = 0;
bool xf4_24_loop : 1;
bool xf4_25_hasAudio : 1;
bool xf4_26_fieldFlip : 1;
bool xf4_25_hasAudio : 1 = false;
bool xf4_26_fieldFlip : 1 = false;
bool m_deinterlace : 1;
u32 xf8_ = 0;
u32 xfc_fieldIndex = 0;

View File

@ -12,8 +12,6 @@ CRainSplashGenerator::CRainSplashGenerator(const zeus::CVector3f& scale, u32 max
: x14_scale(scale), x2c_minZ(minZ) {
x30_alpha = std::min(1.f, alpha);
x44_genRate = std::min(maxSplashes, genRate);
x48_24 = false;
x48_25_raining = true;
x0_rainSplashes.reserve(maxSplashes);
CGraphics::CommitResources([&](boo::IGraphicsDataFactory::Context& ctx) {
for (u32 i = 0; i < maxSplashes; ++i)

View File

@ -56,8 +56,8 @@ class CRainSplashGenerator {
u32 x3c_queueHead = 0;
u32 x40_queueSize = 0;
u32 x44_genRate;
bool x48_24 : 1;
bool x48_25_raining : 1;
bool x48_24 : 1 = false;
bool x48_25_raining : 1 = true;
void UpdateRainSplashRange(CStateManager& mgr, int start, int end, float dt);
void UpdateRainSplashes(CStateManager& mgr, float magnitude, float dt);
void DoDraw(const zeus::CTransform& xf);

View File

@ -6,11 +6,7 @@
namespace urde {
CSimpleShadow::CSimpleShadow(float scale, float userAlpha, float maxObjHeight, float displacement)
: x30_scale(scale), x38_userAlpha(userAlpha), x40_maxObjHeight(maxObjHeight), x44_displacement(displacement) {
x48_24_collision = false;
x48_25_alwaysCalculateRadius = true;
x48_26_radiusCalculated = false;
}
: x30_scale(scale), x38_userAlpha(userAlpha), x40_maxObjHeight(maxObjHeight), x44_displacement(displacement) {}
zeus::CAABox CSimpleShadow::GetMaxShadowBox(const zeus::CAABox& aabb) const {
float extent = x34_radius * x30_scale;

View File

@ -19,9 +19,9 @@ class CSimpleShadow {
float x3c_heightAlpha = 1.f;
float x40_maxObjHeight;
float x44_displacement;
bool x48_24_collision : 1;
bool x48_25_alwaysCalculateRadius : 1;
bool x48_26_radiusCalculated : 1;
bool x48_24_collision : 1 = false;
bool x48_25_alwaysCalculateRadius : 1 = true;
bool x48_26_radiusCalculated : 1 = false;
std::optional<CTexturedQuadFilter> m_filter;
public:

View File

@ -52,7 +52,6 @@ constexpr zeus::CColor ArtifactPostColor{1.f, 0.63f, 0.02f, 1.f};
CArtifactDoll::CArtifactDoll() {
x10_lights.resize(2, CLight::BuildDirectional(zeus::skForward, zeus::skWhite));
x20_actorLights = std::make_unique<CActorLights>(8, zeus::skZero3f, 4, 4, false, false, false, 0.1f);
x28_24_loaded = false;
x0_models.reserve(ArtifactPieceModels.size());
for (const char* const model : ArtifactPieceModels) {
x0_models.emplace_back(g_SimplePool->GetObj(model));

View File

@ -17,7 +17,7 @@ class CArtifactDoll {
std::vector<CLight> x10_lights;
std::unique_ptr<CActorLights> x20_actorLights;
float x24_fader = 0.f;
bool x28_24_loaded : 1;
bool x28_24_loaded : 1 = false;
void UpdateActorLights();
public:

View File

@ -1487,7 +1487,7 @@ void CFrontEndUI::SNesEmulatorFrame::Draw(CSaveGameScreen* saveUi) const {
}
}
CFrontEndUI::SOptionsFrontEndFrame::SOptionsFrontEndFrame() : x134_24_visible(true), x134_25_exitOptions(false) {
CFrontEndUI::SOptionsFrontEndFrame::SOptionsFrontEndFrame() {
x4_frme = g_SimplePool->GetObj("FRME_OptionsFrontEnd");
x10_pauseScreen = g_SimplePool->GetObj("STRG_PauseScreen");
}

View File

@ -279,8 +279,8 @@ public:
float x38_rowPitch = 0.f;
CSfxHandle x3c_sliderSfx;
CRumbleGenerator x40_rumbleGen;
bool x134_24_visible : 1;
bool x134_25_exitOptions : 1;
bool x134_24_visible : 1 = true;
bool x134_25_exitOptions : 1 = false;
std::unique_ptr<CGameOptionsTouchBar> m_touchBar;
bool m_touchBarInValue = false;

View File

@ -10,7 +10,6 @@ CGameCubeDoll::CGameCubeDoll() {
x0_model = g_SimplePool->GetObj("CMDL_GameCube");
x8_lights.push_back(CLight::BuildDirectional(zeus::skForward, zeus::skWhite));
x18_actorLights = std::make_unique<CActorLights>(8, zeus::skZero3f, 4, 4, false, false, false, 0.1f);
x20_24_loaded = false;
}
void CGameCubeDoll::UpdateActorLights() {

View File

@ -16,7 +16,7 @@ class CGameCubeDoll {
std::vector<CLight> x8_lights;
std::unique_ptr<CActorLights> x18_actorLights;
float x1c_fader = 0.f;
bool x20_24_loaded : 1;
bool x20_24_loaded : 1 = false;
void UpdateActorLights();
public:

View File

@ -178,11 +178,7 @@ CInGameGuiManager::CInGameGuiManager(CStateManager& stateMgr, CArchitectureQueue
, x1c_rand(1234)
, x20_faceplateDecor(stateMgr)
, x50_deathDot(g_SimplePool->GetObj("TXTR_DeathDot"))
, x5c_pauseScreenDGRPs(LockPauseScreenDependencies())
, x1f8_24_(false)
, x1f8_25_playerAlive(true)
, x1f8_26_deferTransition(false)
, x1f8_27_exitSaveUI(true) {
, x5c_pauseScreenDGRPs(LockPauseScreenDependencies()) {
x1e0_helmetVisMode = g_tweakGui->GetHelmetVisMode();
x1e4_enableTargetingManager = g_tweakGui->GetEnableTargetingManager();
x1e8_enableAutoMapper = g_tweakGui->GetEnableAutoMapper();

View File

@ -95,10 +95,10 @@ private:
EHudVisMode x1ec_hudVisMode;
u32 x1f0_enablePlayerVisor;
float x1f4_visorStaticAlpha;
bool x1f8_24_ : 1;
bool x1f8_25_playerAlive : 1;
bool x1f8_26_deferTransition : 1;
bool x1f8_27_exitSaveUI : 1;
bool x1f8_24_ : 1 = false;
bool x1f8_25_playerAlive : 1 = true;
bool x1f8_26_deferTransition : 1 = false;
bool x1f8_27_exitSaveUI : 1 = true;
std::optional<CTexturedQuadFilter> m_deathRenderTexQuad;
std::optional<CTexturedQuadFilter> m_deathDotQuad;

View File

@ -14,10 +14,7 @@
namespace urde::MP1 {
CLogBookScreen::CLogBookScreen(const CStateManager& mgr, CGuiFrame& frame, const CStringTable& pauseStrg)
: CPauseScreenBase(mgr, frame, pauseStrg, true)
, x260_24_loaded(false)
, x260_25_inTextScroll(false)
, x260_26_exitTextScroll(false) {
: CPauseScreenBase(mgr, frame, pauseStrg, true) {
x19c_scanCompletes.resize(5);
x200_viewScans.resize(5);
x258_artifactDoll = std::make_unique<CArtifactDoll>();

View File

@ -30,9 +30,9 @@ class CLogBookScreen : public CPauseScreenBase {
LeavingPause = 1,
LeftPause = 2
} x25c_leavePauseState = ELeavePauseState::InPause;
bool x260_24_loaded : 1;
bool x260_25_inTextScroll : 1;
bool x260_26_exitTextScroll : 1;
bool x260_24_loaded : 1 = false;
bool x260_25_inTextScroll : 1 = false;
bool x260_26_exitTextScroll : 1 = false;
void InitializeLogBook();
void UpdateRightTitles();

View File

@ -18,9 +18,7 @@ CMFGame::CMFGame(const std::weak_ptr<CStateManager>& stateMgr, const std::weak_p
const CArchitectureQueue&)
: CMFGameBase("CMFGame")
, x14_stateManager(stateMgr.lock())
, x18_guiManager(guiMgr.lock())
, x2a_24_initialized(false)
, x2a_25_samusAlive(true) {
, x18_guiManager(guiMgr.lock()) {
static_cast<CMain&>(*g_Main).SetMFGameBuilt(true);
}
@ -258,8 +256,7 @@ void CMFGame::EnterMapScreen() {
x14_stateManager->SetInMapScreen(true);
}
CMFGameLoader::CMFGameLoader()
: CMFGameLoaderBase("CMFGameLoader"), x2c_24_initialized(false), x2c_25_transitionFinished(false) {
CMFGameLoader::CMFGameLoader() : CMFGameLoaderBase("CMFGameLoader") {
auto* m = static_cast<CMain*>(g_Main);
switch (m->GetFlowState()) {
case EFlowState::Default:

View File

@ -23,8 +23,8 @@ class CMFGame : public CMFGameBase {
float x20_cineSkipTime;
u32 x24_ = 0;
TUniqueId x28_skippedCineCam = kInvalidUniqueId;
bool x2a_24_initialized : 1;
bool x2a_25_samusAlive : 1;
bool x2a_24_initialized : 1 = false;
bool x2a_25_samusAlive : 1 = true;
CColoredQuadFilter m_fadeToBlack{EFilterType::Multiply};
@ -52,8 +52,8 @@ class CMFGameLoader : public CMFGameLoaderBase {
std::shared_ptr<CStateManager> x14_stateMgr;
std::shared_ptr<CInGameGuiManager> x18_guiMgr;
std::vector<CToken> x1c_loadList;
bool x2c_24_initialized : 1;
bool x2c_25_transitionFinished : 1;
bool x2c_24_initialized : 1 = false;
bool x2c_25_transitionFinished : 1 = false;
void MakeLoadDependencyList();

View File

@ -12,7 +12,6 @@
namespace urde::MP1 {
CMessageScreen::CMessageScreen(CAssetId msg, float delayTime) : x74_delayTime(delayTime) {
x78_24_exit = false;
x0_msg = g_SimplePool->GetObj({FOURCC('STRG'), msg});
xc_msgScreen = g_SimplePool->GetObj("FRME_MsgScreen");
}

View File

@ -36,7 +36,7 @@ class CMessageScreen {
u32 x6c_page = 0;
float x70_blurAmt = 0.f;
float x74_delayTime;
bool x78_24_exit : 1;
bool x78_24_exit : 1 = false;
public:
explicit CMessageScreen(CAssetId msg, float time);

View File

@ -10,10 +10,7 @@
namespace urde::MP1 {
COptionsScreen::COptionsScreen(const CStateManager& mgr, CGuiFrame& frame, const CStringTable& pauseStrg)
: CPauseScreenBase(mgr, frame, pauseStrg) {
x1a0_gameCube = std::make_unique<CGameCubeDoll>();
x2a0_24_inOptionBody = false;
}
: CPauseScreenBase(mgr, frame, pauseStrg), x1a0_gameCube{std::make_unique<CGameCubeDoll>()} {}
COptionsScreen::~COptionsScreen() { CSfxManager::SfxStop(x1a4_sliderSfx); }

View File

@ -15,7 +15,7 @@ class COptionsScreen : public CPauseScreenBase {
CSfxHandle x1a4_sliderSfx;
CRumbleGenerator x1a8_rumble;
float x29c_optionAlpha = 0.f;
bool x2a0_24_inOptionBody : 1;
bool x2a0_24_inOptionBody : 1 = false;
void UpdateOptionView();
void ResetOptionWidgetVisibility();

View File

@ -25,11 +25,6 @@ CPauseScreen::CPauseScreen(ESubScreen subscreen, const CDependencyGroup& suitDgr
x60_loadTok = g_ResFactory->LoadResourceAsync(frmeTag, x5c_frmePauseScreenBuf.get());
CSfxManager::SfxStart(SFXui_pause_screen_enter, 1.f, 0.f, false, 0x7f, false, kInvalidAreaId);
x7c_screens.resize(2);
m_returnDown = false;
m_nextDown = false;
m_backDown = false;
m_lDown = false;
m_rDown = false;
}
CPauseScreen::~CPauseScreen() {

View File

@ -44,16 +44,16 @@ private:
bool x90_resourcesLoaded = false;
bool x91_initialTransition = true;
bool m_returnClicked : 1;
bool m_nextClicked : 1;
bool m_backClicked : 1;
bool m_lClicked : 1;
bool m_rClicked : 1;
bool m_returnDown : 1;
bool m_nextDown : 1;
bool m_backDown : 1;
bool m_lDown : 1;
bool m_rDown : 1;
bool m_returnClicked : 1 = false;
bool m_nextClicked : 1 = false;
bool m_backClicked : 1 = false;
bool m_lClicked : 1 = false;
bool m_rClicked : 1 = false;
bool m_returnDown : 1 = false;
bool m_nextDown : 1 = false;
bool m_backDown : 1 = false;
bool m_lDown : 1 = false;
bool m_rDown : 1 = false;
std::unique_ptr<CPauseScreenBase> BuildPauseSubScreen(ESubScreen subscreen, const CStateManager& mgr,
CGuiFrame& frame) const;

View File

@ -19,22 +19,7 @@ namespace urde::MP1 {
CPauseScreenBase::CPauseScreenBase(const CStateManager& mgr, CGuiFrame& frame, const CStringTable& pauseStrg,
bool isLogBook)
: x4_mgr(mgr)
, x8_frame(frame)
, xc_pauseStrg(pauseStrg)
, x198_24_ready(false)
, x198_25_handledInput(false)
, x198_26_exitPauseScreen(false)
, x198_27_canDraw(false)
, x198_28_pulseTextArrowTop(false)
, x198_29_pulseTextArrowBottom(false)
, m_isLogBook(isLogBook)
, m_bodyUpClicked(false)
, m_bodyDownClicked(false)
, m_bodyClicked(false)
, m_leftClicked(false)
, m_rightClicked(false)
, m_playRightTableSfx(true) {
: x4_mgr(mgr), x8_frame(frame), xc_pauseStrg(pauseStrg), m_isLogBook(isLogBook) {
InitializeFrameGlue();
}

View File

@ -74,19 +74,19 @@ protected:
CGuiSliderGroup* x18c_slidergroup_slider = nullptr;
CGuiTableGroup* x190_tablegroup_double = nullptr;
CGuiTableGroup* x194_tablegroup_triple = nullptr;
bool x198_24_ready : 1;
bool x198_25_handledInput : 1;
bool x198_26_exitPauseScreen : 1;
bool x198_27_canDraw : 1;
bool x198_28_pulseTextArrowTop : 1;
bool x198_29_pulseTextArrowBottom : 1;
bool x198_24_ready : 1 = false;
bool x198_25_handledInput : 1 = false;
bool x198_26_exitPauseScreen : 1 = false;
bool x198_27_canDraw : 1 = false;
bool x198_28_pulseTextArrowTop : 1 = false;
bool x198_29_pulseTextArrowBottom : 1 = false;
bool m_isLogBook : 1;
bool m_bodyUpClicked : 1;
bool m_bodyDownClicked : 1;
bool m_bodyClicked : 1;
bool m_leftClicked : 1;
bool m_rightClicked : 1;
bool m_playRightTableSfx : 1;
bool m_bodyUpClicked : 1 = false;
bool m_bodyDownClicked : 1 = false;
bool m_bodyClicked : 1 = false;
bool m_leftClicked : 1 = false;
bool m_rightClicked : 1 = false;
bool m_playRightTableSfx : 1 = true;
void InitializeFrameGlue();
void ChangeMode(EMode mode, bool playSfx = true);

View File

@ -6,8 +6,7 @@
namespace urde::MP1 {
CPauseScreenBlur::CPauseScreenBlur()
: x4_mapLightQuarter(g_SimplePool->GetObj("TXTR_MapLightQuarter")), x50_24_blurring(false), x50_25_gameDraw(true) {}
CPauseScreenBlur::CPauseScreenBlur() : x4_mapLightQuarter(g_SimplePool->GetObj("TXTR_MapLightQuarter")) {}
void CPauseScreenBlur::OnNewInGameGuiState(EInGameGuiState state, CStateManager& stateMgr) {
switch (state) {

View File

@ -20,8 +20,8 @@ class CPauseScreenBlur {
EState x14_nextState = EState::InGame;
float x18_blurAmt = 0.f;
CCameraBlurPass x1c_camBlur;
bool x50_24_blurring : 1;
bool x50_25_gameDraw : 1;
bool x50_24_blurring : 1 = false;
bool x50_25_gameDraw : 1 = true;
CTexturedQuadFilter m_quarterFilter{EFilterType::Multiply, x4_mapLightQuarter};
CScanLinesFilterEven m_linesFilter{EFilterType::Multiply};

View File

@ -8,13 +8,7 @@ const char* kMovies[] = {"Video/wingame.thp", "Video/wingame_best.thp", "
bool CPlayMovie::IsResultsScreen(EWhichMovie which) { return int(which) <= 2; }
CPlayMovie::CPlayMovie(EWhichMovie which)
: CPlayMovieBase("CPlayMovie", kMovies[int(which)])
, x18_which(which)
, x78_24_(false)
, x78_25_(false)
, x78_26_resultsScreen(false)
, x78_27_(false) {
CPlayMovie::CPlayMovie(EWhichMovie which) : CPlayMovieBase("CPlayMovie", kMovies[int(which)]), x18_which(which) {
(void)x18_which;
}

View File

@ -20,10 +20,10 @@ public:
private:
EWhichMovie x18_which;
bool x78_24_ : 1;
bool x78_25_ : 1;
bool x78_26_resultsScreen : 1;
bool x78_27_ : 1;
bool x78_24_ : 1 = false;
bool x78_25_ : 1 = false;
bool x78_26_resultsScreen : 1 = false;
bool x78_27_ : 1 = false;
static bool IsResultsScreen(EWhichMovie which);

View File

@ -15,8 +15,6 @@
namespace urde::MP1 {
CPlayerVisor::CPlayerVisor(CStateManager&) : x108_newScanPane(EFilterType::Blend, CGraphics::g_SpareTexture.get()) {
x25_24_visorTransitioning = false;
x25_25_ = false;
xcc_scanFrameCorner = g_SimplePool->GetObj("CMDL_ScanFrameCorner");
xd8_scanFrameCenterSide = g_SimplePool->GetObj("CMDL_ScanFrameCenterSide");
xe4_scanFrameCenterTop = g_SimplePool->GetObj("CMDL_ScanFrameCenterTop");

View File

@ -31,8 +31,8 @@ class CPlayerVisor {
CPlayerState::EPlayerVisor x1c_curVisor = CPlayerState::EPlayerVisor::Combat;
CPlayerState::EPlayerVisor x20_nextVisor = CPlayerState::EPlayerVisor::Combat;
float x24_visorSfxVol = 1.f; // used to be u8
bool x25_24_visorTransitioning : 1;
bool x25_25_ : 1;
bool x25_24_visorTransitioning : 1 = false;
bool x25_25_ : 1 = false;
float x28_ = 0.f;
float x2c_scanDimInterp = 1.f;
EScanWindowState x30_prevState = EScanWindowState::NotInScanVisor;

View File

@ -100,13 +100,7 @@ CSamusDoll::CSamusDoll(const CDependencyGroup& suitDgrp, const CDependencyGroup&
, x44_suit(suit)
, x48_beam(beam)
, x270_24_hasSpiderBall(hasSpiderBall)
, x270_25_hasGrappleBeam(hasGrappleBeam)
, x270_26_pulseSuit(false)
, x270_27_pulseBeam(false)
, x270_28_pulseGrapple(false)
, x270_29_pulseBoots(false)
, x270_30_pulseVisor(false)
, x270_31_loaded(false) {
, x270_25_hasGrappleBeam(hasGrappleBeam) {
x70_fixedRot.rotateZ(M_PIF);
x90_userInterpRot = xb0_userRot = x70_fixedRot;
x1d4_spiderBallGlass = g_SimplePool->GetObj(SpiderBallGlassModels[size_t(suit)].first);

View File

@ -73,12 +73,12 @@ class CSamusDoll {
CSfxHandle x26c_zoomSfx;
bool x270_24_hasSpiderBall : 1;
bool x270_25_hasGrappleBeam : 1;
bool x270_26_pulseSuit : 1;
bool x270_27_pulseBeam : 1;
bool x270_28_pulseGrapple : 1;
bool x270_29_pulseBoots : 1;
bool x270_30_pulseVisor : 1;
bool x270_31_loaded : 1;
bool x270_26_pulseSuit : 1 = false;
bool x270_27_pulseBeam : 1 = false;
bool x270_28_pulseGrapple : 1 = false;
bool x270_29_pulseBoots : 1 = false;
bool x270_30_pulseVisor : 1 = false;
bool x270_31_loaded : 1 = false;
static constexpr zeus::CVector3f skInitialOffset{0.0f, 0.0f, 0.8f};
static CModelData BuildSuitModelData1(CPlayerState::EPlayerSuit suit);

View File

@ -23,9 +23,6 @@ CSamusHud::CSamusHud(CStateManager& stateMgr)
: x8_targetingMgr(stateMgr)
, x258_frmeHelmet(g_SimplePool->GetObj("FRME_Helmet"))
, x268_frmeBaseHud(g_SimplePool->GetObj("FRME_BaseHud"))
, x2e0_24_inFreeLook(false)
, x2e0_25_lookControlHeld(false)
, x2e0_26_latestFirstPerson(true)
, x2e0_27_energyLow(stateMgr.GetPlayer().IsEnergyLow(stateMgr))
, m_energyDrainFilter(g_tweakGui->GetEnergyDrainFilterAdditive() ? EFilterType::Add : EFilterType::Blend) {
x33c_lights = std::make_unique<CActorLights>(8, zeus::skZero3f, 4, 1, true, 0, 0, 0.1f);

View File

@ -95,9 +95,9 @@ class CSamusHud {
u32 x2d4_totalEnergyTanks = 0;
u32 x2d8_missileAmount = 0;
u32 x2dc_missileCapacity = 0;
bool x2e0_24_inFreeLook : 1;
bool x2e0_25_lookControlHeld : 1;
bool x2e0_26_latestFirstPerson : 1;
bool x2e0_24_inFreeLook : 1 = false;
bool x2e0_25_lookControlHeld : 1 = false;
bool x2e0_26_latestFirstPerson : 1 = true;
bool x2e0_27_energyLow : 1;
u32 x2e4_ = 0;
u32 x2e8_ = 0;

View File

@ -6,20 +6,7 @@
namespace urde {
CSlideShow::CSlideShow()
: CIOWin("SlideShow")
, x5c_slideA(*this)
, x90_slideB(*this)
, x130_(g_tweakSlideShow->GetX54())
, x134_24_(true)
, x134_25_(false)
, x134_26_(false)
, x134_27_(false)
, x134_28_disableInput(false)
, x134_29_(false)
, x134_30_(true)
, x134_31_(false)
, x135_24_(true) {
CSlideShow::CSlideShow() : CIOWin("SlideShow"), x130_(g_tweakSlideShow->GetX54()) {
const SObjectTag* font = g_ResFactory->GetResourceIdByName(g_tweakSlideShow->GetFont());
if (font) {
CGuiTextProperties propsA(false, true, EJustification::Center, EVerticalJustification::Bottom);

View File

@ -58,8 +58,8 @@ private:
float x58_ = 0.f;
*/
SSlideData x5c_slideA;
SSlideData x90_slideB;
SSlideData x5c_slideA{*this};
SSlideData x90_slideB{*this};
std::unique_ptr<CGuiTextSupport> xc4_textA;
std::unique_ptr<CGuiTextSupport> xc8_textB;
@ -87,15 +87,15 @@ private:
float x12c_ = 32.f;
*/
float x130_;
bool x134_24_ : 1;
bool x134_25_ : 1;
bool x134_26_ : 1;
bool x134_27_ : 1;
bool x134_28_disableInput : 1;
bool x134_29_ : 1;
bool x134_30_ : 1;
bool x134_31_ : 1;
bool x135_24_ : 1;
bool x134_24_ : 1 = true;
bool x134_25_ : 1 = false;
bool x134_26_ : 1 = false;
bool x134_27_ : 1 = false;
bool x134_28_disableInput : 1 = false;
bool x134_29_ : 1 = false;
bool x134_30_ : 1 = true;
bool x134_31_ : 1 = false;
bool x135_24_ : 1 = true;
bool LoadTXTRDep(std::string_view name);
static bool AreAllDepsLoaded(const std::vector<TLockedToken<CDependencyGroup>>& deps);

View File

@ -236,17 +236,7 @@ void CGameArchitectureSupport::specialKeyUp(boo::ESpecialKey key, boo::EModifier
CMain::CMain(IFactory* resFactory, CSimplePool* resStore, boo::IGraphicsDataFactory* gfxFactory,
boo::IGraphicsCommandQueue* cmdQ, const boo::ObjToken<boo::ITextureR>& spareTex)
: m_booSetter(gfxFactory, cmdQ, spareTex)
, x128_globalObjects(resFactory, resStore)
, x160_24_finished(false)
, x160_25_mfGameBuilt(false)
, x160_26_screenFading(false)
, x160_27_(false)
, x160_28_manageCard(false)
, x160_29_(false)
, x160_30_(false)
, x160_31_cardBusy(false)
, x161_24_gameFrameDrawn(false) {
: m_booSetter(gfxFactory, cmdQ, spareTex), x128_globalObjects(resFactory, resStore) {
xe4_gameplayResult = EGameplayResult::Playing;
g_Main = this;
}

View File

@ -217,15 +217,15 @@ private:
u32 x130_[10] = {1000000};
bool x160_24_finished : 1;
bool x160_25_mfGameBuilt : 1;
bool x160_26_screenFading : 1;
bool x160_27_ : 1;
bool x160_28_manageCard : 1;
bool x160_29_ : 1;
bool x160_30_ : 1;
bool x160_31_cardBusy : 1;
bool x161_24_gameFrameDrawn : 1;
bool x160_24_finished : 1 = false;
bool x160_25_mfGameBuilt : 1 = false;
bool x160_26_screenFading : 1 = false;
bool x160_27_ : 1 = false;
bool x160_28_manageCard : 1 = false;
bool x160_29_ : 1 = false;
bool x160_30_ : 1 = false;
bool x160_31_cardBusy : 1 = false;
bool x161_24_gameFrameDrawn : 1 = false;
std::unique_ptr<CGameArchitectureSupport> x164_archSupport;

View File

@ -23,7 +23,6 @@ CAtomicAlpha::CAtomicAlpha(TUniqueId uid, std::string_view name, const CEntityIn
CAssetId cmdl, bool invisible, bool b2)
: CPatterned(ECharacter::AtomicAlpha, uid, name, EFlavorType::Zero, info, xf, std::move(mData), pInfo,
EMovementType::Flyer, EColliderType::One, EBodyType::Flyer, actParms, EKnockBackVariant::Medium)
, x568_24_inRange(false)
, x568_25_invisible(invisible)
, x568_26_applyBeamAttraction(b2)
, x56c_bomdDropDelay(bombDropDelay)

View File

@ -17,7 +17,7 @@ class CAtomicAlpha : public CPatterned {
SBomb(const std::string_view locator, pas::ELocomotionType locomotionType)
: x0_locatorName(locator), x10_locomotionType(locomotionType) {}
};
bool x568_24_inRange : 1;
bool x568_24_inRange : 1 = false;
bool x568_25_invisible : 1;
bool x568_26_applyBeamAttraction : 1;
float x56c_bomdDropDelay;

View File

@ -79,21 +79,7 @@ CBabygoth::CBabygoth(TUniqueId uid, std::string_view name, const CEntityInfo& in
g_SimplePool->GetObj({SBIG('WPSC'), babyData.x44_fireBreathWeapon})
: g_SimplePool->GetObj("FlameThrower"sv))
, x98c_dVuln(pInfo.GetDamageVulnerability())
, xa00_shellHitPoints(babyData.GetShellHitPoints())
, xa48_24_isAlert(false)
, xa48_25_(false)
, xa48_26_inProjectileAttack(false)
, xa48_27_(false)
, xa48_28_pendingAttackContactDamage(false)
, xa48_29_hasBeenEnraged(false)
, xa48_30_heardPlayerFire(false)
, xa48_31_approachNeedsPathSearch(true)
, xa49_24_gettingUp(false)
, xa49_25_shouldStepBackwards(false)
, xa49_26_readyForTeam(false)
, xa49_27_locomotionValid(false)
, xa49_28_onApproachPath(false)
, xa49_29_objectSpaceCollision(false) {
, xa00_shellHitPoints(babyData.GetShellHitPoints()) {
TLockedToken<CModel> model = g_SimplePool->GetObj({SBIG('CMDL'), babyData.x138_noShellModel});
TLockedToken<CSkinRules> skin = g_SimplePool->GetObj({SBIG('CSKR'), babyData.x13c_noShellSkin});
xa08_noShellModel =

View File

@ -97,20 +97,20 @@ private:
TToken<CGenDescription> xa20_crackTwoParticle;
TToken<CGenDescription> xa2c_destroyShellParticle;
TLockedToken<CGenDescription> xa38_intermediateCrackParticle; // Used to be an optional, not necessary in URDE
bool xa48_24_isAlert : 1;
bool xa48_25_ : 1;
bool xa48_26_inProjectileAttack : 1;
bool xa48_27_ : 1;
bool xa48_28_pendingAttackContactDamage : 1;
bool xa48_29_hasBeenEnraged : 1;
bool xa48_30_heardPlayerFire : 1;
bool xa48_31_approachNeedsPathSearch : 1;
bool xa49_24_gettingUp : 1;
bool xa49_25_shouldStepBackwards : 1;
bool xa49_26_readyForTeam : 1;
bool xa49_27_locomotionValid : 1;
bool xa49_28_onApproachPath : 1;
bool xa49_29_objectSpaceCollision : 1;
bool xa48_24_isAlert : 1 = false;
bool xa48_25_ : 1 = false;
bool xa48_26_inProjectileAttack : 1 = false;
bool xa48_27_ : 1 = false;
bool xa48_28_pendingAttackContactDamage : 1 = false;
bool xa48_29_hasBeenEnraged : 1 = false;
bool xa48_30_heardPlayerFire : 1 = false;
bool xa48_31_approachNeedsPathSearch : 1 = true;
bool xa49_24_gettingUp : 1 = false;
bool xa49_25_shouldStepBackwards : 1 = false;
bool xa49_26_readyForTeam : 1 = false;
bool xa49_27_locomotionValid : 1 = false;
bool xa49_28_onApproachPath : 1 = false;
bool xa49_29_objectSpaceCollision : 1 = false;
void AddSphereCollisionList(const SSphereJointInfo*, size_t, std::vector<CJointCollisionDescription>&);

View File

@ -31,10 +31,7 @@ CBeetle::CBeetle(TUniqueId uid, std::string_view name, const CEntityInfo& info,
, x744_platingVuln(platingVuln)
, x7ac_tailVuln(tailVuln)
, x814_attackDelayTimer(initialAttackDelay)
, x834_retreatTime(retreatTime)
, x838_24_hitSomething(false)
, x838_25_burrowing(false)
, x838_26_canSkid(false) {
, x834_retreatTime(retreatTime) {
x5a0_headbuttDist = GetAnimationDistance(CPASAnimParmData(7, CPASAnimParm::FromEnum(0), CPASAnimParm::FromEnum(1)));
x5a4_jumpBackwardDist =
x64_modelData->GetScale().y() *

View File

@ -38,9 +38,9 @@ private:
zeus::CVector3f x824_predictPos;
float x830_intoGroundFactor = 1.f;
float x834_retreatTime;
bool x838_24_hitSomething : 1;
bool x838_25_burrowing : 1;
bool x838_26_canSkid : 1;
bool x838_24_hitSomething : 1 = false;
bool x838_25_burrowing : 1 = false;
bool x838_26_canSkid : 1 = false;
void SquadAdd(CStateManager& mgr);
void SquadRemove(CStateManager& mgr);

View File

@ -22,9 +22,7 @@ CBouncyGrenade::CBouncyGrenade(TUniqueId uid, std::string_view name, const CEnti
, x2a4_elementGen2(std::make_unique<CElementGen>(g_SimplePool->GetObj({'PART', data.GetElementGenId2()})))
, x2a8_elementGen3(std::make_unique<CElementGen>(g_SimplePool->GetObj({'PART', data.GetElementGenId3()})))
, x2ac_elementGen4(std::make_unique<CElementGen>(g_SimplePool->GetObj({'PART', data.GetElementGenId4()})))
, x2b0_explodePlayerDistance(explodePlayerDistance)
, x2b4_24_exploded(false)
, x2b4_25_(false) {
, x2b0_explodePlayerDistance(explodePlayerDistance) {
SetMomentumWR({0.f, 0.f, -GravityConstant() * GetMass()});
SetVelocityWR(velocity * xf.frontVector());
x2a0_elementGen1->SetParticleEmission(false);

View File

@ -68,8 +68,8 @@ private:
std::unique_ptr<CElementGen> x2a8_elementGen3;
std::unique_ptr<CElementGen> x2ac_elementGen4;
float x2b0_explodePlayerDistance;
bool x2b4_24_exploded : 1;
bool x2b4_25_ : 1;
bool x2b4_24_exploded : 1 = false;
bool x2b4_25_ : 1 = false;
public:
CBouncyGrenade(TUniqueId uid, std::string_view name, const CEntityInfo& info, const zeus::CTransform& xf,

View File

@ -99,18 +99,6 @@ CChozoGhost::CChozoGhost(TUniqueId uid, std::string_view name, const CEntityInfo
, x660_midChance(midChance)
, x664_24_behaviorEnabled(w1)
, x664_25_flinch(!w1)
, x664_26_alert(false)
, x664_27_onGround(false)
, x664_28_(false)
, x664_29_fadedIn(false)
, x664_30_fadedOut(false)
, x664_31_(false)
, x665_24_(true)
, x665_25_(false)
, x665_26_shouldSwoosh(false)
, x665_27_playerInLeashRange(false)
, x665_28_inRange(false)
, x665_29_aggressive(false)
, x680_behaveType(x664_24_behaviorEnabled ? EBehaveType::Attack : EBehaveType::None)
, x68c_boneTracking(*GetModelData()->GetAnimationData(), "Head_1"sv, zeus::degToRad(80.f), zeus::degToRad(180.f),
EBoneTrackingFlags::None) {

View File

@ -62,18 +62,18 @@ private:
u32 x660_midChance;
bool x664_24_behaviorEnabled : 1;
bool x664_25_flinch : 1;
bool x664_26_alert : 1;
bool x664_27_onGround : 1;
bool x664_28_ : 1;
bool x664_29_fadedIn : 1;
bool x664_30_fadedOut : 1;
bool x664_31_ : 1;
bool x665_24_ : 1;
bool x665_25_ : 1;
bool x665_26_shouldSwoosh : 1;
bool x665_27_playerInLeashRange : 1;
bool x665_28_inRange : 1;
bool x665_29_aggressive : 1;
bool x664_26_alert : 1 = false;
bool x664_27_onGround : 1 = false;
bool x664_28_ : 1 = false;
bool x664_29_fadedIn : 1 = false;
bool x664_30_fadedOut : 1 = false;
bool x664_31_ : 1 = false;
bool x665_24_ : 1 = true;
bool x665_25_ : 1 = false;
bool x665_26_shouldSwoosh : 1 = false;
bool x665_27_playerInLeashRange : 1 = false;
bool x665_28_inRange : 1 = false;
bool x665_29_aggressive : 1 = false;
float x668_ = 0.f;
float x66c_ = 0.f;
float x670_ = 0.f;

View File

@ -85,17 +85,7 @@ CElitePirate::CElitePirate(TUniqueId uid, std::string_view name, const CEntityIn
EBoneTrackingFlags::None)
, x738_collisionAabb(GetBoundingBox(), GetMaterialList())
, x7a0_initialSpeed(x3b4_speed)
, x7d0_pathFindSearch(nullptr, 1, pInfo.GetPathfindingIndex(), 1.f, 1.f)
, x8c0_(5.f)
, x988_24_damageOn(false)
, x988_25_attackingRightClaw(false)
, x988_26_attackingLeftClaw(false)
, x988_27_shotAt(false)
, x988_28_alert(false)
, x988_29_shockWaveAnim(false)
, x988_30_calledForBackup(false)
, x988_31_running(false)
, x989_24_onPath(false) {
, x7d0_pathFindSearch(nullptr, 1, pInfo.GetPathfindingIndex(), 1.f, 1.f) {
if (x5d8_data.GetX20().IsValid()) {
x760_energyAbsorbDesc = g_SimplePool->GetObj({SBIG('PART'), x5d8_data.GetX20()});
}

View File

@ -127,16 +127,16 @@ private:
u32 x7cc_activeMaterialSet = 0;
CPathFindSearch x7d0_pathFindSearch;
zeus::CVector3f x8b4_targetDestPos;
SUnknownStruct x8c0_;
bool x988_24_damageOn : 1;
bool x988_25_attackingRightClaw : 1;
bool x988_26_attackingLeftClaw : 1;
bool x988_27_shotAt : 1;
bool x988_28_alert : 1;
bool x988_29_shockWaveAnim : 1;
bool x988_30_calledForBackup : 1;
bool x988_31_running : 1;
bool x989_24_onPath : 1;
SUnknownStruct x8c0_{5.0f};
bool x988_24_damageOn : 1 = false;
bool x988_25_attackingRightClaw : 1 = false;
bool x988_26_attackingLeftClaw : 1 = false;
bool x988_27_shotAt : 1 = false;
bool x988_28_alert : 1 = false;
bool x988_29_shockWaveAnim : 1 = false;
bool x988_30_calledForBackup : 1 = false;
bool x988_31_running : 1 = false;
bool x989_24_onPath : 1 = false;
public:
DEFINE_PATTERNED(ElitePirate)

View File

@ -29,17 +29,9 @@ CEyeball::CEyeball(TUniqueId uid, std::string_view name, CPatterned::EFlavorType
, x5e0_beamPulseFxId(beamPulseFxId)
, x5e4_beamTextureId(beamTextureId)
, x5e8_beamGlowTextureId(beamGlowTextureId)
, x5f4_animIdxs{static_cast<s32>(anim0), static_cast<s32>(anim1), static_cast<s32>(anim2), static_cast<s32>(anim3)}
, x604_beamSfxId(CSfxManager::TranslateSFXID(beamSfx))
, x60c_24_canAttack(false)
, x60c_25_playerInRange(false)
, x60c_26_alert(false)
, x60c_27_attackDisabled(attackDisabled)
, x60c_28_firingBeam(false) {
x5f4_animIdxs[0] = anim0;
x5f4_animIdxs[1] = anim1;
x5f4_animIdxs[2] = anim2;
x5f4_animIdxs[3] = anim3;
, x60c_27_attackDisabled(attackDisabled) {
x460_knockBackController.SetAutoResetImpulse(false);
}
@ -192,20 +184,23 @@ void CEyeball::Active(CStateManager& mgr, EStateMsg msg, float) {
}
void CEyeball::UpdateAnimation() {
if (std::fabs(GetModelData()->GetAnimationData()->GetAnimTimeRemaining("Whole Body"sv) - 0.f) >= 0.00001f)
if (std::fabs(GetModelData()->GetAnimationData()->GetAnimTimeRemaining("Whole Body"sv) - 0.f) >= 0.00001f) {
return;
}
x5f0_currentAnim = (x5f0_currentAnim + 1) & 3;
for (u32 i = 0; i < 4; ++i) {
if (x5f4_animIdxs[x5f0_currentAnim] != -1)
for (size_t i = 0; i < x5f4_animIdxs.size(); ++i) {
if (x5f4_animIdxs[x5f0_currentAnim] != -1) {
break;
}
x5f0_currentAnim = (x5f0_currentAnim + 1) & 3;
}
s32 animIdx = x5f4_animIdxs[x5f0_currentAnim];
if (animIdx != -1)
const s32 animIdx = x5f4_animIdxs[x5f0_currentAnim];
if (animIdx != -1) {
x450_bodyController->GetCommandMgr().DeliverCmd(CBCScriptedCmd(animIdx, false, false, 0.f));
}
}
void CEyeball::ResetBeamState(CStateManager& mgr) {
if (CPlasmaProjectile* projectile = static_cast<CPlasmaProjectile*>(mgr.ObjectById(x5ec_projectileId)))

View File

@ -1,5 +1,6 @@
#pragma once
#include <array>
#include <string_view>
#include "Runtime/RetroTypes.hpp"
@ -22,14 +23,14 @@ class CEyeball : public CPatterned {
CAssetId x5e8_beamGlowTextureId;
TUniqueId x5ec_projectileId = kInvalidUniqueId;
u32 x5f0_currentAnim = 0;
s32 x5f4_animIdxs[4];
std::array<s32, 4> x5f4_animIdxs;
u16 x604_beamSfxId;
CSfxHandle x608_beamSfx = 0;
bool x60c_24_canAttack : 1;
bool x60c_25_playerInRange : 1;
bool x60c_26_alert : 1;
CSfxHandle x608_beamSfx;
bool x60c_24_canAttack : 1 = false;
bool x60c_25_playerInRange : 1 = false;
bool x60c_26_alert : 1 = false;
bool x60c_27_attackDisabled : 1;
bool x60c_28_firingBeam : 1;
bool x60c_28_firingBeam : 1 = false;
void CreateBeam(CStateManager&);
void FireBeam(CStateManager&, const zeus::CTransform&);

View File

@ -93,21 +93,6 @@ CFlaahgra::CFlaahgra(TUniqueId uid, std::string_view name, const CEntityInfo& in
, x820_(xf.origin)
, x8a0_(xf.frontVector())
, x8ac_(animRes) {
x8e4_24_loaded = false;
x8e4_25_loading = false;
x8e4_26_ = false;
x8e4_27_ = false;
x8e4_28_ = false;
x8e4_29_getup = false;
x8e4_30_ = false;
x8e4_31_ = false;
x8e5_24_ = false;
x8e5_25_ = false;
x8e5_26_ = false;
x8e5_27_ = false;
x8e5_28_ = false;
x8e5_29_ = true;
x8e5_30_ = false;
x6dc_.Token().Lock();
x704_.Token().Lock();
x7dc_.SetDamage(0.5f * x7dc_.GetDamage());

View File

@ -134,21 +134,21 @@ class CFlaahgra : public CPatterned {
CAnimRes x8ac_;
std::optional<TToken<CDependencyGroup>> x8c8_depGroup;
std::vector<CToken> x8d4_tokens;
bool x8e4_24_loaded : 1;
bool x8e4_25_loading : 1;
bool x8e4_26_ : 1;
bool x8e4_27_ : 1;
bool x8e4_28_ : 1;
bool x8e4_29_getup : 1;
bool x8e4_30_ : 1;
bool x8e4_31_ : 1;
bool x8e5_24_ : 1;
bool x8e5_25_ : 1;
bool x8e5_26_ : 1;
bool x8e5_27_ : 1;
bool x8e5_28_ : 1;
bool x8e5_29_ : 1;
bool x8e5_30_ : 1;
bool x8e4_24_loaded : 1 = false;
bool x8e4_25_loading : 1 = false;
bool x8e4_26_ : 1 = false;
bool x8e4_27_ : 1 = false;
bool x8e4_28_ : 1 = false;
bool x8e4_29_getup : 1 = false;
bool x8e4_30_ : 1 = false;
bool x8e4_31_ : 1 = false;
bool x8e5_24_ : 1 = false;
bool x8e5_25_ : 1 = false;
bool x8e5_26_ : 1 = false;
bool x8e5_27_ : 1 = false;
bool x8e5_28_ : 1 = false;
bool x8e5_29_ : 1 = true;
bool x8e5_30_ : 1 = false;
void LoadDependencies(CAssetId);
void ResetModelDataAndBodyController();

View File

@ -24,7 +24,6 @@ CFlaahgraTentacle::CFlaahgraTentacle(TUniqueId uid, std::string_view name, const
const CActorParameters& actParms)
: CPatterned(ECharacter::FlaahgraTentacle, uid, name, EFlavorType::Zero, info, xf, std::move(mData), pInfo,
EMovementType::Flyer, EColliderType::One, EBodyType::Restricted, actParms, EKnockBackVariant::Large) {
x58e_24_ = false;
GetActorLights()->SetCastShadows(false);
x460_knockBackController.SetAutoResetImpulse(false);
CreateShadow(false);

View File

@ -19,7 +19,7 @@ class CFlaahgraTentacle : public CPatterned {
TUniqueId x57c_tentacleTipAct = kInvalidUniqueId;
zeus::CVector3f x580_forceVector;
TUniqueId x58c_triggerId = kInvalidUniqueId;
bool x58e_24_ : 1;
bool x58e_24_ : 1 = false;
void AddSphereCollisionList(const SSphereJointInfo* sphereJoints, size_t jointCount,
std::vector<CJointCollisionDescription>& outJoints);

View File

@ -17,9 +17,6 @@ CFlickerBat::CFlickerBat(TUniqueId uid, std::string_view name, CPatterned::EFlav
: CPatterned(ECharacter::FlickerBat, uid, name, flavor, info, xf, std::move(mData), pInfo, EMovementType::Flyer,
colType, EBodyType::Pitchable, actParms, EKnockBackVariant::Small)
, x574_state(EFlickerBatState(startsHidden))
, x580_24_wasInXray(false)
, x580_25_heardShot(false)
, x580_26_inLOS(false)
, x580_27_enableLOSCheck(enableLineOfSight) {
SetupPlayerCollision(startsHidden);
x3d8_xDamageThreshold = 0.f;

View File

@ -14,9 +14,9 @@ private:
EFlickerBatState x574_state;
float x578_fadeRemTime = 1.f;
float x57c_ooFadeDur = 0.f;
bool x580_24_wasInXray : 1;
bool x580_25_heardShot : 1;
bool x580_26_inLOS : 1;
bool x580_24_wasInXray : 1 = false;
bool x580_25_heardShot : 1 = false;
bool x580_26_inLOS : 1 = false;
bool x580_27_enableLOSCheck : 1;
void NotifyNeighbors(CStateManager&);

Some files were not shown because too many files have changed in this diff Show More