mirror of
https://github.com/AxioDL/metaforce.git
synced 2025-12-08 13:44:56 +00:00
CBeetle implementation
This commit is contained in:
@@ -382,8 +382,11 @@ std::string PAKRouter<BRIDGETYPE>::getBestEntryName(const EntryType& entry, bool
|
||||
std::string name;
|
||||
for (const BRIDGETYPE& bridge : *m_bridges) {
|
||||
const typename BRIDGETYPE::PAKType& pak = bridge.getPAK();
|
||||
const typename BRIDGETYPE::PAKType::Entry* e = pak.lookupEntry(entry.id);
|
||||
if (!e)
|
||||
continue;
|
||||
|
||||
if (stdOverride && isShared()) {
|
||||
if (stdOverride && !pak.m_noShare) {
|
||||
if (entry.type == FOURCC('MLVL'))
|
||||
return "!world";
|
||||
else if (entry.type == FOURCC('MREA'))
|
||||
@@ -411,7 +414,7 @@ std::string PAKRouter<BRIDGETYPE>::getBestEntryName(const IDType& entry, bool st
|
||||
if (!e)
|
||||
continue;
|
||||
|
||||
if (stdOverride && isShared()) {
|
||||
if (stdOverride && !pak.m_noShare) {
|
||||
if (e->type == FOURCC('MLVL'))
|
||||
return "!world";
|
||||
else if (e->type == FOURCC('MREA'))
|
||||
|
||||
@@ -175,10 +175,6 @@ public:
|
||||
hecl::ProjectPath getWorking(const IDType& id, bool silenceWarnings = false) const;
|
||||
hecl::ProjectPath getCooked(const EntryType* entry) const;
|
||||
hecl::ProjectPath getCooked(const IDType& id, bool silenceWarnings = false) const;
|
||||
bool isShared() const {
|
||||
const PAKType* pak = m_pak.get();
|
||||
return pak ? !pak->m_noShare : false;
|
||||
}
|
||||
|
||||
hecl::SystemString getResourceRelativePath(const EntryType& a, const IDType& b) const;
|
||||
|
||||
|
||||
@@ -9,37 +9,37 @@ struct Beetle : IScriptObject {
|
||||
AT_DECL_DNA_YAML
|
||||
AT_DECL_DNAV
|
||||
String<-1> name;
|
||||
Value<atUint32> unknown1;
|
||||
Value<atUint32> flavor;
|
||||
Value<atVec3f> location;
|
||||
Value<atVec3f> orientation;
|
||||
Value<atVec3f> scale;
|
||||
PatternedInfo patternedInfo;
|
||||
ActorParameters actorParameters;
|
||||
DamageInfo damageInfo;
|
||||
Value<atVec3f> unknown2;
|
||||
Value<float> unknown3;
|
||||
DamageVulnerability damageVulnerabilty1;
|
||||
DamageVulnerability damageVulnerabilty2;
|
||||
UniqueID32 model;
|
||||
Value<atUint32> unknown4;
|
||||
Value<float> unknown5;
|
||||
Value<float> unknown6;
|
||||
DamageInfo touchDamage;
|
||||
Value<atVec3f> tailAimReference;
|
||||
Value<float> unused;
|
||||
DamageVulnerability tailVuln;
|
||||
DamageVulnerability platingVuln;
|
||||
UniqueID32 tailModel;
|
||||
Value<atUint32> entranceType;
|
||||
Value<float> initialAttackDelay;
|
||||
Value<float> retreatTime;
|
||||
|
||||
void addCMDLRigPairs(PAKRouter<PAKBridge>& pakRouter, CharacterAssociations<UniqueID32>& charAssoc) const {
|
||||
actorParameters.addCMDLRigPairs(pakRouter, charAssoc, patternedInfo.animationParameters);
|
||||
}
|
||||
|
||||
void nameIDs(PAKRouter<PAKBridge>& pakRouter) const {
|
||||
if (model) {
|
||||
PAK::Entry* ent = (PAK::Entry*)pakRouter.lookupEntry(model);
|
||||
ent->name = name + "_model";
|
||||
if (tailModel) {
|
||||
PAK::Entry* ent = (PAK::Entry*)pakRouter.lookupEntry(tailModel);
|
||||
ent->name = name + "_tailModel";
|
||||
}
|
||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||
}
|
||||
|
||||
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut, std::vector<hecl::ProjectPath>& lazyOut) const {
|
||||
g_curSpec->flattenDependencies(model, pathsOut);
|
||||
g_curSpec->flattenDependencies(tailModel, pathsOut);
|
||||
patternedInfo.depIDs(pathsOut);
|
||||
actorParameters.depIDs(pathsOut, lazyOut);
|
||||
}
|
||||
|
||||
@@ -13,10 +13,10 @@ struct Trigger : IScriptObject {
|
||||
Value<atVec3f> volume;
|
||||
DamageInfo damageInfo;
|
||||
Value<atVec3f> force;
|
||||
Value<atUint32> unknown;
|
||||
Value<atUint32> flags;
|
||||
Value<bool> active;
|
||||
Value<bool> unknown2;
|
||||
Value<bool> unknown3;
|
||||
Value<bool> deactivateOnEntered;
|
||||
Value<bool> deactivateOnExited;
|
||||
|
||||
zeus::CAABox getVISIAABB(hecl::blender::Token& btok) const {
|
||||
zeus::CVector3f halfExtent = zeus::CVector3f(volume) / 2.f;
|
||||
|
||||
Reference in New Issue
Block a user