True match Enemy50_OnCollision

This commit is contained in:
KEKW555 2023-12-24 11:52:42 +05:30 committed by GitHub
parent c1571218ae
commit 20b4cf6724
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 26 additions and 28 deletions

View File

@ -82,40 +82,38 @@ void Enemy50_OnCollision(Enemy50Entity* this) {
sub_08041134(this); sub_08041134(this);
sub_0803F6EC(this); sub_0803F6EC(this);
} }
if (super->hitType == 0x25) { if (super->hitType == 0x25 && super->contactFlags == 0x80) {
super->action = 8;
InitializeAnimation(super, 3);
} else {
if (super->contactFlags == 0x80) { if (super->contactFlags == 0x80) {
super->action = 8; this->unk_7c = 0x78;
InitializeAnimation(super, 3); sub_08041128(this);
goto _08040C9C;
} }
} else if (super->contactFlags == 0x80) { if (super->contactFlags == 0x9d) {
this->unk_7c = 0x78; super->zVelocity = Q_16_16(1.5);
sub_08041128(this); }
} if (super->confusedTime != 0) {
if (super->contactFlags == 0x9d) {
super->zVelocity = Q_16_16(1.5);
}
if (super->confusedTime != 0) {
super->animationState = super->knockbackDirection >> 4;
InitializeAnimation(super, super->animationState + 7);
Create0x68FX(super, FX_STARS);
}
if (super->health != this->unk_7a) {
if (super->type == 0) {
super->animationState = super->knockbackDirection >> 4; super->animationState = super->knockbackDirection >> 4;
InitializeAnimation(super, super->animationState + 7); InitializeAnimation(super, super->animationState + 7);
} else { Create0x68FX(super, FX_STARS);
if (super->iframes > 0) { }
*((u8*)&super->iframes) |= 0x80; if (super->health != this->unk_7a) {
} if (super->type == 0) {
super->flags |= 0x80; super->animationState = super->knockbackDirection >> 4;
super->health = 0xff; InitializeAnimation(super, super->animationState + 7);
super->action = 0xa; } else {
super->timer = 60; if (super->iframes > 0) {
*((u8*)&super->iframes) |= 0x80;
}
super->flags |= 0x80;
super->health = 0xff;
super->action = 0xa;
super->timer = 60;
}
this->unk_7a = super->health;
} }
this->unk_7a = super->health;
} }
_08040C9C:
EnemyFunctionHandlerAfterCollision(super, Enemy50_Functions); EnemyFunctionHandlerAfterCollision(super, Enemy50_Functions);
} }