mirror of
https://github.com/zeldaret/tp
synced 2026-05-25 15:25:25 -04:00
4dc0cd9d09
* Fix missing arg to JUT_ASSERT * Fix some MWCC version diff errors * Compile m_Do_ext, d_demo, actor_mng * Add VSCode task to quickly switch between versions * Unlink magLift for debug * Update the hash of the debug dol The old cbea5fa... hash here was for the dol generated by the alf2dol.py script, which produces incorrect alignment. The dol with the new hash can be obtained by using `dtk elf2dol` to convert the debug .alf file to a dol. The DOL now builds OK. * Fix all debug REL dtor splits All RELs now also build OK, meaning `ninja build/ShieldD/ok` now succeeds. * Add genMessage declarations to all HIO subclasses * Fixing more compilation errors * m_Do_mtx 100% on debug Cannot be linked due to weak function name mangling? * Improve various matches * Fix all remaining compilation errors * Fix new compilation errors from main * Fix retail regression * Link f_pc_profile_lst
47 lines
1.3 KiB
C++
47 lines
1.3 KiB
C++
#ifndef DEFINE_H
|
|
#define DEFINE_H
|
|
|
|
#include "types.h"
|
|
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
|
|
class JGadget_outMessage {
|
|
public:
|
|
typedef void (*MessageFunc)(const char*, int, const char*);
|
|
|
|
static void warning(const char*, int, const char*);
|
|
|
|
JGadget_outMessage(MessageFunc fn, const char* file, int line);
|
|
~JGadget_outMessage();
|
|
|
|
JGadget_outMessage& operator<<(int param_1) { return *this << (s32)param_1; }
|
|
JGadget_outMessage& operator<<(u16);
|
|
JGadget_outMessage& operator<<(unsigned int);
|
|
JGadget_outMessage& operator<<(u8);
|
|
JGadget_outMessage& operator<<(const char* str);
|
|
JGadget_outMessage& operator<<(s8);
|
|
JGadget_outMessage& operator<<(s32);
|
|
JGadget_outMessage& operator<<(u32);
|
|
JGadget_outMessage& operator<<(const void*);
|
|
|
|
private:
|
|
MessageFunc mMsgFunc;
|
|
char mBuffer[256];
|
|
char* mWrite_p;
|
|
char* mFile;
|
|
int mLine;
|
|
};
|
|
|
|
#define JGADGET_ASSERTWARN(cond) ((cond) || (false))
|
|
|
|
#define JGADGET_EXITWARN(cond) \
|
|
if (!(cond)) { \
|
|
false; \
|
|
return false; \
|
|
}
|
|
}
|
|
#endif
|
|
|
|
#endif
|