1#include <game/mLib/m_3d.hpp>
4 if (allocator ==
nullptr) {
5 allocator = internal::l_allocator_p;
9 if (objSize ==
nullptr) {
13 nw4r::g3d::AnmObjVisRes::Construct(
nullptr, objSize, anmVis, mdl);
14 if (!createAllocator(allocator, objSize)) {
18 mpObj = nw4r::g3d::AnmObjVisRes::Construct(&mAllocator, &size, anmVis, mdl);
19 if (!mpObj->Bind(mdl)) {
27void m3d::anmVis_c::setAnm(m3d::bmdl_c &mdl, nw4r::g3d::ResAnmVis anmVis,
m3d::playMode_e playMode) {
28 nw4r::g3d::ScnMdlSimple::AnmObjType anmType = (nw4r::g3d::ScnMdlSimple::AnmObjType) getType();
29 mdl.removeAnm(anmType);
34 mpObj = nw4r::g3d::AnmObjVisRes::Construct(&mAllocator, &size, anmVis, mdl.getResMdl());
35 mpObj->Bind(mdl.getResMdl());
36 setFrmCtrlDefault(anmVis, playMode);
39void m3d::anmVis_c::setFrmCtrlDefault(nw4r::g3d::ResAnmVis &anmVis,
m3d::playMode_e playMode) {
43 fanm_c::set(anmVis.getDuration(), playMode, 1.0f, -1.0f);
@ MEM_FRMHEAP_FREE_ALL
Deallocates all memory blocks from the heap.
void set(float duration, m3d::playMode_e playMode, float updateRate, float startFrame)
Starts the animation with the given parameters.
An allocator class that wraps an EGG:Allocator .
@ FORWARD_ONCE
Play the animation forward once.
@ FORWARD_LOOP
Play the animation forward in a loop.
@ PLAYMODE_INHERIT
Use the play mode of the parent.