1
0
Fork 0
mirror of https://github.com/zeldaret/oot.git synced 2025-08-10 17:00:19 +00:00

Docs for the Anime part of SkelAnime (#517)

* Darkmeiro decompilation

Bg_Gnd_Darkmeiro decompiled, matched, and documented.

* give this a shot

* fix conflict

* one more try

* could be useful

* whoops

* ZAP2 stuff

* ZAP why

* ZAP again

* more names

* so many names

* we got subsystems now

* slight cleanup

* merge part 2

* new naming scheme

* slight adjustment

* no limit

* syms maybe

* step one

* OK, it's fixed

* table

* some names and such

* comments**

* update zap

* gitkeep to please jenkins

* ZAP

* fixer

* fixer2

* fixer3

* zap

Co-authored-by: petrie911 <pmontag@DESKTOP-LG8A167.localdomain>
Co-authored-by: fig <fig02srl@gmail.com>
This commit is contained in:
petrie911 2020-12-29 16:46:46 -06:00 committed by GitHub
parent e4d88bf942
commit 2dfa188706
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
1187 changed files with 5434 additions and 5367 deletions

View file

@ -148,15 +148,14 @@ void EnButte_Init(Actor* thisx, GlobalContext* globalCtx) {
this->actor.uncullZoneScale = 200.0f;
}
SkelAnime_Init(globalCtx, &this->skelAnime, &D_050036F0, &D_05002470, this->limbDrawTable,
this->transitionDrawTable, 8);
SkelAnime_Init(globalCtx, &this->skelAnime, &D_050036F0, &D_05002470, this->jointTable, this->morphTable, 8);
Collider_InitJntSph(globalCtx, &this->collider);
Collider_SetJntSph(globalCtx, &this->collider, &this->actor, &sColliderInit, this->colliderItems);
this->actor.colChkInfo.mass = 0;
this->unk_25C = Rand_ZeroOne() * 0xFFFF;
this->unk_25E = Rand_ZeroOne() * 0xFFFF;
this->unk_260 = Rand_ZeroOne() * 0xFFFF;
SkelAnime_ChangeAnim(&this->skelAnime, &D_05002470, 1.0f, 0.0f, 0.0f, 1, 0.0f);
Animation_Change(&this->skelAnime, &D_05002470, 1.0f, 0.0f, 0.0f, 1, 0.0f);
EnButte_SetupFlyAround(this);
this->actor.shape.rot.x -= 0x2320;
this->drawSkelAnime = true;
@ -252,8 +251,8 @@ void EnButte_FlyAround(EnButte* this, GlobalContext* globalCtx) {
animSpeed = this->actor.speedXZ / 2.0f + Rand_ZeroOne() * 0.2f + (1.0f - Math_SinS(this->unk_260)) * 0.15f +
(1.0f - Math_SinS(this->unk_25E)) * 0.3f + minAnimSpeed;
this->skelAnime.animPlaybackSpeed = CLAMP(animSpeed, 0.2f, 1.5f);
SkelAnime_FrameUpdateMatrix(&this->skelAnime);
this->skelAnime.playSpeed = CLAMP(animSpeed, 0.2f, 1.5f);
SkelAnime_Update(&this->skelAnime);
if (this->timer <= 0) {
EnButte_SelectFlightParams(this, &sFlyAroundParams[this->flightParamsIdx]);
@ -314,8 +313,8 @@ void EnButte_FollowLink(EnButte* this, GlobalContext* globalCtx) {
animSpeed = this->actor.speedXZ / 2.0f + Rand_ZeroOne() * 0.2f + (1.0f - Math_SinS(this->unk_260)) * 0.15f +
(1.0f - Math_SinS(this->unk_25E)) * 0.3f + minAnimSpeed;
this->skelAnime.animPlaybackSpeed = CLAMP(animSpeed, 0.2f, 1.5f);
SkelAnime_FrameUpdateMatrix(&this->skelAnime);
this->skelAnime.playSpeed = CLAMP(animSpeed, 0.2f, 1.5f);
SkelAnime_Update(&this->skelAnime);
if (this->timer <= 0) {
EnButte_SelectFlightParams(this, &sFollowLinkParams[this->flightParamsIdx]);
@ -339,13 +338,13 @@ void EnButte_FollowLink(EnButte* this, GlobalContext* globalCtx) {
void EnButte_SetupTransformIntoFairy(EnButte* this) {
this->timer = 9;
this->actor.flags |= 0x10;
this->skelAnime.animPlaybackSpeed = 1.0f;
this->skelAnime.playSpeed = 1.0f;
EnButte_ResetTransformationEffect();
this->actionFunc = EnButte_TransformIntoFairy;
}
void EnButte_TransformIntoFairy(EnButte* this, GlobalContext* globalCtx) {
SkelAnime_FrameUpdateMatrix(&this->skelAnime);
SkelAnime_Update(&this->skelAnime);
EnButte_UpdateTransformationEffect();
if (this->timer == 5) {
@ -413,7 +412,7 @@ void EnButte_Draw(Actor* thisx, GlobalContext* globalCtx) {
if (this->drawSkelAnime) {
func_80093D18(globalCtx->state.gfxCtx);
SkelAnime_DrawOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, NULL, NULL, NULL);
SkelAnime_DrawOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.jointTable, NULL, NULL, NULL);
func_800628A4(0, &this->collider);
}

View file

@ -13,8 +13,8 @@ typedef struct EnButte {
/* 0x014C */ ColliderJntSph collider;
/* 0x016C */ ColliderJntSphItem colliderItems[1];
/* 0x01AC */ SkelAnime skelAnime;
/* 0x01F0 */ Vec3s limbDrawTable[8];
/* 0x0220 */ Vec3s transitionDrawTable[8];
/* 0x01F0 */ Vec3s jointTable[8];
/* 0x0220 */ Vec3s morphTable[8];
/* 0x0250 */ EnButteActionFunc actionFunc;
/* 0x0254 */ s16 timer;
/* 0x0256 */ u8 flightParamsIdx;