mirror of
https://github.com/TwilitRealm/dusklight
synced 2026-08-19 21:11:59 -04:00
Annotate all data with DUSK_GAME_DATA (#2214)
The hope of auto-importing data via lld MinGW + pseudo_reloc is now dead thanks to ARM64, so I just wrote a script to go annotate every exported data symbol in the game instead.
This commit is contained in:
@@ -41,7 +41,7 @@ BOOL fpcBs_Is_JustOfType(int i_typeA, int i_typeB) {
|
||||
}
|
||||
}
|
||||
|
||||
int g_fpcBs_type;
|
||||
DUSK_GAME_DATA int g_fpcBs_type;
|
||||
|
||||
int fpcBs_MakeOfType(int* i_type) {
|
||||
static int t_type = 0x9130000;
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
|
||||
#include "f_pc/f_pc_create_tag.h"
|
||||
|
||||
node_list_class g_fpcCtTg_Queue = {NULL, NULL, 0};
|
||||
DUSK_GAME_DATA node_list_class g_fpcCtTg_Queue = {NULL, NULL, 0};
|
||||
|
||||
void fpcCtTg_ToCreateQ(create_tag* i_createTag) {
|
||||
cTg_Addition(&g_fpcCtTg_Queue, &i_createTag->base);
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
#include "f_pc/f_pc_delete_tag.h"
|
||||
#include "f_pc/f_pc_debug_sv.h"
|
||||
|
||||
node_list_class g_fpcDtTg_Queue = {NULL, NULL, 0};
|
||||
DUSK_GAME_DATA node_list_class g_fpcDtTg_Queue = {NULL, NULL, 0};
|
||||
|
||||
BOOL fpcDtTg_IsEmpty() {
|
||||
if (g_fpcDtTg_Queue.mSize == 0) {
|
||||
|
||||
@@ -82,7 +82,7 @@ void fpcLy_CreatedMesg(layer_class* i_layer) {
|
||||
}
|
||||
}
|
||||
|
||||
layer_class l_fpcLy_Crear = {
|
||||
DUSK_GAME_DATA layer_class l_fpcLy_Crear = {
|
||||
NULL, NULL, 0, 0xFFFFFFFF, NULL, 0, NULL, NULL, NULL, 0, 0, 0,
|
||||
};
|
||||
|
||||
|
||||
@@ -56,7 +56,7 @@ int fpcLf_Delete(leafdraw_class* i_leaf) {
|
||||
return ret;
|
||||
}
|
||||
|
||||
int g_fpcLf_type;
|
||||
DUSK_GAME_DATA int g_fpcLf_type;
|
||||
|
||||
int fpcLf_Create(leafdraw_class* i_leaf) {
|
||||
if (LEAFDRAW_BASE(i_leaf).state.init_state == 0) {
|
||||
@@ -74,7 +74,7 @@ int fpcLf_Create(leafdraw_class* i_leaf) {
|
||||
return ret;
|
||||
}
|
||||
|
||||
leafdraw_method_class DUSK_CONST g_fpcLf_Method = {
|
||||
DUSK_GAME_DATA leafdraw_method_class DUSK_CONST g_fpcLf_Method = {
|
||||
(process_method_func)fpcLf_Create, (process_method_func)fpcLf_Delete,
|
||||
(process_method_func)fpcLf_Execute, (process_method_func)fpcLf_IsDelete,
|
||||
(process_method_func)fpcLf_Draw,
|
||||
|
||||
@@ -16,7 +16,7 @@ void fpcLn_Create() {
|
||||
cLs_Create(line_node++);
|
||||
}
|
||||
|
||||
node_lists_tree_class g_fpcLn_Queue = {
|
||||
DUSK_GAME_DATA node_lists_tree_class g_fpcLn_Queue = {
|
||||
l_fpcLn_Line,
|
||||
ARRAY_SIZEU(l_fpcLn_Line),
|
||||
};
|
||||
|
||||
@@ -61,7 +61,7 @@ int fpcNd_Execute(process_node_class* i_procNode) {
|
||||
return ret;
|
||||
}
|
||||
|
||||
int g_fpcNd_type;
|
||||
DUSK_GAME_DATA int g_fpcNd_type;
|
||||
|
||||
void* fpcNd_IsCreatingFromUnder(void* i_procNode) {
|
||||
if (i_procNode != NULL && fpcBs_Is_JustOfType(g_fpcNd_type, ((process_node_class*)i_procNode)->base.subtype) != FALSE)
|
||||
@@ -79,7 +79,7 @@ void* fpcNd_IsCreatingFromUnder(void* i_procNode) {
|
||||
return NULL;
|
||||
}
|
||||
|
||||
BOOL g_fpcNd_IsCheckOfDeleteTiming = TRUE;
|
||||
DUSK_GAME_DATA BOOL g_fpcNd_IsCheckOfDeleteTiming = TRUE;
|
||||
|
||||
int fpcNd_IsDeleteTiming(process_node_class* i_procNode) {
|
||||
if (g_fpcNd_IsCheckOfDeleteTiming == TRUE && fpcNd_IsCreatingFromUnder(i_procNode) != NULL) {
|
||||
@@ -124,7 +124,7 @@ int fpcNd_Create(process_node_class* i_procNode) {
|
||||
return ret;
|
||||
}
|
||||
|
||||
nodedraw_method_class g_fpcNd_Method = {
|
||||
DUSK_GAME_DATA nodedraw_method_class g_fpcNd_Method = {
|
||||
(process_method_func)fpcNd_Create, (process_method_func)fpcNd_Delete,
|
||||
(process_method_func)fpcNd_Execute, (process_method_func)fpcNd_IsDelete,
|
||||
(process_method_func)fpcNd_Draw,
|
||||
|
||||
@@ -8,9 +8,9 @@
|
||||
|
||||
#ifndef __MWERKS__
|
||||
// Forward declare the static list from f_pc_profile_lst.cpp
|
||||
extern process_profile_definition DUSK_CONST* DUSK_CONST g_fpcPfLst_ProfileList[];
|
||||
DUSK_GAME_EXTERN process_profile_definition DUSK_CONST* DUSK_CONST g_fpcPfLst_ProfileList[];
|
||||
// On PC: Direct pointer to static array
|
||||
process_profile_definition DUSK_CONST* DUSK_CONST* DUSK_CONST g_fpcPf_ProfileList_p = g_fpcPfLst_ProfileList;
|
||||
DUSK_GAME_DATA process_profile_definition DUSK_CONST* DUSK_CONST* DUSK_CONST g_fpcPf_ProfileList_p = g_fpcPfLst_ProfileList;
|
||||
#else
|
||||
// On Console: Pointer initialized by REL module prolog
|
||||
process_profile_definition** g_fpcPf_ProfileList_p;
|
||||
|
||||
@@ -811,7 +811,7 @@ extern "C" void ModuleEpilog() {
|
||||
}
|
||||
|
||||
#else
|
||||
process_profile_definition DUSK_CONST* DUSK_CONST g_fpcPfLst_ProfileList[] = {
|
||||
DUSK_GAME_DATA process_profile_definition DUSK_CONST* DUSK_CONST g_fpcPfLst_ProfileList[] = {
|
||||
&g_profile_OVERLAP0.base.base,
|
||||
&g_profile_OVERLAP1.base.base,
|
||||
&g_profile_OVERLAP3.base.base,
|
||||
|
||||
Reference in New Issue
Block a user