1
0
Fork 0
mirror of https://github.com/zeldaret/oot.git synced 2025-08-20 22:11:16 +00:00

Remove THIS macro (#1047)

* remove THIS

* fix

* forgot dorf
This commit is contained in:
fig02 2021-12-04 11:33:00 -05:00 committed by GitHub
parent 68899c2e33
commit e635e34265
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
433 changed files with 1996 additions and 2859 deletions

View file

@ -10,8 +10,6 @@
#define FLAGS 0x00000010
#define THIS ((DemoExt*)thisx)
typedef enum {
/* 0x00 */ EXT_WAIT,
/* 0x01 */ EXT_MAINTAIN,
@ -32,7 +30,7 @@ void DemoExt_Destroy(Actor* thisx, GlobalContext* globalCtx) {
}
void DemoExt_Init(Actor* thisx, GlobalContext* globalCtx) {
DemoExt* this = THIS;
DemoExt* this = (DemoExt*)thisx;
this->scrollIncr[0] = 25;
this->scrollIncr[1] = 40;
@ -170,7 +168,7 @@ static DemoExtActionFunc sActionFuncs[] = {
};
void DemoExt_Update(Actor* thisx, GlobalContext* globalCtx) {
DemoExt* this = THIS;
DemoExt* this = (DemoExt*)thisx;
if ((this->action < EXT_WAIT) || (this->action > EXT_DISPELL) || sActionFuncs[this->action] == NULL) {
// "Main mode is abnormal!"
@ -184,7 +182,7 @@ void DemoExt_DrawNothing(Actor* thisx, GlobalContext* globalCtx) {
}
void DemoExt_DrawVortex(Actor* thisx, GlobalContext* globalCtx) {
DemoExt* this = THIS;
DemoExt* this = (DemoExt*)thisx;
Mtx* mtx;
GraphicsContext* gfxCtx;
s16* curScroll;
@ -224,7 +222,7 @@ static DemoExtDrawFunc sDrawFuncs[] = {
};
void DemoExt_Draw(Actor* thisx, GlobalContext* globalCtx) {
DemoExt* this = THIS;
DemoExt* this = (DemoExt*)thisx;
if ((this->drawMode < EXT_DRAW_NOTHING) || (this->drawMode > EXT_DRAW_VORTEX) ||
sDrawFuncs[this->drawMode] == NULL) {