Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
MorsGames
GitHub Repository: MorsGames/sm64plus
Path: blob/master/tools/ido5.3_recomp/helpers.h
7858 views
1
#ifndef HELPERS_H
2
#define HELPERS_H
3
4
#include <stdint.h>
5
6
#define MEM_U32(a) (*(uint32_t *)(mem + a))
7
#define MEM_S32(a) (*(int32_t *)(mem + a))
8
#define MEM_U16(a) (*(uint16_t *)(mem + ((a) ^ 2)))
9
#define MEM_S16(a) (*(int16_t *)(mem + ((a) ^ 2)))
10
#define MEM_U8(a) (*(uint8_t *)(mem + ((a) ^ 3)))
11
#define MEM_S8(a) (*(int8_t *)(mem + ((a) ^ 3)))
12
13
#endif
14
15