Files
tp/include/JSystem/JSupport/JSupport.h
T
Pheenoh 7fd7d0c1f3 d_a_obj_carry work, SETUP_ACTOR macro, header cleanup (#1885)
* d_a_obj_carry work, SETUP_ACTOR macro

* rm headers, add script

* progress

* macro rename, consistent spacing
2023-08-16 12:07:52 -07:00

23 lines
355 B
C++

#ifndef JSUPPORT_H
#define JSUPPORT_H
template <typename T>
T* JSUConvertOffsetToPtr(const void* ptr, const void* offset) {
if (offset == NULL) {
return NULL;
} else {
return (T*)((s32)ptr + (s32)offset);
}
}
inline u8 JSULoByte(u16 in) {
return in & 0xff;
}
inline u8 JSUHiByte(u16 in) {
return in >> 8;
}
#endif