mirror of
https://github.com/encounter/tp.git
synced 2026-03-30 11:40:53 -07:00
a61e3491f7
* initial freezard actor struct + setActionMode OK * daE_FZ_Draw * setReflectAngle * mBoundSoundset * daE_FZ_Execute & execute * demoDelete * daE_FZ_Delete & _delete * CreateHeap * useHeapInit * cc_set * mtx_set * action WIP * way_gake_check * executeRollMove * executeMove * draw WIP * executeDamage * checkpoint * create * checkpoint * daE_FZ_c::executeWait * checkpoint * daE_FZ_c::damage_check almost done * rm asm * rm headers * setup_profile WIP + doxygen update * fix merge issues * docs fix? * fix2 * doxygen updates * setup g_profile_E_FZ, profile setup script WIP * update github actions * update progress.md
46 lines
911 B
C++
46 lines
911 B
C++
#ifndef JUTNAMETAB_H
|
|
#define JUTNAMETAB_H
|
|
|
|
#include "dolphin/types.h"
|
|
|
|
/**
|
|
* @ingroup jsystem-jutility
|
|
*
|
|
*/
|
|
struct ResNTAB {
|
|
u16 mEntryNum;
|
|
u16 mPad0;
|
|
struct Entry {
|
|
u16 mKeyCode;
|
|
u16 mOffs;
|
|
} mEntries[1];
|
|
|
|
inline const char* getName(u32 index) const {
|
|
return ((const char*)mEntries) + mEntries[index].mOffs - 4;
|
|
}
|
|
};
|
|
|
|
/**
|
|
* @ingroup jsystem-jutility
|
|
*
|
|
*/
|
|
class JUTNameTab {
|
|
public:
|
|
JUTNameTab();
|
|
JUTNameTab(const ResNTAB* pNameTable);
|
|
virtual ~JUTNameTab() {};
|
|
|
|
void setResource(const ResNTAB* pNameTable);
|
|
s32 getIndex(char const*) const;
|
|
const char* getName(u16 index) const;
|
|
u16 calcKeyCode(char const* pName) const;
|
|
const ResNTAB* getResNameTable() const { return mNameTable; }
|
|
|
|
private:
|
|
/* 0x4 */ const ResNTAB* mNameTable;
|
|
/* 0x8 */ const char* mpStrData;
|
|
/* 0xC */ u16 mNameNum;
|
|
};
|
|
|
|
#endif /* JUTNAMETAB_H */
|