1
0
Fork 0
mirror of https://github.com/zeldaret/oot.git synced 2025-06-08 17:41:56 +00:00
This commit is contained in:
Dragorn421 2025-06-08 00:27:49 +09:00 committed by GitHub
commit 032586e362
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
9 changed files with 22 additions and 17 deletions

View file

@ -86,9 +86,14 @@ typedef struct ColliderElementDamageInfoAT {
/* 0x05 */ u8 damage; // Damage
} ColliderElementDamageInfoAT; // size = 0x08
typedef enum HitBacklash {
HIT_BACKLASH_0,
HIT_BACKLASH_1 // Shock?
} HitBacklash;
typedef struct ColliderElementDamageInfoAC {
/* 0x00 */ u32 dmgFlags; // Damage types that may affect this collider element as AC.
/* 0x04 */ u8 effect; // Damage Effect (Knockback, Fire, etc.)
/* 0x04 */ u8 hitBacklash; // The backlash type applied to other ATs touching this AC.
/* 0x05 */ u8 defense; // Damage Resistance
/* 0x06 */ Vec3s hitPos; // Point of contact
} ColliderElementDamageInfoAC; // size = 0x0C
@ -465,7 +470,7 @@ typedef struct CollisionCheckInfo {
/* 0x17 */ u8 health; // Note: some actors may use their own health variable instead of this one
/* 0x18 */ u8 damage; // Amount to decrement health by
/* 0x19 */ u8 damageReaction; // Stores what reaction should occur after being hit
/* 0x1A */ u8 atHitEffect; // Stores what effect should occur when AT connects with an AC
/* 0x1A */ u8 atHitBacklash; // Stores the backlash type from touching an AC as an AT
/* 0x1B */ u8 acHitEffect; // Stores what effect should occur when AC is touched by an AT
} CollisionCheckInfo; // size = 0x1C

View file

@ -32,7 +32,7 @@
#include "play_state.h"
#include "vis.h"
#pragma increment_block_number "gc-eu:128 gc-eu-mq:128 gc-jp:128 gc-jp-ce:128 gc-jp-mq:128 gc-us:128 gc-us-mq:128"
#pragma increment_block_number "gc-eu:0 gc-eu-mq:0 gc-jp:0 gc-jp-ce:0 gc-jp-mq:0 gc-us:0 gc-us-mq:0"
SpeedMeter D_801664D0;
VisCvg sVisCvg;

View file

@ -27,7 +27,7 @@
#include "overlays/actors/ovl_En_Horse/z_en_horse.h"
#pragma increment_block_number "gc-eu:128 gc-eu-mq:128 gc-jp:128 gc-jp-ce:128 gc-jp-mq:128 gc-us:128 gc-us-mq:128" \
"ique-cn:128 ntsc-1.0:128 ntsc-1.1:128 ntsc-1.2:128 pal-1.0:128 pal-1.1:128"
"ique-cn:64 ntsc-1.0:128 ntsc-1.1:128 ntsc-1.2:128 pal-1.0:128 pal-1.1:128"
s16 Camera_RequestSettingImpl(Camera* camera, s16 requestedSetting, s16 flags);
s32 Camera_RequestModeImpl(Camera* camera, s16 requestedMode, u8 forceModeChange);
@ -3661,7 +3661,7 @@ s32 Camera_KeepOn3(Camera* camera) {
}
#pragma increment_block_number "gc-eu:128 gc-eu-mq:128 gc-jp:128 gc-jp-ce:128 gc-jp-mq:128 gc-us:128 gc-us-mq:128" \
"ique-cn:128 ntsc-1.0:82 ntsc-1.1:82 ntsc-1.2:82 pal-1.0:82 pal-1.1:82"
"ique-cn:128 ntsc-1.0:79 ntsc-1.1:79 ntsc-1.2:79 pal-1.0:79 pal-1.1:79"
s32 Camera_KeepOn4(Camera* camera) {
static Vec3f D_8015BD50;

View file

@ -17,7 +17,7 @@
#include "z_lib.h"
#pragma increment_block_number "gc-eu:192 gc-eu-mq:192 gc-jp:192 gc-jp-ce:192 gc-jp-mq:192 gc-us:192 gc-us-mq:192" \
"ique-cn:192 ntsc-1.0:168 ntsc-1.1:168 ntsc-1.2:168 pal-1.0:168 pal-1.1:168"
"ique-cn:192 ntsc-1.0:160 ntsc-1.1:160 ntsc-1.2:160 pal-1.0:160 pal-1.1:160"
typedef s32 (*ColChkResetFunc)(PlayState*, Collider*);
typedef void (*ColChkApplyFunc)(PlayState*, CollisionCheckContext*, Collider*);
@ -194,7 +194,7 @@ s32 Collider_DestroyElementDamageInfoAC(PlayState* play, ColliderElementDamageIn
s32 Collider_SetElementDamageInfoAC(PlayState* play, ColliderElementDamageInfoAC* acDmgInfo,
ColliderElementDamageInfoACInit* init) {
acDmgInfo->dmgFlags = init->dmgFlags;
acDmgInfo->effect = init->effect;
acDmgInfo->hitBacklash = init->effect;
acDmgInfo->defense = init->defense;
return true;
}
@ -1739,7 +1739,7 @@ s32 CollisionCheck_SetATvsAC(PlayState* play, Collider* atCol, ColliderElement*
atElem->atHitElem = acElem;
atElem->atElemFlags |= ATELEM_HIT;
if (atCol->actor != NULL) {
atCol->actor->colChkInfo.atHitEffect = acElem->acDmgInfo.effect;
atCol->actor->colChkInfo.atHitBacklash = acElem->acDmgInfo.hitBacklash;
}
}
acCol->acFlags |= AC_HIT;
@ -3028,7 +3028,7 @@ void CollisionCheck_InitInfo(CollisionCheckInfo* info) {
void CollisionCheck_ResetDamage(CollisionCheckInfo* info) {
info->damage = 0;
info->damageReaction = 0;
info->atHitEffect = 0;
info->atHitBacklash = HIT_BACKLASH_0;
info->acHitEffect = 0;
info->displacement.x = info->displacement.y = info->displacement.z = 0.0f;
}

View file

@ -33,7 +33,7 @@
#include "assets/objects/gameplay_keep/gameplay_keep.h"
#pragma increment_block_number "gc-eu:0 gc-eu-mq:0 gc-jp:128 gc-jp-ce:128 gc-jp-mq:128 gc-us:128 gc-us-mq:128" \
"ique-cn:128 pal-1.0:128 pal-1.1:128"
"ique-cn:128 pal-1.0:0 pal-1.1:0"
#define FLAGS \
(ACTOR_FLAG_ATTENTION_ENABLED | ACTOR_FLAG_HOSTILE | ACTOR_FLAG_UPDATE_CULLING_DISABLED | \

View file

@ -157,7 +157,7 @@ void EnBili_Destroy(Actor* thisx, PlayState* play) {
void EnBili_SetupFloatIdle(EnBili* this) {
this->actor.speed = 0.7f;
this->collider.elem.acDmgInfo.effect = 1; // Shock?
this->collider.elem.acDmgInfo.hitBacklash = HIT_BACKLASH_1;
this->timer = 32;
this->actor.home.pos.y = this->actor.world.pos.y;
this->actor.gravity = 0.0f;
@ -253,7 +253,7 @@ void EnBili_SetupDie(EnBili* this) {
*/
void EnBili_SetupStunned(EnBili* this) {
this->timer = 80;
this->collider.elem.acDmgInfo.effect = 0;
this->collider.elem.acDmgInfo.hitBacklash = HIT_BACKLASH_0;
this->actor.gravity = -1.0f;
this->actor.speed = 0.0f;
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 150, COLORFILTER_BUFFLAG_XLU, 80);

View file

@ -272,7 +272,7 @@ void EnVali_SetupStunned(EnVali* this) {
this->timer = 80;
this->actor.velocity.y = 0.0f;
Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_XLU, 80);
this->bodyCollider.elem.acDmgInfo.effect = 0;
this->bodyCollider.elem.acDmgInfo.hitBacklash = HIT_BACKLASH_0;
Actor_PlaySfx(&this->actor, NA_SE_EN_GOMA_JR_FREEZE);
this->actor.velocity.y = 1.0f;
this->actionFunc = EnVali_Stunned;
@ -462,7 +462,7 @@ void EnVali_Stunned(EnVali* this, PlayState* play) {
}
if (this->timer == 0) {
this->bodyCollider.elem.acDmgInfo.effect = 1; // Shock?
this->bodyCollider.elem.acDmgInfo.hitBacklash = HIT_BACKLASH_1;
EnVali_SetupFloatIdle(this);
}
}

View file

@ -1416,7 +1416,7 @@ void func_80B3F3D8(void) {
}
#pragma increment_block_number "gc-eu:64 gc-eu-mq:64 gc-jp:64 gc-jp-ce:64 gc-jp-mq:64 gc-us:64 gc-us-mq:64 ique-cn:64" \
"ntsc-1.0:64 ntsc-1.1:128 ntsc-1.2:128 pal-1.0:128 pal-1.1:128"
"ntsc-1.0:64 ntsc-1.1:64 ntsc-1.2:64 pal-1.0:64 pal-1.1:64"
void EnXc_PlayDiveSFX(Vec3f* src, PlayState* play) {
static Vec3f D_80B42DA0;

View file

@ -377,7 +377,7 @@ static Vec3f sInteractWallCheckResult;
static Input* sControlInput;
#pragma increment_block_number "gc-eu:192 gc-eu-mq:192 gc-jp:192 gc-jp-ce:192 gc-jp-mq:192 gc-us:192 gc-us-mq:192" \
"ique-cn:192 ntsc-1.0:128 ntsc-1.1:128 ntsc-1.2:128 pal-1.0:128 pal-1.1:128"
"ique-cn:160 ntsc-1.0:128 ntsc-1.1:128 ntsc-1.2:128 pal-1.0:128 pal-1.1:128"
// .data
@ -9144,7 +9144,7 @@ s32 func_80842DF4(PlayState* play, Player* this) {
if ((func_80842AC4(play, this) == 0) && (this->heldItemAction != PLAYER_IA_HAMMER)) {
func_80842B7C(play, this);
if (this->actor.colChkInfo.atHitEffect == 1) {
if (this->actor.colChkInfo.atHitBacklash == HIT_BACKLASH_1) {
this->actor.colChkInfo.damage = 8;
func_80837C0C(play, this, PLAYER_HIT_RESPONSE_ELECTRIC_SHOCK, 0.0f, 0.0f, this->actor.shape.rot.y,
20);