The first commit

This commit is contained in:
Banjo Kazooie
2022-07-15 17:09:41 -05:00
commit dd13d34074
1087 changed files with 391897 additions and 0 deletions

53
src/core2/bsList.c Normal file
View File

@@ -0,0 +1,53 @@
#include <ultra64.h>
#include "functions.h"
#include "variables.h"
#include "bsint.h"
//TODO replace with bsList Count
bsState D_8037C700[166];
/* .code */
void bsList_clearAll(void){
s32 i = 0;
do{
bsList_setInitMethod(i, NULL);
bsList_setUpdateMethod(i, NULL);
bsList_setEndMethod(i, NULL);
bsList_setInterruptMethod(i, NULL);
i++;
}while(i != 0xa6);
}
void bsList_setInitMethod(enum bs_e i, bsStateMethod func){
D_8037C700[i].init_func = func;
}
void bsList_setUpdateMethod(s32 i, bsStateMethod func){
D_8037C700[i].update_func = func;
}
void bsList_setEndMethod(s32 i, bsStateMethod func){
D_8037C700[i].end_func = func;
}
void bsList_setInterruptMethod(s32 i, bsStateMethod func){
D_8037C700[i].interrupt_func = func;
}
bsStateMethod bsList_getInitMethod(s32 i){
return D_8037C700[i].init_func;
}
bsStateMethod bsList_getUpdateMethod(s32 i){
return D_8037C700[i].update_func;
}
bsStateMethod bsList_getEndMethod(s32 i){
return D_8037C700[i].end_func;
}
bsStateMethod bsList_getInterruptMethod(s32 i){
return D_8037C700[i].interrupt_func;
}