2018-10-06 20:42:33 -07:00
|
|
|
#pragma once
|
2016-02-04 17:27:03 -08:00
|
|
|
|
2019-09-23 12:00:23 -07:00
|
|
|
#include <utility>
|
|
|
|
#include <vector>
|
|
|
|
|
|
|
|
#include "Runtime/CToken.hpp"
|
2022-02-19 05:04:45 -08:00
|
|
|
#include "Runtime/Streams/IOStreams.hpp"
|
2019-09-23 12:00:23 -07:00
|
|
|
#include "Runtime/RetroTypes.hpp"
|
2016-02-04 17:27:03 -08:00
|
|
|
|
2021-04-10 01:42:06 -07:00
|
|
|
namespace metaforce {
|
2016-02-04 17:27:03 -08:00
|
|
|
class CSimplePool;
|
2016-02-10 22:58:33 -08:00
|
|
|
class CGenDescription;
|
2016-02-04 17:27:03 -08:00
|
|
|
|
2018-12-07 21:30:43 -08:00
|
|
|
class CSpawnSystemKeyframeData {
|
2016-02-10 22:58:33 -08:00
|
|
|
public:
|
2018-12-07 21:30:43 -08:00
|
|
|
class CSpawnSystemKeyframeInfo {
|
|
|
|
friend class CSpawnSystemKeyframeData;
|
|
|
|
u32 x0_id;
|
2016-02-10 22:58:33 -08:00
|
|
|
u32 x4;
|
2018-12-07 21:30:43 -08:00
|
|
|
u32 x8;
|
2016-02-10 22:58:33 -08:00
|
|
|
u32 xc;
|
2018-12-07 21:30:43 -08:00
|
|
|
TLockedToken<CGenDescription> x10_token;
|
|
|
|
bool x18_found = false;
|
|
|
|
void LoadToken(CSimplePool* pool);
|
|
|
|
|
|
|
|
public:
|
2020-03-25 18:25:11 -07:00
|
|
|
explicit CSpawnSystemKeyframeInfo(CInputStream& in);
|
2018-12-07 21:30:43 -08:00
|
|
|
TLockedToken<CGenDescription>& GetToken() { return x10_token; }
|
|
|
|
};
|
|
|
|
|
|
|
|
private:
|
|
|
|
u32 x0;
|
|
|
|
u32 x4;
|
|
|
|
u32 x8_endFrame;
|
|
|
|
u32 xc;
|
|
|
|
std::vector<std::pair<u32, std::vector<CSpawnSystemKeyframeInfo>>> x10_spawns;
|
|
|
|
|
2016-02-04 17:27:03 -08:00
|
|
|
public:
|
2020-03-25 18:25:11 -07:00
|
|
|
explicit CSpawnSystemKeyframeData(CInputStream& in);
|
2018-12-07 21:30:43 -08:00
|
|
|
void LoadAllSpawnedSystemTokens(CSimplePool* pool);
|
|
|
|
std::vector<CSpawnSystemKeyframeInfo>& GetSpawnedSystemsAtFrame(u32 frame);
|
2016-02-04 17:27:03 -08:00
|
|
|
};
|
|
|
|
|
2021-04-10 01:42:06 -07:00
|
|
|
} // namespace metaforce
|