mirror of
https://github.com/Laupetin/OpenAssetTools.git
synced 2025-04-20 00:02:55 +00:00
chore: add missing iw5 weapon fields
This commit is contained in:
parent
f63e7c7f35
commit
f8c9e62624
@ -81,6 +81,7 @@ namespace IW5
|
||||
CSPFT_PHYS_COLLMAP,
|
||||
CSPFT_SOUND,
|
||||
CSPFT_TRACER,
|
||||
CSPFT_SCRIPT_STRING,
|
||||
|
||||
CSPFT_NUM_BASE_FIELD_TYPES,
|
||||
};
|
||||
@ -98,7 +99,7 @@ namespace IW5
|
||||
WFT_ANIMTYPE,
|
||||
WFT_ACTIVE_RETICLE_TYPE,
|
||||
WFT_GUIDED_MISSILE_TYPE,
|
||||
WFT_BOUNCE_SOUND,
|
||||
WFT_PER_SURFACE_TYPE_SOUND,
|
||||
WFT_STICKINESS,
|
||||
WFT_OVERLAYINTERFACE,
|
||||
WFT_INVENTORYTYPE,
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -76,13 +76,13 @@ namespace IW5
|
||||
FillFromEnumInt(std::string(field.szName), field.iOffset, guidedMissileNames, std::extent_v<decltype(guidedMissileNames)>);
|
||||
break;
|
||||
|
||||
case WFT_BOUNCE_SOUND:
|
||||
case WFT_PER_SURFACE_TYPE_SOUND:
|
||||
{
|
||||
const auto* bounceSound = *reinterpret_cast<SndAliasCustom**>(reinterpret_cast<uintptr_t>(m_structure) + field.iOffset);
|
||||
const auto* perSurfaceTypeSound = *reinterpret_cast<SndAliasCustom**>(reinterpret_cast<uintptr_t>(m_structure) + field.iOffset);
|
||||
|
||||
if (bounceSound && bounceSound->name)
|
||||
if (perSurfaceTypeSound && perSurfaceTypeSound->name)
|
||||
{
|
||||
const std::string firstBounceSound(bounceSound->name->soundName);
|
||||
const std::string firstBounceSound(perSurfaceTypeSound->name->soundName);
|
||||
const auto endOfBouncePrefix = firstBounceSound.rfind("_default");
|
||||
assert(endOfBouncePrefix != std::string::npos);
|
||||
|
||||
|
@ -117,6 +117,10 @@ void InfoStringFromStructConverter::FillFromBaseField(const cspField_t& field)
|
||||
break;
|
||||
}
|
||||
|
||||
case CSPFT_SCRIPT_STRING:
|
||||
FillFromScriptString(std::string(field.szName), field.iOffset);
|
||||
break;
|
||||
|
||||
case CSPFT_NUM_BASE_FIELD_TYPES:
|
||||
default:
|
||||
assert(false);
|
||||
|
Loading…
x
Reference in New Issue
Block a user