1
0
Fork 0
mirror of https://github.com/zeldaret/oot.git synced 2025-08-11 01:10:33 +00:00
oot/tools/ZAPD/ZAPD/ZPath.h
Anghelo Carvajal 5c147e5e03
ZAPD update: Gotta go fast! (#877)
* copy over the xml

* Rename anims

* A bunch of renames

* minor extract_assets fixes

* git subrepo pull --force tools/ZAPD

subrepo:
  subdir:   "tools/ZAPD"
  merged:   "820678b4e"
upstream:
  origin:   "https://github.com/zeldaret/ZAPD.git"
  branch:   "master"
  commit:   "820678b4e"
git-subrepo:
  version:  "0.4.3"
  origin:   "???"
  commit:   "???"

* Change rgb5a1 to rgba16

* eye and eyebrows

* some dlists

* git subrepo pull --force tools/ZAPD

subrepo:
  subdir:   "tools/ZAPD"
  merged:   "6be9af65d"
upstream:
  origin:   "https://github.com/zeldaret/ZAPD.git"
  branch:   "master"
  commit:   "6be9af65d"
git-subrepo:
  version:  "0.4.3"
  origin:   "???"
  commit:   "???"
2021-07-27 22:16:03 -04:00

53 lines
1.2 KiB
C++

#pragma once
#include "ZResource.h"
#include "ZVector.h"
class PathwayEntry : public ZResource
{
public:
PathwayEntry(ZFile* nParent);
void ParseRawData() override;
void DeclareReferences(const std::string& prefix) override;
std::string GetBodySourceCode() const;
std::string GetSourceTypeName() const override;
ZResourceType GetResourceType() const override;
size_t GetRawDataSize() const;
segptr_t GetListAddress() const;
protected:
int32_t numPoints;
int8_t unk1; // (MM Only)
int16_t unk2; // (MM Only)
segptr_t listSegmentAddress;
std::vector<ZVector> points;
};
class ZPath : public ZResource
{
public:
ZPath(ZFile* nParent);
void ExtractFromXML(tinyxml2::XMLElement* reader, uint32_t nRawDataIndex);
void ParseXML(tinyxml2::XMLElement* reader) override;
void ParseRawData() override;
void DeclareReferences(const std::string& prefix) override;
std::string GetBodySourceCode() const;
std::string GetSourceOutputCode(const std::string& prefix) override;
std::string GetSourceTypeName() const override;
ZResourceType GetResourceType() const override;
size_t GetRawDataSize() const override;
void SetNumPaths(uint32_t nNumPaths);
protected:
uint32_t numPaths;
std::vector<PathwayEntry> pathways;
};