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

Document Culling (#2318)

* document culling

* format

* depth -> distance

* format

* var name

* new graph link

* rephrase actor flags

* tharo's comments + some more tweaks

* is this causing the problem?

* change wording

* cant scope the temp

* format

* dragorn review

* bad merge

* player -> camera in descriptions

* more its

* cadmic review

* goddamn it why do i have that habit

* projected
This commit is contained in:
fig02 2024-12-13 08:12:52 -05:00 committed by GitHub
parent a897017af5
commit 016aef482b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
371 changed files with 1015 additions and 850 deletions

View file

@ -34,9 +34,9 @@ ActorProfile Obj_Mure3_Profile = {
static s16 sRupeeCounts[] = { 5, 5, 7, 0 };
static InitChainEntry sInitChain[] = {
ICHAIN_F32(uncullZoneForward, 100, ICHAIN_CONTINUE),
ICHAIN_F32(uncullZoneScale, 1800, ICHAIN_CONTINUE),
ICHAIN_F32(uncullZoneDownward, 100, ICHAIN_STOP),
ICHAIN_F32(cullingVolumeDistance, 100, ICHAIN_CONTINUE),
ICHAIN_F32(cullingVolumeScale, 1800, ICHAIN_CONTINUE),
ICHAIN_F32(cullingVolumeDownward, 100, ICHAIN_STOP),
};
void func_80B9A9D0(ObjMure3* this, PlayState* play) {
@ -172,7 +172,7 @@ void func_80B9AF64(ObjMure3* this, PlayState* play) {
static ObjMure3SpawnFunc spawnFuncs[] = { func_80B9A9D0, func_80B9AA90, func_80B9ABA0 };
if (Math3D_Dist1DSq(this->actor.projectedPos.x, this->actor.projectedPos.z) < SQ(1150.0f)) {
this->actor.flags |= ACTOR_FLAG_4;
this->actor.flags |= ACTOR_FLAG_UPDATE_CULLING_DISABLED;
spawnFuncs[PARAMS_GET_U(this->actor.params, 13, 3)](this, play);
func_80B9AFEC(this);
}
@ -185,7 +185,7 @@ void func_80B9AFEC(ObjMure3* this) {
void func_80B9AFFC(ObjMure3* this, PlayState* play) {
func_80B9ADCC(this, play);
if (Math3D_Dist1DSq(this->actor.projectedPos.x, this->actor.projectedPos.z) >= SQ(1450.0f)) {
this->actor.flags &= ~ACTOR_FLAG_4;
this->actor.flags &= ~ACTOR_FLAG_UPDATE_CULLING_DISABLED;
func_80B9ACE4(this, play);
func_80B9AF54(this);
}