Fix all_source build

This commit is contained in:
Luke Street 2024-02-28 22:04:59 -07:00
parent ba95b75f72
commit a876d81ac2
13 changed files with 76 additions and 68 deletions

View File

@ -8,6 +8,7 @@ public:
CScriptDock(TUniqueId uid, const rstl::string& name, const CEntityInfo& info, CScriptDock(TUniqueId uid, const rstl::string& name, const CEntityInfo& info,
const CVector3f& position, const CVector3f& extent, int dock, TAreaId area, const CVector3f& position, const CVector3f& extent, int dock, TAreaId area,
bool active, int dockReferenceCount, bool loadConnected); bool active, int dockReferenceCount, bool loadConnected);
~CScriptDock();
void SetDockReference(CStateManager& mgr, int); void SetDockReference(CStateManager& mgr, int);

View File

@ -12,7 +12,7 @@ namespace rstl {
template < typename T, typename Vec, typename Alloc > template < typename T, typename Vec, typename Alloc >
class const_pointer_iterator { class const_pointer_iterator {
public: public:
typedef ptrdiff_t difference_type; typedef long difference_type;
typedef random_access_iterator_tag iterator_category; typedef random_access_iterator_tag iterator_category;
typedef T value_type; typedef T value_type;

View File

@ -7,7 +7,7 @@ extern float sqrtf(float x);
#define GX_LARGE_NUMBER 1.0e+18f; #define GX_LARGE_NUMBER 1.0e+18f;
void GXInitLightAttn(GXLightObj* lt_obj, f32 a0, f32 a1, f32 a2, f32 k0, f32 k1, f32 k2) { void GXInitLightAttn(GXLightObj* lt_obj, f32 a0, f32 a1, f32 a2, f32 k0, f32 k1, f32 k2) {
GXLightObj_* obj = (GXLightObj_*)lt_obj; GXLightObjInt* obj = (GXLightObjInt*)lt_obj;
obj->a0 = a0; obj->a0 = a0;
obj->a1 = a1; obj->a1 = a1;
obj->a2 = a2; obj->a2 = a2;
@ -17,28 +17,28 @@ void GXInitLightAttn(GXLightObj* lt_obj, f32 a0, f32 a1, f32 a2, f32 k0, f32 k1,
} }
void GXInitLightAttnA(GXLightObj* lt_obj, f32 a0, f32 a1, f32 a2) { void GXInitLightAttnA(GXLightObj* lt_obj, f32 a0, f32 a1, f32 a2) {
GXLightObj_* obj = (GXLightObj_*)lt_obj; GXLightObjInt* obj = (GXLightObjInt*)lt_obj;
obj->a0 = a0; obj->a0 = a0;
obj->a1 = a1; obj->a1 = a1;
obj->a2 = a2; obj->a2 = a2;
} }
void GXGetLightAttnA(const GXLightObj* lt_obj, f32* a0, f32* a1, f32* a2) { void GXGetLightAttnA(const GXLightObj* lt_obj, f32* a0, f32* a1, f32* a2) {
GXLightObj_* obj = (GXLightObj_*)lt_obj; GXLightObjInt* obj = (GXLightObjInt*)lt_obj;
*a0 = obj->a0; *a0 = obj->a0;
*a1 = obj->a1; *a1 = obj->a1;
*a2 = obj->a2; *a2 = obj->a2;
} }
void GXInitLightAttnK(GXLightObj* lt_obj, f32 k0, f32 k1, f32 k2) { void GXInitLightAttnK(GXLightObj* lt_obj, f32 k0, f32 k1, f32 k2) {
GXLightObj_* obj = (GXLightObj_*)lt_obj; GXLightObjInt* obj = (GXLightObjInt*)lt_obj;
obj->k0 = k0; obj->k0 = k0;
obj->k1 = k1; obj->k1 = k1;
obj->k2 = k2; obj->k2 = k2;
} }
void GXGetLightAttnK(const GXLightObj* lt_obj, f32* k0, f32* k1, f32* k2) { void GXGetLightAttnK(const GXLightObj* lt_obj, f32* k0, f32* k1, f32* k2) {
GXLightObj_* obj = (GXLightObj_*)lt_obj; GXLightObjInt* obj = (GXLightObjInt*)lt_obj;
*k0 = obj->k0; *k0 = obj->k0;
*k1 = obj->k1; *k1 = obj->k1;
*k2 = obj->k2; *k2 = obj->k2;
@ -48,7 +48,7 @@ void GXGetLightAttnK(const GXLightObj* lt_obj, f32* k0, f32* k1, f32* k2) {
void GXInitLightSpot(GXLightObj* lt_obj, f32 cutoff, GXSpotFn spot_func) { void GXInitLightSpot(GXLightObj* lt_obj, f32 cutoff, GXSpotFn spot_func) {
f32 a0, a1, a2, r, d, cr; f32 a0, a1, a2, r, d, cr;
GXLightObj_* obj = (GXLightObj_*)lt_obj; GXLightObjInt* obj = (GXLightObjInt*)lt_obj;
if (cutoff <= 0.0f || cutoff > 90.0f) { if (cutoff <= 0.0f || cutoff > 90.0f) {
spot_func = GX_SP_OFF; spot_func = GX_SP_OFF;
@ -106,7 +106,7 @@ void GXInitLightSpot(GXLightObj* lt_obj, f32 cutoff, GXSpotFn spot_func) {
void GXInitLightDistAttn(GXLightObj* lt_obj, f32 ref_dist, f32 ref_br, GXDistAttnFn dist_func) { void GXInitLightDistAttn(GXLightObj* lt_obj, f32 ref_dist, f32 ref_br, GXDistAttnFn dist_func) {
f32 k0, k1, k2; f32 k0, k1, k2;
GXLightObj_* obj = (GXLightObj_*)lt_obj; GXLightObjInt* obj = (GXLightObjInt*)lt_obj;
if (ref_dist < 0.0F) { if (ref_dist < 0.0F) {
dist_func = GX_DA_OFF; dist_func = GX_DA_OFF;
@ -146,7 +146,7 @@ void GXInitLightDistAttn(GXLightObj* lt_obj, f32 ref_dist, f32 ref_br, GXDistAtt
} }
void GXInitLightPos(GXLightObj* lt_obj, f32 x, f32 y, f32 z) { void GXInitLightPos(GXLightObj* lt_obj, f32 x, f32 y, f32 z) {
GXLightObj_* obj = (GXLightObj_*)lt_obj; GXLightObjInt* obj = (GXLightObjInt*)lt_obj;
obj->px = x; obj->px = x;
obj->py = y; obj->py = y;
@ -154,14 +154,14 @@ void GXInitLightPos(GXLightObj* lt_obj, f32 x, f32 y, f32 z) {
} }
void GXGetLightPos(const GXLightObj* lt_obj, f32* x, f32* y, f32* z) { void GXGetLightPos(const GXLightObj* lt_obj, f32* x, f32* y, f32* z) {
GXLightObj_* obj = (GXLightObj_*)lt_obj; GXLightObjInt* obj = (GXLightObjInt*)lt_obj;
*x = obj->px; *x = obj->px;
*y = obj->py; *y = obj->py;
*z = obj->pz; *z = obj->pz;
} }
void GXInitLightDir(GXLightObj* lt_obj, f32 nx, f32 ny, f32 nz) { void GXInitLightDir(GXLightObj* lt_obj, f32 nx, f32 ny, f32 nz) {
GXLightObj_* obj = (GXLightObj_*)lt_obj; GXLightObjInt* obj = (GXLightObjInt*)lt_obj;
obj->nx = -nx; obj->nx = -nx;
obj->ny = -ny; obj->ny = -ny;
@ -169,7 +169,7 @@ void GXInitLightDir(GXLightObj* lt_obj, f32 nx, f32 ny, f32 nz) {
} }
void GXGetLightDir(const GXLightObj* lt_obj, f32* nx, f32* ny, f32* nz) { void GXGetLightDir(const GXLightObj* lt_obj, f32* nx, f32* ny, f32* nz) {
GXLightObj_* obj = (GXLightObj_*)lt_obj; GXLightObjInt* obj = (GXLightObjInt*)lt_obj;
*nx = -(obj->nx); *nx = -(obj->nx);
*ny = -(obj->ny); *ny = -(obj->ny);
*nz = -(obj->nz); *nz = -(obj->nz);
@ -178,7 +178,7 @@ void GXGetLightDir(const GXLightObj* lt_obj, f32* nx, f32* ny, f32* nz) {
void GXInitSpecularDir(GXLightObj* lt_obj, f32 nx, f32 ny, f32 nz) { void GXInitSpecularDir(GXLightObj* lt_obj, f32 nx, f32 ny, f32 nz) {
f32 mag; f32 mag;
f32 vx, vy, vz; f32 vx, vy, vz;
GXLightObj_* obj = (GXLightObj_*)lt_obj; GXLightObjInt* obj = (GXLightObjInt*)lt_obj;
vx = -nx; vx = -nx;
vy = -ny; vy = -ny;
@ -199,7 +199,7 @@ void GXInitSpecularDir(GXLightObj* lt_obj, f32 nx, f32 ny, f32 nz) {
} }
void GXInitSpecularDirHA(GXLightObj* lt_obj, f32 nx, f32 ny, f32 nz, f32 hx, f32 hy, f32 hz) { void GXInitSpecularDirHA(GXLightObj* lt_obj, f32 nx, f32 ny, f32 nz, f32 hx, f32 hy, f32 hz) {
GXLightObj_* obj = (GXLightObj_*)lt_obj; GXLightObjInt* obj = (GXLightObjInt*)lt_obj;
obj->nx = hx; obj->nx = hx;
obj->ny = hy; obj->ny = hy;
@ -211,16 +211,16 @@ void GXInitSpecularDirHA(GXLightObj* lt_obj, f32 nx, f32 ny, f32 nz, f32 hx, f32
} }
void GXInitLightColor(GXLightObj* lt_obj, GXColor color) { void GXInitLightColor(GXLightObj* lt_obj, GXColor color) {
GXLightObj_* obj = (GXLightObj_*)lt_obj; GXLightObjInt* obj = (GXLightObjInt*)lt_obj;
obj->color = *(u32*)(&color); obj->color = *(u32*)(&color);
} }
void GXGetLightColor(const GXLightObj* lt_obj, GXColor* color) { void GXGetLightColor(const GXLightObj* lt_obj, GXColor* color) {
GXLightObj_* obj = (GXLightObj_*)lt_obj; GXLightObjInt* obj = (GXLightObjInt*)lt_obj;
*(u32*)color = obj->color; *(u32*)color = obj->color;
} }
static inline void PushLight(const register GXLightObj_* lt_obj, register void* dest) { static inline void PushLight(const register GXLightObjInt* lt_obj, register void* dest) {
register u32 zero, color; register u32 zero, color;
register f32 a0_a1, a2_k0, k1_k2; register f32 a0_a1, a2_k0, k1_k2;
register f32 px_py, pz_dx, dy_dz; register f32 px_py, pz_dx, dy_dz;
@ -252,8 +252,8 @@ static inline void PushLight(const register GXLightObj_* lt_obj, register void*
void GXLoadLightObjImm(GXLightObj* lt_obj, GXLightID light) { void GXLoadLightObjImm(GXLightObj* lt_obj, GXLightID light) {
u32 addr; u32 addr;
u32 idx; u32 idx;
GXLightObj_* obj; GXLightObjInt* obj;
obj = (GXLightObj_*)lt_obj; obj = (GXLightObjInt*)lt_obj;
idx = 31 - __cntlzw(light); idx = 31 - __cntlzw(light);
idx &= 7; idx &= 7;
@ -263,7 +263,7 @@ void GXLoadLightObjImm(GXLightObj* lt_obj, GXLightID light) {
GX_WRITE_U8(16); GX_WRITE_U8(16);
GX_WRITE_U32(addr | (XF_LIGHT_SIZE - 1) << 16); GX_WRITE_U32(addr | (XF_LIGHT_SIZE - 1) << 16);
PushLight(obj, (void*)GX_FIFO_ADDR); PushLight(obj, (void*)GX_FIFO_ADDR);
__GXData->bpSentNot = 1; gx->bpSentNot = 1;
} }
void GXSetChanAmbColor(GXChannelID chan, GXColor color) {} void GXSetChanAmbColor(GXChannelID chan, GXColor color) {}

View File

@ -715,8 +715,11 @@ void CActor::ProcessSoundEvent(int sfxId, float weight, int flags, float fallOff
musyxFlags |= 0x8; // Doppler FX musyxFlags |= 0x8; // Doppler FX
} }
CAudioSys::C3DEmitterParmData parms(position, CVector3f::Zero(), maxDist, fallOff, musyxFlags, id, // TODO ctor?
maxVol, minVol, false, 0x7f); CAudioSys::C3DEmitterParmData parms(maxDist, fallOff, musyxFlags, maxVol, minVol);
parms.x0_pos = position;
parms.xc_dir = CVector3f::Zero();
parms.x24_sfxId = id;
bool useAcoustics = (flags & 0x80) == 0; bool useAcoustics = (flags & 0x80) == 0;
bool looping = (sfxId & 0x80000000) != 0; bool looping = (sfxId & 0x80000000) != 0;

View File

@ -58,7 +58,7 @@ CIOWin::EMessageReturn CCredits::Update(float dt, CArchitectureQueue& queue) {
for (int i = 0; i < x18_creditsTable->GetStringCount(); ++i) { for (int i = 0; i < x18_creditsTable->GetStringCount(); ++i) {
x30_text.push_back(rstl::pair< rstl::single_ptr< CGuiTextSupport >, CVector2i >( x30_text.push_back(rstl::pair< rstl::single_ptr< CGuiTextSupport >, CVector2i >(
rs_new CGuiTextSupport( rs_new CGuiTextSupport(
gpResourceFactory->GetResourceIdByName(gpTweakGui->GetCreditsFont().data())->id, gpResourceFactory->GetResourceIdByName(gpTweakGui->GetCreditsFont().data())->mId,
CGuiTextProperties(true, true, kJustification_Center, kVerticalJustification_Top), CGuiTextProperties(true, true, kJustification_Center, kVerticalJustification_Top),
gpTweakGui->GetCreditsTextFontColor(), gpTweakGui->GetCreditsTextBorderColor(), gpTweakGui->GetCreditsTextFontColor(), gpTweakGui->GetCreditsTextBorderColor(),
CColor::White(), CGraphics::GetViewport().mWidth - 64, 0, gpSimplePool, CColor::White(), CGraphics::GetViewport().mWidth - 64, 0, gpSimplePool,
@ -68,7 +68,7 @@ CIOWin::EMessageReturn CCredits::Update(float dt, CArchitectureQueue& queue) {
} }
// auto tmp = std::make_pair(std::make_unique<CGuiTextSupport>( // auto tmp = std::make_pair(std::make_unique<CGuiTextSupport>(
// gpResourceFactory->GetResourceIdByName(gpTweakGui->GetCreditsFont())->id, // gpResourceFactory->GetResourceIdByName(gpTweakGui->GetCreditsFont())->mId,
// CGuiTextProperties(true, true, kJ_Center, // CGuiTextProperties(true, true, kJ_Center,
// EVerticalJustification::Top), // EVerticalJustification::Top),
// gpTweakGui->GetCreditsTextFontColor(), // gpTweakGui->GetCreditsTextFontColor(),

View File

@ -238,6 +238,6 @@ const CVector3f& CMapArea::GetAreaPostTranslate(const IWorld& world, TAreaId aid
CFactoryFnReturn FMapAreaFactory(const SObjectTag& objTag, CInputStream& in, CFactoryFnReturn FMapAreaFactory(const SObjectTag& objTag, CInputStream& in,
const CVParamTransfer&) { const CVParamTransfer&) {
gHackAssetId = objTag.id; gHackAssetId = objTag.mId;
return CFactoryFnReturn(rs_new CMapArea(in, gpResourceFactory->ResourceSize(objTag))); return CFactoryFnReturn(rs_new CMapArea(in, gpResourceFactory->ResourceSize(objTag)));
} }

View File

@ -147,41 +147,42 @@ void CMappableObject::Draw(int curArea, const CMapWorldInfo& mwInfo, float alpha
CAssetId iconRes = kInvalidAssetId; CAssetId iconRes = kInvalidAssetId;
CColor iconColor = CColor(0xffffffff); CColor iconColor = CColor(0xffffffff);
switch (x0_type) { // TODO
case kMOT_DownArrowYellow: // switch (x0_type) {
iconRes = gpTweakPlayerRes->x10_minesBreakFirstTopIcon; // case kMOT_DownArrowYellow:
iconColor = CColor(0xffff96ff); // iconRes = gpTweakPlayerRes->x10_minesBreakFirstTopIcon;
break; // iconColor = CColor(0xffff96ff);
case kMOT_UpArrowYellow: // break;
iconRes = gpTweakPlayerRes->x14_minesBreakFirstBottomIcon; // case kMOT_UpArrowYellow:
iconColor = CColor(0xffff96ff); // iconRes = gpTweakPlayerRes->x14_minesBreakFirstBottomIcon;
break; // iconColor = CColor(0xffff96ff);
case kMOT_DownArrowGreen: // break;
iconRes = gpTweakPlayerRes->x10_minesBreakFirstTopIcon; // case kMOT_DownArrowGreen:
iconColor = CColor(0x64ff96ff); // iconRes = gpTweakPlayerRes->x10_minesBreakFirstTopIcon;
break; // iconColor = CColor(0x64ff96ff);
case kMOT_UpArrowGreen: // break;
iconRes = gpTweakPlayerRes->x14_minesBreakFirstBottomIcon; // case kMOT_UpArrowGreen:
iconColor = CColor(0x64ff96ff); // iconRes = gpTweakPlayerRes->x14_minesBreakFirstBottomIcon;
break; // iconColor = CColor(0x64ff96ff);
case kMOT_DownArrowRed: // break;
iconRes = gpTweakPlayerRes->x10_minesBreakFirstTopIcon; // case kMOT_DownArrowRed:
iconColor = CColor(0xff6496ff); // iconRes = gpTweakPlayerRes->x10_minesBreakFirstTopIcon;
break; // iconColor = CColor(0xff6496ff);
case kMOT_UpArrowRed: // break;
iconRes = gpTweakPlayerRes->x14_minesBreakFirstBottomIcon; // case kMOT_UpArrowRed:
iconColor = CColor(0xff6496ff); // iconRes = gpTweakPlayerRes->x14_minesBreakFirstBottomIcon;
break; // iconColor = CColor(0xff6496ff);
case kMOT_SaveStation: // break;
iconRes = gpTweakPlayerRes->x4_saveStationIcon; // case kMOT_SaveStation:
break; // iconRes = gpTweakPlayerRes->x4_saveStationIcon;
case kMOT_MissileStation: // break;
iconRes = gpTweakPlayerRes->x8_missileStationIcon; // case kMOT_MissileStation:
break; // iconRes = gpTweakPlayerRes->x8_missileStationIcon;
default: // break;
iconRes = gpTweakPlayerRes->xc_elevatorIcon; // default:
break; // iconRes = gpTweakPlayerRes->xc_elevatorIcon;
} // break;
// }
TLockedToken< CTexture > tex = gpSimplePool->GetObj(SObjectTag('TXTR', iconRes)); TLockedToken< CTexture > tex = gpSimplePool->GetObj(SObjectTag('TXTR', iconRes));
tex->Load(GX_TEXMAP0, CTexture::kCM_Repeat); tex->Load(GX_TEXMAP0, CTexture::kCM_Repeat);
CGraphics::SetTevOp(kTS_Stage0, CGraphics::kEnvModulate); CGraphics::SetTevOp(kTS_Stage0, CGraphics::kEnvModulate);

View File

@ -23,7 +23,7 @@ static const CTransform4f skFaceModelViewAdjust =
CTransform4f::Scale(0.3f) * CTransform4f::Translate(CVector3f(0.f, 0.5f, 0.f)); CTransform4f::Scale(0.3f) * CTransform4f::Translate(CVector3f(0.f, 0.5f, 0.f));
CSamusFaceReflection::CSamusFaceReflection(const CStateManager& mgr) CSamusFaceReflection::CSamusFaceReflection(const CStateManager& mgr)
: x0_modelData(CModelData(CAnimRes(gpResourceFactory->GetResourceIdByName(skFaceAssetIdName)->id, : x0_modelData(CModelData(CAnimRes(gpResourceFactory->GetResourceIdByName(skFaceAssetIdName)->mId,
CAnimRes::kDefaultCharIdx, CVector3f(1.f, 1.f, 1.f), 0, true))) CAnimRes::kDefaultCharIdx, CVector3f(1.f, 1.f, 1.f), 0, true)))
, x4c_lights(rs_new CActorLights(8, CVector3f::Zero(), 4, 4)) , x4c_lights(rs_new CActorLights(8, CVector3f::Zero(), 4, 4))
, x50_lookRot(CQuaternion::NoRotation()) , x50_lookRot(CQuaternion::NoRotation())

View File

@ -140,7 +140,7 @@ void CScriptActor::AcceptScriptMsg(EScriptObjectMessage msg, TUniqueId uid, CSta
} }
case kSM_Increment: { case kSM_Increment: {
if (!GetActive()) { if (!GetActive()) {
mgr.SendScriptMsg(this, GetUniqueId(), kSM_Activate); mgr.DeliverScriptMsg(this, GetUniqueId(), kSM_Activate);
CScriptColorModulate::FadeInHelper(mgr, GetUniqueId(), x2d0_fadeInTime); CScriptColorModulate::FadeInHelper(mgr, GetUniqueId(), x2d0_fadeInTime);
} }
break; break;

View File

@ -77,7 +77,7 @@ void CScriptRandomRelay::SendLocalScriptMsgs(EScriptObjectState state, CStateMan
for (rstl::vector< rstl::pair< CEntity*, EScriptObjectMessage > >::iterator it = objs.begin(); for (rstl::vector< rstl::pair< CEntity*, EScriptObjectMessage > >::iterator it = objs.begin();
it != objs.end(); ++it) { it != objs.end(); ++it) {
stateMgr.SendScriptMsg(it->first, GetUniqueId(), it->second); stateMgr.DeliverScriptMsg(it->first, GetUniqueId(), it->second);
} }
break; break;
} }

View File

@ -545,7 +545,7 @@ void CScriptSpecialFunction::AcceptScriptMsg(EScriptObjectMessage msg, TUniqueId
if (msg == kSM_Increment) { if (msg == kSM_Increment) {
const SObjectTag* objectTag = const SObjectTag* objectTag =
gpResourceFactory->GetResourceIdByName(xec_locatorName.data()); gpResourceFactory->GetResourceIdByName(xec_locatorName.data());
const CAssetId assetId = objectTag ? objectTag->id : kInvalidAssetId; const CAssetId assetId = objectTag ? objectTag->mId : kInvalidAssetId;
mgr.SetPendingOnScreenTex(assetId, CVector2i(int(x104_float3), int(x108_float4)), mgr.SetPendingOnScreenTex(assetId, CVector2i(int(x104_float3), int(x108_float4)),
CVector2i(int(xfc_float1), int(x100_float2))); CVector2i(int(xfc_float1), int(x100_float2)));

View File

@ -38,7 +38,7 @@ CTweakPlayerRes* gpTweakPlayerRes = nullptr;
CTweakSlideShow* gpTweakSlideShow = nullptr; CTweakSlideShow* gpTweakSlideShow = nullptr;
CAssetId IDFromFactory(CResFactory& factory, const char* filename) { CAssetId IDFromFactory(CResFactory& factory, const char* filename) {
return factory.GetResourceIdByName(filename)->id; return factory.GetResourceIdByName(filename)->mId;
} }
CTweaks::CTweaks() { mTweakObjects.resize(14, rstl::auto_ptr< ITweakObject >()); } CTweaks::CTweaks() { mTweakObjects.resize(14, rstl::auto_ptr< ITweakObject >()); }

View File

@ -23,7 +23,7 @@ CAssetId get_asset_id_from_name(const char* name) {
if (!tag) { if (!tag) {
return kInvalidAssetId; return kInvalidAssetId;
} }
return tag->id; return tag->mId;
} }
void get_token_vector(CAnimData& animData, int animIdx, rstl::vector< CToken >& tokensOut, void get_token_vector(CAnimData& animData, int animIdx, rstl::vector< CToken >& tokensOut,
@ -107,8 +107,11 @@ void do_sound_event(rstl::pair< u16, CSfxHandle >& sfxHandle, int& pitch, bool d
useFlags |= 0x8; // Doppler effect useFlags |= 0x8; // Doppler effect
bool useAcoustics = (flags & 0x80) == 0; bool useAcoustics = (flags & 0x80) == 0;
CAudioSys::C3DEmitterParmData parms(pos, CVector3f::Up(), maxDist, falloff, useFlags, useSfxId, // TODO ctor?
maxVol, minVol, false, 0x7f); CAudioSys::C3DEmitterParmData parms(maxDist, falloff, useFlags, maxVol, minVol);
parms.x0_pos = pos;
parms.xc_dir = CVector3f::Up();
parms.x24_sfxId = useSfxId;
if (mgr.Random()->Float() <= weight) { if (mgr.Random()->Float() <= weight) {
if ((soundId & 0x80000000) != 0) { if ((soundId & 0x80000000) != 0) {