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

Actor Struct Changes (and a few related things) (#617)

* reformat header

* type -> category

* done for now i think

* some more stuff

* first -> head

* focus

* flag comment

* ground -> floor

* remove asm, name wrapper funcs

* name func, format

* review

* targetPriority, format

* git subrepo pull --force tools/ZAPD

subrepo:
  subdir:   "tools/ZAPD"
  merged:   "0305ec2c2"
upstream:
  origin:   "https://github.com/zeldaret/ZAPD.git"
  branch:   "master"
  commit:   "0305ec2c2"
git-subrepo:
  version:  "0.4.3"
  origin:   "https://github.com/ingydotnet/git-subrepo.git"
  commit:   "2f68596"

* comment

* review

* feet flags

* horse shadow
This commit is contained in:
fig02 2021-01-18 16:04:04 -05:00 committed by GitHub
parent 20206fba0d
commit 00a5edea71
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
697 changed files with 8157 additions and 7942 deletions

View file

@ -20,7 +20,7 @@ extern Gfx D_0404D4E0[];
const ActorInit Obj_Syokudai_InitVars = {
ACTOR_OBJ_SYOKUDAI,
ACTORTYPE_PROP,
ACTORCAT_PROP,
FLAGS,
OBJECT_SYOKUDAI,
sizeof(ObjSyokudai),
@ -97,8 +97,8 @@ void ObjSyokudai_Init(Actor* thisx, GlobalContext* globalCtx) {
this->actor.colChkInfo.mass = MASS_IMMOVABLE;
Lights_PointGlowSetInfo(&this->lightInfo, this->actor.posRot.pos.x, this->actor.posRot.pos.y + 70.0f,
this->actor.posRot.pos.z, 255, 255, 180, -1);
Lights_PointGlowSetInfo(&this->lightInfo, this->actor.world.pos.x, this->actor.world.pos.y + 70.0f,
this->actor.world.pos.z, 255, 255, 180, -1);
this->lightNode = LightContext_InsertLight(globalCtx, &globalCtx->lightCtx, &this->lightInfo);
if ((this->actor.params & 0x400) || ((torchType != 2) && Flags_GetSwitch(globalCtx, this->actor.params & 0x3F))) {
@ -107,7 +107,7 @@ void ObjSyokudai_Init(Actor* thisx, GlobalContext* globalCtx) {
this->flameTexScroll = (s32)(Rand_ZeroOne() * 20.0f);
sLitTorchCount = 0;
Actor_SetHeight(&this->actor, 60.0f);
Actor_SetFocus(&this->actor, 60.0f);
}
void ObjSyokudai_Destroy(Actor* thisx, GlobalContext* globalCtx) {
@ -142,9 +142,9 @@ void ObjSyokudai_Update(Actor* thisx, GlobalContext* globalCtx2) {
if (torchCount == 10) {
torchCount = 24;
}
if (WaterBox_GetSurfaceImpl(globalCtx, &globalCtx->colCtx, this->actor.posRot.pos.x, this->actor.posRot.pos.z,
if (WaterBox_GetSurfaceImpl(globalCtx, &globalCtx->colCtx, this->actor.world.pos.x, this->actor.world.pos.z,
&waterSurface, &dummy) &&
((waterSurface - this->actor.posRot.pos.y) > 52.0f)) {
((waterSurface - this->actor.world.pos.y) > 52.0f)) {
this->litTimer = 0;
if (torchType == 1) {
Flags_UnsetSwitch(globalCtx, switchFlag);
@ -178,7 +178,7 @@ void ObjSyokudai_Update(Actor* thisx, GlobalContext* globalCtx2) {
interactionType = 1;
}
} else if (player->heldItemActionParam == 6) {
Math_Vec3f_Diff(&player->swordInfo[0].tip, &this->actor.posRot.pos, &tipToFlame);
Math_Vec3f_Diff(&player->swordInfo[0].tip, &this->actor.world.pos, &tipToFlame);
tipToFlame.y -= 67.0f;
if ((SQ(tipToFlame.x) + SQ(tipToFlame.y) + SQ(tipToFlame.z)) < SQ(20.0f)) {
interactionType = -1;