z_player documentation 2024-10-11 (#4407)

* Add names to start of typedefs

* Idle stuff

* 2 functions

* Player state flags

* Name functions + misc

* ActionChange => ActionHandler

* Some player unks

* More player unks

* Header misc

* Misc

* More misc

* Player Actions

* Missed comments

* Move ship specific stuff

* Fix build

* CsCmdActorAction to CsCmdActorCue

* Fix build
This commit is contained in:
Pepe20129 2024-10-17 20:55:31 +02:00 committed by GitHub
commit b5c6545d6f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
65 changed files with 3603 additions and 2562 deletions

View file

@ -8,17 +8,23 @@
// #define __attribute__(x)
// #endif
// #ifndef AVOID_UB
// #define BAD_RETURN(type) type
// #else
// #define BAD_RETURN(type) void
// #endif
// SoH [Port] Always use the AVOID_UB version (we don't set AVOID_UB while building yet)
/*
#ifndef AVOID_UB
#define BAD_RETURN(type) type
#else
#define BAD_RETURN(type) void
#endif
*/
#define BAD_RETURN(type) void
// Upstream TODO: Document reasoning for change
// #define UNUSED __attribute__((unused))
// #define FALLTHROUGH __attribute__((fallthrough))
#define ARRAY_COUNT(arr) (s32)(sizeof(arr) / sizeof(arr[0]))
#define ARRAY_COUNTU(arr) (u32)(sizeof(arr) / sizeof(arr[0]))
#define ARRAY_COUNT_2D(arr) (s32)(sizeof(arr) / sizeof(arr[0][0]))
#define PHYSICAL_TO_VIRTUAL(addr) (void*)((uintptr_t)(addr) + 0x80000000)
#define VIRTUAL_TO_PHYSICAL(addr) (uintptr_t)((u8*)(addr) - 0x80000000)