#pragma once #include "../../DNACommon/DNACommon.hpp" #include "IScriptObject.hpp" #include "Parameters.hpp" namespace DataSpec::DNAMP1 { struct Babygoth : IScriptObject { AT_DECL_DNA_YAMLV String<-1> name; Value location; Value orientation; Value scale; PatternedInfo patternedInfo; ActorParameters actorParameters; Value fireballAttackTime; Value fireballAttackTimeVariance; UniqueID32 fireballWeapon; DamageInfo fireballDamage; DamageInfo attackContactDamage; UniqueID32 fireBreathWeapon; UniqueID32 fireBreathRes; DamageInfo fireBreathDamage; DamageVulnerability mouthVulnerabilities; DamageVulnerability shellVulnerabilities; UniqueID32 noShellModel; UniqueID32 noShellSkin; Value shellHitPoints; Value shellCrackSfx; UniqueID32 intermediateCrackParticle; UniqueID32 crackOneParticle; UniqueID32 crackTwoParticle; UniqueID32 destroyShellParticle; Value crackOneSfx; Value crackTwoSfx; Value destroyShellSfx; Value timeUntilAttack; Value attackCooldownTime; Value interestTime; UniqueID32 flamePlayerSteamTxtr; Value flamePlayerHitSfx; UniqueID32 flamePlayerIceTxtr; void addCMDLRigPairs(PAKRouter& pakRouter, CharacterAssociations& charAssoc) const override { UniqueID32 cinf = patternedInfo.animationParameters.getCINF(pakRouter); actorParameters.addCMDLRigPairs(pakRouter, charAssoc, patternedInfo.animationParameters); if (noShellModel.isValid() && noShellSkin.isValid()) { charAssoc.m_cmdlRigs[noShellModel] = std::make_pair(noShellSkin, cinf); charAssoc.m_cskrCinfToCharacter[noShellSkin] = std::make_pair(patternedInfo.animationParameters.animationCharacterSet, "ATTACH.SHELLESS.CSKR"); charAssoc.addAttachmentRig(patternedInfo.animationParameters.animationCharacterSet, {}, noShellModel, "SHELLESS"); } } void nameIDs(PAKRouter& pakRouter) const override { if (fireballWeapon.isValid()) { PAK::Entry* ent = (PAK::Entry*)pakRouter.lookupEntry(fireballWeapon); ent->name = name + "_wpsc1"; } if (fireBreathWeapon.isValid()) { PAK::Entry* ent = (PAK::Entry*)pakRouter.lookupEntry(fireBreathWeapon); ent->name = name + "_wpsc2"; } if (fireBreathRes.isValid()) { PAK::Entry* ent = (PAK::Entry*)pakRouter.lookupEntry(fireBreathRes); ent->name = name + "_part1"; } if (noShellModel.isValid()) { PAK::Entry* ent = (PAK::Entry*)pakRouter.lookupEntry(noShellModel); ent->name = name + "_emodel"; } if (noShellSkin.isValid()) { PAK::Entry* ent = (PAK::Entry*)pakRouter.lookupEntry(noShellSkin); ent->name = name + "_eskin"; } if (intermediateCrackParticle.isValid()) { PAK::Entry* ent = (PAK::Entry*)pakRouter.lookupEntry(intermediateCrackParticle); ent->name = name + "_part2"; } if (crackOneParticle.isValid()) { PAK::Entry* ent = (PAK::Entry*)pakRouter.lookupEntry(crackOneParticle); ent->name = name + "_part3"; } if (crackTwoParticle.isValid()) { PAK::Entry* ent = (PAK::Entry*)pakRouter.lookupEntry(crackTwoParticle); ent->name = name + "_part4"; } if (destroyShellParticle.isValid()) { PAK::Entry* ent = (PAK::Entry*)pakRouter.lookupEntry(destroyShellParticle); ent->name = name + "_part5"; } if (flamePlayerSteamTxtr.isValid()) { PAK::Entry* ent = (PAK::Entry*)pakRouter.lookupEntry(flamePlayerSteamTxtr); ent->name = name + "_tex"; } if (flamePlayerIceTxtr.isValid()) { PAK::Entry* ent = (PAK::Entry*)pakRouter.lookupEntry(flamePlayerIceTxtr); ent->name = name + "_part6"; } patternedInfo.nameIDs(pakRouter, name + "_patterned"); actorParameters.nameIDs(pakRouter, name + "_actp"); } void gatherDependencies(std::vector& pathsOut, std::vector& lazyOut) const override { g_curSpec->flattenDependencies(fireballWeapon, pathsOut); g_curSpec->flattenDependencies(fireBreathWeapon, pathsOut); g_curSpec->flattenDependencies(fireBreathRes, pathsOut); g_curSpec->flattenDependencies(noShellModel, pathsOut); g_curSpec->flattenDependencies(noShellSkin, pathsOut); g_curSpec->flattenDependencies(intermediateCrackParticle, pathsOut); g_curSpec->flattenDependencies(crackOneParticle, pathsOut); g_curSpec->flattenDependencies(crackTwoParticle, pathsOut); g_curSpec->flattenDependencies(destroyShellParticle, pathsOut); g_curSpec->flattenDependencies(flamePlayerSteamTxtr, pathsOut); g_curSpec->flattenDependencies(flamePlayerIceTxtr, pathsOut); patternedInfo.depIDs(pathsOut); actorParameters.depIDs(pathsOut, lazyOut); } void gatherScans(std::vector& scansOut) const override { actorParameters.scanIDs(scansOut); } }; } // namespace DataSpec::DNAMP1