1
0
Fork 0
mirror of https://github.com/zeldaret/oot.git synced 2025-08-08 15:30:14 +00:00

Big actor cleanup (fixed) (#69)

* Started doing cleanup

* did more work

* did more migration

* migrated more rodata and worked on some structs

* did more work

* Removal of ROOM field from initvars, some rodata migration, some string decompilation

* General update

* Decompiled vt strings

* Tool work

* Tool improvements

* 270 overlay rodata files remaining

* better float handling

* floats

* Many more floats

* migrated boss_mo

* assorted fixes

* Migrated 10

* tool improvements

* migrated 10

* 10 more

* 1 more

* did a few more

* fixes

* 10 more

* more floats

* Did some more, updated migrate-rodata.py to 'modify' the C file after processing in order to make to compiler process it as if it was changed.

* removed changes made to script by accident

* migrated largest rodata - ovl_fishing

* Did some more

* 114 remaining

* 99 left !

* almost done migrating rodata

* did some more, done for tonight

* almost done, tried add support to the script for z_player

* All possible rodata migrated in actor overlays

* update

* removed static from all overlays, ran format.sh

* Removed unknown actor structs

* converted a few floats

* Added new lines to header files that were missing them. Removed unused asm files

* Removed unused asm files

* Formatting newlines

Further formatting

spacing

.float spacing

More space formatting

More spacing formatting

Removing .balign 4 after floats

Co-authored-by: Ethan Roseman <ethteck@gmail.com>
This commit is contained in:
Lucas Shaw 2020-04-14 11:16:34 -07:00 committed by GitHub
parent 5aef81071e
commit 045a92d7c3
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
10327 changed files with 33390 additions and 45661 deletions

View file

@ -6,20 +6,18 @@
#include "z_en_nutsball.h"
#define ROOM 0x00
#define FLAGS 0x00000010
static void EnNutsball_Init(EnNutsball* this, GlobalContext* globalCtx);
static void EnNutsball_Destroy(EnNutsball* this, GlobalContext* globalCtx);
static void EnNutsball_Update(EnNutsball* this, GlobalContext* globalCtx);
static void func_80ABBB34(EnNutsball* this, GlobalContext* globalCtx);
static void func_80ABBBA8(EnNutsball* this, GlobalContext* globalCtx);
static void EnNutsball_Draw(EnNutsball* this, GlobalContext* globalCtx);
void EnNutsball_Init(EnNutsball* this, GlobalContext* globalCtx);
void EnNutsball_Destroy(EnNutsball* this, GlobalContext* globalCtx);
void EnNutsball_Update(EnNutsball* this, GlobalContext* globalCtx);
void func_80ABBB34(EnNutsball* this, GlobalContext* globalCtx);
void func_80ABBBA8(EnNutsball* this, GlobalContext* globalCtx);
void EnNutsball_Draw(EnNutsball* this, GlobalContext* globalCtx);
const ActorInit En_Nutsball_InitVars = {
ACTOR_EN_NUTSBALL,
ACTORTYPE_PROP,
ROOM,
FLAGS,
OBJECT_GAMEPLAY_KEEP,
sizeof(EnNutsball),
@ -38,7 +36,7 @@ static ColliderCylinderInit cylinderInitData = {
static s16 objectTbl[] = { OBJECT_DEKUNUTS, OBJECT_HINTNUTS, OBJECT_SHOPNUTS, OBJECT_DNS, OBJECT_DNK };
static u32 dListTbl[] = { 0x06002028, 0x060012F0, 0x06004008, 0x06002410, 0x06001890 };
static void EnNutsball_Init(EnNutsball* this, GlobalContext* globalCtx) {
void EnNutsball_Init(EnNutsball* this, GlobalContext* globalCtx) {
s32 pad[2];
ActorShape_Init(&this->actor.shape, 400.0f, ActorShadow_DrawFunc_Circle, 13.0f);
@ -53,12 +51,12 @@ static void EnNutsball_Init(EnNutsball* this, GlobalContext* globalCtx) {
}
}
static void EnNutsball_Destroy(EnNutsball* this, GlobalContext* globalCtx) {
void EnNutsball_Destroy(EnNutsball* this, GlobalContext* globalCtx) {
ColliderCylinderMain* collider = &this->collider;
ActorCollider_FreeCylinder(globalCtx, collider);
}
static void func_80ABBB34(EnNutsball* this, GlobalContext* globalCtx) {
void func_80ABBB34(EnNutsball* this, GlobalContext* globalCtx) {
if (Object_IsLoaded(&globalCtx->objectCtx, this->objBankIndex)) {
this->actor.objBankIndex = this->objBankIndex;
this->actor.draw = (ActorFunc)EnNutsball_Draw;
@ -69,7 +67,7 @@ static void func_80ABBB34(EnNutsball* this, GlobalContext* globalCtx) {
}
}
static void func_80ABBBA8(EnNutsball* this, GlobalContext* globalCtx) {
void func_80ABBBA8(EnNutsball* this, GlobalContext* globalCtx) {
Player* player = PLAYER;
Vec3s sp4C;
Vec3f sp40;
@ -114,7 +112,7 @@ static void func_80ABBBA8(EnNutsball* this, GlobalContext* globalCtx) {
}
}
static void EnNutsball_Update(EnNutsball* this, GlobalContext* globalCtx) {
void EnNutsball_Update(EnNutsball* this, GlobalContext* globalCtx) {
EnNutsball* nutsball = this;
Player* player = PLAYER;
s32 pad;
@ -134,7 +132,7 @@ static void EnNutsball_Update(EnNutsball* this, GlobalContext* globalCtx) {
}
}
static void EnNutsball_Draw(EnNutsball* this, GlobalContext* globalCtx) {
void EnNutsball_Draw(EnNutsball* this, GlobalContext* globalCtx) {
GraphicsContext* gfxCtx = globalCtx->state.gfxCtx;
Gfx* dispRefs[5];