summaryrefslogtreecommitdiff
path: root/mm/2s2h/resource/type/Path.h
blob: 649c71b7de2e3262b97a2efb26035c9d4b7861d6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
#pragma once

#include <cstdint>
#include <vector>
#include <ship/resource/Resource.h>
#include <libultraship/libultra/types.h>
#include "z64math.h"

namespace SOH {
typedef struct {
    /* 0x0 */ u8 count; // Number of points in the path
    /* 0x1 */ u8 additionalPathIndex;
    /* 0x2 */ s16 customValue; // Path specific to help distinguish different paths
    /* 0x4 */ Vec3s* points;   // Segment Address to the array of points
} PathDataMM;                  // size = 0x8

class PathMM : public Ship::Resource<PathDataMM> {
  public:
    using Resource::Resource;

    PathMM() : Resource(std::shared_ptr<Ship::ResourceInitData>()) {
    }

    PathDataMM* GetPointer();
    size_t GetPointerSize();

    uint32_t numPaths;
    std::vector<PathDataMM> pathData;
    std::vector<std::vector<Vec3s>> paths;
};

}; // namespace SOH