NSMBW-Decomp
A decompilation of New Super Mario Bros. Wii
Loading...
Searching...
No Matches
anm_tex_pat.hpp
1#pragma once
2#include <game/mLib/m_3d/banm.hpp>
3#include <game/mLib/m_3d/bmdl.hpp>
4#include <game/mLib/m_3d/fanm.hpp>
5
6namespace m3d {
7 class anmTexPat_c : public banm_c {
8 public:
9 anmTexPat_c() : children(nullptr) {}
10 virtual ~anmTexPat_c();
11 virtual void remove();
12 virtual void play();
13 virtual banm_c::anmType_e getType() const { return banm_c::TYPE_ANM_TEX_PAT; };
14
15 static size_t heapCost(nw4r::g3d::ResMdl mdl, nw4r::g3d::ResAnmTexPat anmTexPat, long count, bool calcAligned);
16 bool create(nw4r::g3d::ResMdl mdl, nw4r::g3d::ResAnmTexPat anmTexPat, mAllocator_c *allocator, size_t *objSize, long count);
17 void setAnm(m3d::bmdl_c &mdl, nw4r::g3d::ResAnmTexPat anmTexPat, long idx, m3d::playMode_e playMode);
18 void releaseAnm(long idx);
19 void play(long idx);
20 float getFrame(long idx) const;
21 void setFrame(float frame, long idx);
22 float getRate(long idx) const;
23 void setRate(float rate, long idx);
24 bool isStop(long idx) const;
25 bool checkFrame(float frame, long idx) const;
26 void setPlayMode(m3d::playMode_e playMode, long idx);
27 float getFrameMax(long idx) const;
28 float getFrameStart(long idx) const;
29
30 bool create(nw4r::g3d::ResMdl mdl, nw4r::g3d::ResAnmTexPat anmTexPat, mAllocator_c *allocator, int count) {
31 return create(mdl, anmTexPat, allocator, nullptr, count);
32 }
33
34 bool create(nw4r::g3d::ResMdl mdl, nw4r::g3d::ResAnmTexPat anmTexPat, mAllocator_c *allocator) {
35 return create(mdl, anmTexPat, allocator, 1);
36 }
37
38 class child_c : public fanm_c {
39 public:
40 virtual banm_c::anmType_e getType( void ) const { return banm_c::TYPE_ANM_TEX_PAT; };
41 virtual ~child_c() {}
42
43 static size_t heapCost(nw4r::g3d::ResMdl mdl, nw4r::g3d::ResAnmTexPat anmTexPat, bool calcAligned);
44 bool create(nw4r::g3d::ResMdl mdl, nw4r::g3d::ResAnmTexPat anmTexPat, mAllocator_c *allocator, size_t *objSize);
45 void setAnm(m3d::bmdl_c &mdl, nw4r::g3d::ResAnmTexPat anmTexPat, m3d::playMode_e playMode);
46 void releaseAnm();
47 void setFrmCtrlDefault(nw4r::g3d::ResAnmTexPat &anmTexPat, m3d::playMode_e playMode);
48 };
49
50 child_c *children;
51 };
52}
fanm_c()
Constructs an animation object.
Definition fanm.cpp:3
An allocator class that wraps an EGG:Allocator .
mLib 3D library
Definition anm_chr.hpp:5
playMode_e
Definition banm.hpp:7