mirror of https://github.com/n64decomp/mk64.git
HIT_FAKE_ITEM -> EXPLOSION_CRASH
This commit is contained in:
parent
cd031179c3
commit
b0b218ee3b
|
|
@ -338,32 +338,32 @@ enum PLACE { FIRST_PLACE, SECOND_PLACE, THIRD_PLACE, FOURTH_PLACE };
|
|||
#define HIT_RED_BLUE_MOLE_SOUND_EFFECT 0x2 // hit by a red shell, blue shell, or hit a mole
|
||||
#define HIT_GREEN_SHELL_SOUND_EFFECT 0x4 // hit by a green shell
|
||||
#define DRIVING_SPINOUT_SOUND_EFFECT 0x80 // spinning out from erratic driving
|
||||
#define THWOMP_STOMP_SOUND_EFFECT 0x100 // hitting an object (actually, stomped by thwomp)*
|
||||
#define THWOMP_STOMP_SOUND_EFFECT 0x100 // stomped by thwomp
|
||||
#define BOOST_SOUND_EFFECT 0x200 // being boosted by trigger a mushroom
|
||||
#define BOO_SOUND_EFFECT 0x800 // being a boo
|
||||
#define UNUSED_SOUND_EFFECT_0x1000 0x1000 // Unused
|
||||
#define STAR_SOUND_EFFECT 0x2000 // Starting a star
|
||||
#define LIGHTNING_STRIKE_SOUND_EFFECT 0x4000 // hitting a rotating object (actually struck by lightning)
|
||||
#define LIGHTNING_STRIKE_SOUND_EFFECT 0x4000 // Struck by lightning
|
||||
#define BOOST_RAMP_WOOD_SOUND_EFFECT 0x8000 // being boosted by a ramp
|
||||
#define UNUSED_SOUND_EFFECT_0x20000 0x20000 //* Unused
|
||||
#define DRAG_ITEM_SOUND_EFFECT 0x40000 //* holding a banana (or a banana bunch or a fake item block)// confirmed but ongoing, so not really a sound effect
|
||||
#define HIT_PADDLE_BOAT_SOUND_EFFECT 0x80000 //* hit paddle boat
|
||||
#define UNUSED_SOUND_EFFECT_0x10000 0x100000 //* Unused
|
||||
#define UNUSED_SOUND_EFFECT_0x20000 0x20000 // Unused
|
||||
#define DRAG_ITEM_SOUND_EFFECT 0x40000 // holding a non-shell item behind you
|
||||
#define HIT_PADDLE_BOAT_SOUND_EFFECT 0x80000 // hit paddle boat
|
||||
#define UNUSED_SOUND_EFFECT_0x10000 0x100000 // Unused
|
||||
#define SPINOUT_SOUND_EFFECT 0x200000 // hit crab or spiny spinout or losing versus race
|
||||
#define HIT_FAKE_ITEM_SOUND_EFFECT 0x400000 // actually hitting a fake item / bomb
|
||||
#define BOOST_RAMP_ASPHALT_SOUND_EFFECT 0x800000 // being boosted by a boost pad // confirmed but not every time
|
||||
#define EXPLOSION_CRASH_SOUND_EFFECT 0x400000 // hitting a fake item / bomb / snowman / car / train
|
||||
#define BOOST_RAMP_ASPHALT_SOUND_EFFECT 0x800000 // being boosted by a boost pad
|
||||
#define HIT_BY_STAR_SOUND_EFFECT 0x1000000 // being hit by a star
|
||||
#define START_BOOST_SOUND_EFFECT 0x2000000 //* Start boost sound effect
|
||||
#define LOSE_BATTLE_SOUND_EFFECT 0x4000000 //* When losing battle mode
|
||||
#define BECOME_BOMB_SOUND_EFFECT 0x8000000 //* When becoming a bomb in battle mode
|
||||
#define START_SPINOUT_SOUND_EFFECT 0x10000000 //* Spinning out by holding gas at start of race
|
||||
#define START_BOOST_SOUND_EFFECT 0x2000000 // Start boost sound effect
|
||||
#define LOSE_BATTLE_SOUND_EFFECT 0x4000000 // When losing battle mode
|
||||
#define BECOME_BOMB_SOUND_EFFECT 0x8000000 // When becoming a bomb in battle mode
|
||||
#define START_SPINOUT_SOUND_EFFECT 0x10000000 // Spinning out by holding gas at start of race
|
||||
|
||||
#define ALL_SOUND_EFFECTS (0xFFFFFFFF)
|
||||
#define RACING_SPINOUT_SOUND_EFFECTS (SPINOUT_SOUND_EFFECT | DRIVING_SPINOUT_SOUND_EFFECT | HIT_BANANA_SOUND_EFFECT) // 0x200081
|
||||
#define RAMP_BOOST_SOUND_EFFECTS (BOOST_RAMP_ASPHALT_SOUND_EFFECT | BOOST_RAMP_WOOD_SOUND_EFFECT) // 0x00808000
|
||||
#define ANY_BOOST_SOUND_EFFECTS (RAMP_BOOST_SOUND_EFFECTS | BOOST_SOUND_EFFECT) // 0x00808200
|
||||
#define STATE_TRANSITION_SOUND_EFFECTS (STAR_SOUND_EFFECT | BOO_SOUND_EFFECT | UNUSED_SOUND_EFFECT_0x1000 | UNUSED_SOUND_EFFECT_0x20000)// 0x00023800
|
||||
#define HIT_SOUND_EFFECTS (HIT_BY_STAR_SOUND_EFFECT | HIT_FAKE_ITEM_SOUND_EFFECT | \
|
||||
#define HIT_SOUND_EFFECTS (HIT_BY_STAR_SOUND_EFFECT | EXPLOSION_CRASH_SOUND_EFFECT | \
|
||||
LIGHTNING_STRIKE_SOUND_EFFECT | HIT_GREEN_SHELL_SOUND_EFFECT | HIT_RED_BLUE_MOLE_SOUND_EFFECT | THWOMP_STOMP_SOUND_EFFECT) // 0x01404106
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -1185,7 +1185,7 @@ s32 func_80089B50(s32 objectIndex) {
|
|||
(player->type & PLAYER_EXISTS) && !(player->type & PLAYER_INVISIBLE_OR_BOMB) &&
|
||||
(has_collided_horizontally_with_player(objectIndex, player) != 0)) {
|
||||
if (!(player->effects & STAR_EFFECT)) {
|
||||
player->soundEffects |= HIT_FAKE_ITEM_SOUND_EFFECT;
|
||||
player->soundEffects |= EXPLOSION_CRASH_SOUND_EFFECT;
|
||||
if (is_obj_flag_status_active(objectIndex, 0x04000000) != 0) {
|
||||
func_80072180();
|
||||
}
|
||||
|
|
@ -1212,7 +1212,7 @@ s32 func_80089CBC(s32 objectIndex, f32 arg1) {
|
|||
if ((player->type & PLAYER_EXISTS) && !(player->type & PLAYER_INVISIBLE_OR_BOMB) &&
|
||||
(has_collided_with_player_and_within_height(objectIndex, player, arg1) != 0)) {
|
||||
if (!(player->effects & STAR_EFFECT)) {
|
||||
player->soundEffects |= HIT_FAKE_ITEM_SOUND_EFFECT;
|
||||
player->soundEffects |= EXPLOSION_CRASH_SOUND_EFFECT;
|
||||
if (is_obj_flag_status_active(objectIndex, 0x04000000) != 0) {
|
||||
func_80072180();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1359,7 +1359,7 @@ void play_cpu_sound_effect(s32 arg0, Player* player) {
|
|||
}
|
||||
}
|
||||
if (D_801633B0[arg0] >= 0xB) {
|
||||
if ((player->soundEffects & HIT_FAKE_ITEM_SOUND_EFFECT) || (player->soundEffects & HIT_BY_STAR_SOUND_EFFECT) ||
|
||||
if ((player->soundEffects & EXPLOSION_CRASH_SOUND_EFFECT) || (player->soundEffects & HIT_BY_STAR_SOUND_EFFECT) ||
|
||||
(player->soundEffects & HIT_RED_BLUE_MOLE_SOUND_EFFECT) || (player->soundEffects & HIT_GREEN_SHELL_SOUND_EFFECT) || (player->effects & HIT_EFFECT)) {
|
||||
func_800C92CC(arg0, SOUND_ARG_LOAD(0x29, 0x00, 0x80, 0x0B));
|
||||
D_801633B0[arg0] = 0;
|
||||
|
|
|
|||
|
|
@ -139,7 +139,7 @@ void func_8000DF8C(s32 bombKartId) {
|
|||
if ((((temp_f0 * temp_f0) + (temp_f2 * temp_f2)) + (temp_f12 * temp_f12)) < 25.0f) {
|
||||
var_s1 = 0;
|
||||
sp7E = 4;
|
||||
var_v0->soundEffects |= HIT_FAKE_ITEM_SOUND_EFFECT;
|
||||
var_v0->soundEffects |= EXPLOSION_CRASH_SOUND_EFFECT;
|
||||
var_v0->type &= ~0x2000;
|
||||
}
|
||||
}
|
||||
|
|
@ -157,7 +157,7 @@ void func_8000DF8C(s32 bombKartId) {
|
|||
if (gCurrentCourseId == COURSE_FRAPPE_SNOWLAND) {
|
||||
var_v0->soundEffects |= HIT_BY_STAR_SOUND_EFFECT;
|
||||
} else {
|
||||
var_v0->soundEffects |= HIT_FAKE_ITEM_SOUND_EFFECT;
|
||||
var_v0->soundEffects |= EXPLOSION_CRASH_SOUND_EFFECT;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -134,7 +134,7 @@ void regulate_cpu_speed(s32 playerId, f32 targetSpeed, Player* player) {
|
|||
|
||||
speed = player->speed;
|
||||
if (!(player->effects & 0x80) && !(player->effects & 0x40) && !(player->effects & 0x20000) &&
|
||||
!(player->soundEffects & HIT_FAKE_ITEM_SOUND_EFFECT) && !(player->soundEffects & HIT_BY_STAR_SOUND_EFFECT) && !(player->soundEffects & HIT_RED_BLUE_MOLE_SOUND_EFFECT) &&
|
||||
!(player->soundEffects & EXPLOSION_CRASH_SOUND_EFFECT) && !(player->soundEffects & HIT_BY_STAR_SOUND_EFFECT) && !(player->soundEffects & HIT_RED_BLUE_MOLE_SOUND_EFFECT) &&
|
||||
!(player->soundEffects & 4)) {
|
||||
if (gCurrentCourseId == COURSE_AWARD_CEREMONY) {
|
||||
func_80007FA4(playerId, player, speed);
|
||||
|
|
|
|||
|
|
@ -372,14 +372,14 @@ void handle_trains_interactions(s32 playerId, Player* player) {
|
|||
if ((z_dist > -100.0) && (z_dist < 100.0)) {
|
||||
if (is_collide_with_vehicle(trainCar->position[0], trainCar->position[2], trainCar->velocity[0],
|
||||
trainCar->velocity[2], 60.0f, 20.0f, playerPosX, playerPosZ) == 1) {
|
||||
player->soundEffects |= HIT_FAKE_ITEM_SOUND_EFFECT;
|
||||
player->soundEffects |= EXPLOSION_CRASH_SOUND_EFFECT;
|
||||
}
|
||||
trainCar = &gTrainList[trainIndex].tender;
|
||||
if (trainCar->isActive == 1) {
|
||||
if (is_collide_with_vehicle(trainCar->position[0], trainCar->position[2],
|
||||
trainCar->velocity[0], trainCar->velocity[2], 30.0f, 20.0f,
|
||||
playerPosX, playerPosZ) == 1) {
|
||||
player->soundEffects |= HIT_FAKE_ITEM_SOUND_EFFECT;
|
||||
player->soundEffects |= EXPLOSION_CRASH_SOUND_EFFECT;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -395,7 +395,7 @@ void handle_trains_interactions(s32 playerId, Player* player) {
|
|||
if (is_collide_with_vehicle(trainCar->position[0], trainCar->position[2],
|
||||
trainCar->velocity[0], trainCar->velocity[2], 30.0f, 20.0f,
|
||||
playerPosX, playerPosZ) == 1) {
|
||||
player->soundEffects |= HIT_FAKE_ITEM_SOUND_EFFECT;
|
||||
player->soundEffects |= EXPLOSION_CRASH_SOUND_EFFECT;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -805,7 +805,7 @@ void handle_vehicle_interactions(s32 playerId, Player* player, VehicleStuff* veh
|
|||
if (is_collide_with_vehicle(vehicle->position[0], vehicle->position[2], vehicle->velocity[0],
|
||||
vehicle->velocity[2], distanceX, distanceY, playerX,
|
||||
playerZ) == (s32) 1) {
|
||||
player->soundEffects |= HIT_FAKE_ITEM_SOUND_EFFECT;
|
||||
player->soundEffects |= EXPLOSION_CRASH_SOUND_EFFECT;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -311,7 +311,7 @@ void func_8008C8C4(Player* player, s8 playerId) {
|
|||
}
|
||||
if ((gModeSelection == VERSUS) && ((player->type & PLAYER_CPU) == PLAYER_CPU) && (!gDemoMode) &&
|
||||
((player->unk_0CA & 2) == 0) && (gGPCurrentRaceRankByPlayerId[playerId] != 0)) {
|
||||
player->soundEffects = (s32) (player->soundEffects | HIT_FAKE_ITEM_SOUND_EFFECT);
|
||||
player->soundEffects = (s32) (player->soundEffects | EXPLOSION_CRASH_SOUND_EFFECT);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -1025,7 +1025,7 @@ void apply_reverse_sound_effect(Player* player, s8 playerIndex) {
|
|||
play_cpu_sound_effect(playerIndex, player);
|
||||
}
|
||||
|
||||
player->soundEffects &= ~(HIT_FAKE_ITEM_SOUND_EFFECT | HIT_PADDLE_BOAT_SOUND_EFFECT);
|
||||
player->soundEffects &= ~(EXPLOSION_CRASH_SOUND_EFFECT | HIT_PADDLE_BOAT_SOUND_EFFECT);
|
||||
player->unk_0B6 |= 0x40;
|
||||
gTimerBoostTripleACombo[playerIndex] = 0;
|
||||
gIsPlayerTripleAButtonCombo[playerIndex] = false;
|
||||
|
|
|
|||
|
|
@ -1384,7 +1384,7 @@ void apply_sound_effect(Player* player, s8 playerId, UNUSED s8 screenId) {
|
|||
if ((player->soundEffects & SPINOUT_SOUND_EFFECT) == SPINOUT_SOUND_EFFECT) {
|
||||
func_8008C73C(player, playerId);
|
||||
}
|
||||
if ((player->soundEffects & HIT_FAKE_ITEM_SOUND_EFFECT) == HIT_FAKE_ITEM_SOUND_EFFECT) {
|
||||
if ((player->soundEffects & EXPLOSION_CRASH_SOUND_EFFECT) == EXPLOSION_CRASH_SOUND_EFFECT) {
|
||||
apply_reverse_sound_effect(player, playerId);
|
||||
}
|
||||
if ((player->soundEffects & HIT_BY_STAR_SOUND_EFFECT) == HIT_BY_STAR_SOUND_EFFECT) {
|
||||
|
|
|
|||
|
|
@ -2220,7 +2220,7 @@ void evaluate_collision_between_player_actor(Player* player, struct Actor* actor
|
|||
(query_collision_player_vs_actor_item(player, actor) != COLLISION)) {
|
||||
break;
|
||||
}
|
||||
player->soundEffects |= HIT_FAKE_ITEM_SOUND_EFFECT;
|
||||
player->soundEffects |= EXPLOSION_CRASH_SOUND_EFFECT;
|
||||
owner = &gPlayers[temp_v1];
|
||||
if (owner->type & 0x4000) {
|
||||
if (actor->flags & 0xF) {
|
||||
|
|
|
|||
|
|
@ -1138,12 +1138,12 @@ void func_802903D8(Player* playerOne, Player* playerTwo) {
|
|||
func_800C9060((playerTwo - gPlayerOne), 0x19008001U);
|
||||
return;
|
||||
} else {
|
||||
playerTwo->soundEffects |= HIT_FAKE_ITEM_SOUND_EFFECT;
|
||||
playerTwo->soundEffects |= EXPLOSION_CRASH_SOUND_EFFECT;
|
||||
func_8008FC1C(playerOne);
|
||||
func_800C9060((playerTwo - gPlayerOne), 0x19008001U);
|
||||
}
|
||||
} else if (playerTwo->type & PLAYER_UNKNOWN_0x40) {
|
||||
playerOne->soundEffects |= HIT_FAKE_ITEM_SOUND_EFFECT;
|
||||
playerOne->soundEffects |= EXPLOSION_CRASH_SOUND_EFFECT;
|
||||
func_8008FC1C(playerTwo);
|
||||
func_800C9060(playerOne - gPlayerOne, 0x19008001U);
|
||||
return;
|
||||
|
|
|
|||
Loading…
Reference in New Issue