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

Implement CFluidPlaneDoor and CScriptDamageableTrigger

This commit is contained in:
Jack Andersen
2017-08-13 17:55:06 -10:00
parent 02f8f77b57
commit 086ff76474
26 changed files with 1110 additions and 295 deletions

View File

@@ -17,38 +17,38 @@ struct DamageableTrigger : IScriptObject
Value<atVec3f> volume;
HealthInfo healthInfo;
DamageVulnerability damageVulnerabilty;
Value<atUint32> unknown1;
UniqueID32 texture1;
UniqueID32 texture2;
UniqueID32 texture3;
Value<atUint32> faceFlag;
UniqueID32 patternTex1;
UniqueID32 patternTex2;
UniqueID32 colorTex;
Value<bool> lockOn;
Value<bool> active;
VisorParameters visorParameters;
void nameIDs(PAKRouter<PAKBridge>& pakRouter) const
{
if (texture1)
if (patternTex1)
{
PAK::Entry* ent = (PAK::Entry*)pakRouter.lookupEntry(texture1);
ent->name = name + "_texture1";
PAK::Entry* ent = (PAK::Entry*)pakRouter.lookupEntry(patternTex1);
ent->name = name + "_patternTex1";
}
if (texture2)
if (patternTex2)
{
PAK::Entry* ent = (PAK::Entry*)pakRouter.lookupEntry(texture2);
ent->name = name + "_texture2";
PAK::Entry* ent = (PAK::Entry*)pakRouter.lookupEntry(patternTex2);
ent->name = name + "_patternTex2";
}
if (texture3)
if (colorTex)
{
PAK::Entry* ent = (PAK::Entry*)pakRouter.lookupEntry(texture3);
ent->name = name + "_texture3";
PAK::Entry* ent = (PAK::Entry*)pakRouter.lookupEntry(colorTex);
ent->name = name + "_colorTex";
}
}
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
{
g_curSpec->flattenDependencies(texture1, pathsOut);
g_curSpec->flattenDependencies(texture2, pathsOut);
g_curSpec->flattenDependencies(texture3, pathsOut);
g_curSpec->flattenDependencies(patternTex1, pathsOut);
g_curSpec->flattenDependencies(patternTex2, pathsOut);
g_curSpec->flattenDependencies(colorTex, pathsOut);
}
zeus::CAABox getVISIAABB(hecl::BlenderToken& btok) const

View File

@@ -84,7 +84,7 @@ struct Water : IScriptObject
Value<float> fogBias;
Value<float> fogMagnitude;
Value<float> fogSpeed;
Value<atVec4f> fogColor; // CColor
Value<atVec4f> fogColor;
UniqueID32 lightmap;
Value<float> unitsPerLightmapTexel;
Value<float> alphaInTime;
@@ -116,52 +116,52 @@ struct Water : IScriptObject
if (patternMap1)
{
PAK::Entry* ent = (PAK::Entry*)pakRouter.lookupEntry(patternMap1);
ent->name = name + "_tex1";
ent->name = name + "_patternMap1";
}
if (patternMap2)
{
PAK::Entry* ent = (PAK::Entry*)pakRouter.lookupEntry(patternMap2);
ent->name = name + "_tex2";
ent->name = name + "_patternMap2";
}
if (colorMap)
{
PAK::Entry* ent = (PAK::Entry*)pakRouter.lookupEntry(colorMap);
ent->name = name + "_tex3";
ent->name = name + "_colorMap";
}
if (bumpMap)
{
PAK::Entry* ent = (PAK::Entry*)pakRouter.lookupEntry(bumpMap);
ent->name = name + "_tex4";
ent->name = name + "_bumpMap";
}
if (envMap)
{
PAK::Entry* ent = (PAK::Entry*)pakRouter.lookupEntry(envMap);
ent->name = name + "_tex5";
ent->name = name + "_envMap";
}
if (envBumpMap)
{
PAK::Entry* ent = (PAK::Entry*)pakRouter.lookupEntry(envBumpMap);
ent->name = name + "_tex6";
ent->name = name + "_envBumpMap";
}
if (lightmap)
{
PAK::Entry* ent = (PAK::Entry*)pakRouter.lookupEntry(lightmap);
ent->name = name + "_tex34";
ent->name = name + "_lightmap";
}
if (splashParticle1)
{
PAK::Entry* ent = (PAK::Entry*)pakRouter.lookupEntry(splashParticle1);
ent->name = name + "_part1";
ent->name = name + "_splashParticle1";
}
if (splashParticle2)
{
PAK::Entry* ent = (PAK::Entry*)pakRouter.lookupEntry(splashParticle2);
ent->name = name + "_part2";
ent->name = name + "_splashParticle2";
}
if (splashParticle3)
{
PAK::Entry* ent = (PAK::Entry*)pakRouter.lookupEntry(splashParticle3);
ent->name = name + "_part3";
ent->name = name + "_splashParticle3";
}
if (particle4)
{