diff options
| author | Aetias <144526980+AetiasHax@users.noreply.github.com> | 2025-07-01 21:15:26 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-07-01 21:15:26 +0200 |
| commit | c8a54735a1fec7923159ade581c59a5806e49a02 (patch) | |
| tree | c732cd037911024d576bfb22339322e13d3b575c /libs | |
| parent | cfb0123c4a582a7cd28e1a49e7642cba0260cc6f (diff) | |
| parent | 74312a0630f5d1f782e2176ea1845e7978e0933d (diff) | |
Merge pull request #72 from Yanis002/displaytext
Decomp DebugDisplay/DebugError
Diffstat (limited to 'libs')
| -rw-r--r-- | libs/c/include/stdarg.h | 24 | ||||
| -rw-r--r-- | libs/nds/include/nds/button.h | 12 |
2 files changed, 36 insertions, 0 deletions
diff --git a/libs/c/include/stdarg.h b/libs/c/include/stdarg.h new file mode 100644 index 00000000..4ace4037 --- /dev/null +++ b/libs/c/include/stdarg.h @@ -0,0 +1,24 @@ +#ifndef _C_STDARG_H +#define _C_STDARG_H + +extern "C" { +typedef char *va_list; + +#define __std(ref) ::std::ref +#define __fourbytealign(n) ((((unsigned long) (n)) + 3U) & ~3U) +#define __va_start(parm) ((__std(va_list))((char *) ((unsigned long) (&parm) & ~3U) + __fourbytealign(sizeof(parm)))) + +#define va_start(ap, parm) ((ap) = __va_start(parm)) +#define va_arg(ap, type) (*(type *) ((ap += __fourbytealign(sizeof(type))) - __fourbytealign(sizeof(type)))) +#define va_end(ap) ((void) 0) +} + +#if defined(__cplusplus) +namespace std { + using ::va_list; +}; + +using std::va_list; +#endif + +#endif diff --git a/libs/nds/include/nds/button.h b/libs/nds/include/nds/button.h new file mode 100644 index 00000000..a2e665a6 --- /dev/null +++ b/libs/nds/include/nds/button.h @@ -0,0 +1,12 @@ +#pragma once + +#define BTN_A (1 << 0) // 0x0001 +#define BTN_B (1 << 1) // 0x0002 +#define BTN_SELECT (1 << 2) // 0x0004 +#define BTN_START (1 << 3) // 0x0008 +#define BTN_DRIGHT (1 << 4) // 0x0010 +#define BTN_DLEFT (1 << 5) // 0x0020 +#define BTN_DUP (1 << 6) // 0x0040 +#define BTN_DDOWN (1 << 7) // 0x0080 +#define BTN_R (1 << 8) // 0x0100 +#define BTN_L (1 << 9) // 0x0200 |
