Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

EnZf OK and partially documented #988

Merged
merged 85 commits into from
Nov 6, 2021
Merged
Changes from 1 commit
Commits
Show all changes
85 commits
Select commit Hold shift + click to select a range
61e35c1
Match Destroy
EllipticEllipsis Jan 24, 2021
efff849
Matched Init
EllipticEllipsis Jan 24, 2021
b8398e7
3 more matched
EllipticEllipsis Jan 24, 2021
60ba3a9
15 functions matched, data imported
EllipticEllipsis Jan 25, 2021
7e19bea
16 matched
EllipticEllipsis Jan 25, 2021
d7dd84b
17 matched
EllipticEllipsis Jan 25, 2021
c7f8639
18 matched
EllipticEllipsis Jan 25, 2021
ba6ca22
formatting
EllipticEllipsis Jan 25, 2021
0cfcc2f
19 matched
EllipticEllipsis Jan 25, 2021
e8213d4
Fix unk_404
EllipticEllipsis Jan 25, 2021
0d9a89d
Draw matched, 20 in total
EllipticEllipsis Jan 26, 2021
e5c91c7
21 matched
EllipticEllipsis Jan 26, 2021
792fe01
22 matched
EllipticEllipsis Jan 26, 2021
b6fe97b
23 matched
EllipticEllipsis Jan 26, 2021
ce8d7c3
24 matched
EllipticEllipsis Jan 26, 2021
dad6364
25 matched
EllipticEllipsis Jan 26, 2021
a71f5bb
26 matched
EllipticEllipsis Jan 26, 2021
5344795
27 matched
EllipticEllipsis Jan 26, 2021
0266e71
28 matched
EllipticEllipsis Jan 26, 2021
71f5e3b
29 matched
EllipticEllipsis Jan 26, 2021
37deaea
30 matched
EllipticEllipsis Jan 26, 2021
f3782cc
31 matched
EllipticEllipsis Jan 26, 2021
5c24781
33 matched
EllipticEllipsis Jan 28, 2021
51c98fe
34 matched
EllipticEllipsis Jan 28, 2021
42a4d97
35 matched
EllipticEllipsis Jan 28, 2021
6043a5c
36 matched
EllipticEllipsis Jan 28, 2021
40b47bc
17 left
EllipticEllipsis Jan 28, 2021
c105568
16 left
EllipticEllipsis Jan 28, 2021
dd6c0a2
15 left
EllipticEllipsis Jan 28, 2021
f3719f2
14 left
EllipticEllipsis Jan 28, 2021
997d86c
13 left
EllipticEllipsis Jan 28, 2021
cbce667
12 left
EllipticEllipsis Jan 28, 2021
32b6b3d
11 left
EllipticEllipsis Jan 28, 2021
63582ea
10 left
EllipticEllipsis Jan 29, 2021
40163fe
spec
EllipticEllipsis Jan 29, 2021
296ff44
bss
EllipticEllipsis Jan 29, 2021
d02551f
9 left
EllipticEllipsis Jan 29, 2021
3aa2f72
8 left
EllipticEllipsis Jan 29, 2021
17b93e7
7 left
EllipticEllipsis Jan 29, 2021
eb4a971
6 left
EllipticEllipsis Jan 29, 2021
23a16af
5 left
EllipticEllipsis Jan 30, 2021
9feedd1
4 left
EllipticEllipsis Jan 30, 2021
e8f59bc
Merge remote-tracking branch 'upstream/master' into Zf
EllipticEllipsis Jan 31, 2021
18405f2
1 up to regalloc, 3 left
EllipticEllipsis Feb 1, 2021
b23da2a
2 left (+ 1 regalloc)
EllipticEllipsis Feb 1, 2021
de59f4c
More naming
EllipticEllipsis Feb 1, 2021
b4bc36b
1 + regalloc left
EllipticEllipsis Feb 1, 2021
a9acba3
Some naming
EllipticEllipsis Feb 1, 2021
232ae20
matches but for 2 words of stack in func_80B45748
EllipticEllipsis Feb 1, 2021
da7b486
Merge remote-tracking branch 'upstream/master' into Zf
EllipticEllipsis Feb 1, 2021
e514fa8
Delete some padding in header
EllipticEllipsis Feb 2, 2021
a63f008
Merge remote-tracking branch 'upstream/master' into Zf
EllipticEllipsis Feb 24, 2021
2e4a9e3
Merge remote-tracking branch 'upstream/master' into Zf
EllipticEllipsis Feb 24, 2021
4a7bb60
func_8003426C rename
EllipticEllipsis Feb 24, 2021
caa3d90
more failed matching attempts
EllipticEllipsis Mar 1, 2021
24bae8c
Merge remote-tracking branch 'upstream/master' into Zf
EllipticEllipsis Aug 9, 2021
b1ed333
Update to new function names
EllipticEllipsis Aug 10, 2021
874c65f
OK at last
EllipticEllipsis Aug 10, 2021
839aed7
Actually OK this time, removed pragmas, spec
EllipticEllipsis Aug 10, 2021
87b381f
Begin documentation
EllipticEllipsis Aug 11, 2021
2a04dbc
Few more names
EllipticEllipsis Aug 11, 2021
17812d6
Some more naming, added description to z_en_geldb.c
EllipticEllipsis Aug 12, 2021
922afad
Confirm platform categories
EllipticEllipsis Aug 12, 2021
5f1a69e
(Badly) named floor check functions
EllipticEllipsis Aug 19, 2021
c214345
Merge remote-tracking branch 'upstream/master' into Zf
EllipticEllipsis Aug 19, 2021
d7b7cc8
Merge remote-tracking branch 'upstream/master' into Zf
EllipticEllipsis Sep 19, 2021
6c74776
Make fighter actors playSpeed animation frame checks consistent (up t…
EllipticEllipsis Sep 20, 2021
2a94ef6
Merge remote-tracking branch 'upstream/master' into Zf
EllipticEllipsis Sep 25, 2021
b503f0c
Action enum, lot of work on the skeleton stuff in the object
EllipticEllipsis Sep 25, 2021
3c1216f
Lot of function and animation naming
EllipticEllipsis Sep 26, 2021
6cbfd1d
More naming, last of the hardcoded symbols
EllipticEllipsis Sep 26, 2021
27a265c
Some name cleanup
EllipticEllipsis Sep 26, 2021
a402253
Remove asm
EllipticEllipsis Sep 26, 2021
eadc446
Format
EllipticEllipsis Sep 26, 2021
5fdbc4e
Bit more cleanup
EllipticEllipsis Sep 26, 2021
2c0eabe
Dragorn review I
EllipticEllipsis Sep 26, 2021
d1e107b
undefined syms
EllipticEllipsis Sep 26, 2021
4d40431
Merge remote-tracking branch 'upstream/master' into Zf
EllipticEllipsis Sep 26, 2021
8132127
Correct limb names
EllipticEllipsis Oct 3, 2021
7a50fd7
Merge remote-tracking branch 'upstream/master' into Zf
EllipticEllipsis Oct 3, 2021
f40f575
Non-control flow review suggestions
EllipticEllipsis Oct 17, 2021
4f11f4d
Merge remote-tracking branch 'upstream/master' into Zf
EllipticEllipsis Oct 24, 2021
a1f87d0
Easy review stuff
EllipticEllipsis Oct 24, 2021
55cced0
Some more review
EllipticEllipsis Oct 29, 2021
71eec95
Merge branch 'master' into Zf
EllipticEllipsis Nov 6, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
19 matched
  • Loading branch information
EllipticEllipsis committed Jan 25, 2021
commit 0cfcc2f6b790d03ed77db9f9db2998137d68ba61
50 changes: 29 additions & 21 deletions src/overlays/actors/ovl_En_Zf/z_en_zf.c
Original file line number Diff line number Diff line change
Expand Up @@ -38,21 +38,9 @@ void func_80B48E50(EnZf* this, GlobalContext* globalCtx);
{ 4380.0f, 531.0f, -690.0f }, { 4197.0f, 531.0f, -646.0f }, { 4070.0f, 531.0f, -1575.0f },
{ 3930.0f, 531.0f, -1705.0f }, { 3780.0f, 531.0f, -1835.0f }, { 3560.0f, 531.0f, -1985.0f },
};
// {
// 0x455E8000, 0x42C80000, 0xC4BDA000, 0x45462000, 0x42C80000, 0xC4DCE000, 0x4545D000, 0x42C80000, 0xC50A9000,
// 0x455EB000, 0x42C80000, 0xC5185000, 0x4576A000, 0x42C80000, 0xC50A9000, 0x45766000, 0x42C80000, 0xC4DCA000,
// 0x4532D000, 0x42C80000, 0xC515A000, 0x452D8000, 0x42C80000, 0xC4F86000, 0x458D7800, 0x4404C000, 0xC48F4000,
// 0x458AD000, 0x4404C000, 0xC4AFA000, 0x45825000, 0x4404C000, 0xC4AE6000, 0x457BE000, 0x4404C000, 0xC4914000,
// 0x457AA000, 0x4404C000, 0xC45CC000, 0x45857000, 0x4404C000, 0xC44A8000, 0x458D4000, 0x4404C000, 0xC45C0000,
// 0x45852000, 0x4404C000, 0xC4816000, 0x4594A800, 0x4404C000, 0xC48F4000, 0x4570A000, 0x4404C000, 0xC45CC000,
// 0x4588E000, 0x4404C000, 0xC42C8000, 0x45832800, 0x4404C000, 0xC4218000, 0x457E6000, 0x4404C000, 0xC4C4E000,
// 0x4575A000, 0x4404C000, 0xC4D52000, 0x456C4000, 0x4404C000, 0xC4E56000, 0x455E8000, 0x4404C000, 0xC4F82000,
// };

// extern s16 D_80B4A1B0;

/* static */ s16 D_80B4A1B0 = 0;

// extern s16 D_80B4A1B4;
/* static */ s16 D_80B4A1B4 = 1;

const ActorInit En_Zf_InitVars = {
Expand Down Expand Up @@ -107,10 +95,6 @@ static ColliderQuadInit D_80B4A204 = {
{ { { 0.0f, 0.0f, 0.0f }, { 0.0f, 0.0f, 0.0f }, { 0.0f, 0.0f, 0.0f }, { 0.0f, 0.0f, 0.0f } } },
};

// extern ColliderCylinderInit D_80B4A1D8;
// extern ColliderQuadInit D_80B4A204;

// extern DamageTable D_80B4A254;
static DamageTable D_80B4A254 = {
/* Deku nut */ DMG_ENTRY(0, 0x1),
/* Deku stick */ DMG_ENTRY(2, 0x0),
Expand Down Expand Up @@ -146,14 +130,12 @@ static DamageTable D_80B4A254 = {
/* Unknown 2 */ DMG_ENTRY(0, 0x0),
};

// extern InitChainEntry D_80B4A274[];
static InitChainEntry D_80B4A274[] = {
ICHAIN_F32(targetArrowOffset, 2000, ICHAIN_CONTINUE),
ICHAIN_VEC3F_DIV1000(scale, 15, ICHAIN_CONTINUE),
ICHAIN_F32_DIV1000(gravity, -3500, ICHAIN_STOP),
};

// extern UNK_PTR D_80B4A280[];
s32 D_80B4A280[] = { 0x0601081C, 0x06010CAC, 0x06011070, 0x44898000, 0xC42F0000, 0x00000000 };

extern SkeletonHeader D_06006690;
Expand All @@ -176,8 +158,34 @@ void func_80B44050(EnZf* this, EnZfActionFunc actionFunc) {
this->actionFunc = actionFunc;
}

#pragma GLOBAL_ASM("asm/non_matchings/overlays/actors/ovl_En_Zf/func_80B44058.s")
s16 func_80B44058(EnZf* this, GlobalContext* globalCtx, f32 arg2);
// #pragma GLOBAL_ASM("asm/non_matchings/overlays/actors/ovl_En_Zf/func_80B44058.s")
s16 func_80B44058(EnZf *this, GlobalContext *globalCtx, f32 arg2) {
s16 ret;
s16 oldBgCheckFlags;
f32 sin;
f32 cos;
Vec3f oldPos;

if (arg2 == 0.0f) {
arg2 = ((this->actor.speedXZ >= 0.0f) ? 1.0f : -1.0f );
arg2 = ((this->actor.params >= 0) ? arg2 * 45.0f : arg2 * 30.0f );
}

oldPos = this->actor.world.pos;
oldBgCheckFlags = this->actor.bgCheckFlags;

sin = Math_SinS(this->actor.world.rot.y) * arg2;
cos = Math_CosS(this->actor.world.rot.y) * arg2;

this->actor.world.pos.x += sin;
this->actor.world.pos.z += cos;

Actor_UpdateBgCheckInfo(globalCtx, &this->actor, 0.0f, 0.0f, 0.0f, 0x1C);
this->actor.world.pos = oldPos;
ret = !(this->actor.bgCheckFlags & 1);
this->actor.bgCheckFlags = oldBgCheckFlags;
return ret;
}

#pragma GLOBAL_ASM("asm/non_matchings/overlays/actors/ovl_En_Zf/func_80B441C4.s")

Expand Down