mirror of
https://github.com/izzy2lost/Ghostship.git
synced 2026-06-19 01:17:03 -07:00
[WIP] Added jpn support
This commit is contained in:
+8
-41
@@ -48,9 +48,7 @@ ALIGNED8 static const Texture texture_hud_char_H[] = "__OTR__textures/segment2/s
|
||||
|
||||
ALIGNED8 static const Texture texture_hud_char_I[] = "__OTR__textures/segment2/segment2.02400";
|
||||
|
||||
#if defined(VERSION_JP) || defined(VERSION_SH)
|
||||
ALIGNED8 static const Texture texture_hud_char_J[] = "__OTR__textures/segment2/segment2.02600";
|
||||
#endif
|
||||
|
||||
ALIGNED8 static const Texture texture_hud_char_K[] = "__OTR__textures/segment2/segment2.02800";
|
||||
|
||||
@@ -64,9 +62,7 @@ ALIGNED8 static const Texture texture_hud_char_O[] = "__OTR__textures/segment2/s
|
||||
|
||||
ALIGNED8 static const Texture texture_hud_char_P[] = "__OTR__textures/segment2/segment2.03200";
|
||||
|
||||
#if defined(VERSION_JP) || defined(VERSION_SH)
|
||||
ALIGNED8 static const Texture texture_hud_char_Q[] = "__OTR__textures/segment2/segment2.03400";
|
||||
#endif
|
||||
|
||||
ALIGNED8 static const Texture texture_hud_char_R[] = "__OTR__textures/segment2/segment2.03600";
|
||||
|
||||
@@ -76,21 +72,15 @@ ALIGNED8 static const Texture texture_hud_char_T[] = "__OTR__textures/segment2/s
|
||||
|
||||
ALIGNED8 static const Texture texture_hud_char_U[] = "__OTR__textures/segment2/segment2.03C00";
|
||||
|
||||
#if defined(VERSION_JP) || defined(VERSION_EU) || defined(VERSION_SH)
|
||||
ALIGNED8 static const Texture texture_hud_char_V[] = "__OTR__textures/segment2/segment2.03E00";
|
||||
#endif
|
||||
|
||||
ALIGNED8 static const Texture texture_hud_char_W[] = "__OTR__textures/segment2/segment2.04000";
|
||||
|
||||
#if defined(VERSION_JP) || defined(VERSION_SH)
|
||||
ALIGNED8 static const Texture texture_hud_char_X[] = "__OTR__textures/segment2/segment2.04200";
|
||||
#endif
|
||||
|
||||
ALIGNED8 static const Texture texture_hud_char_Y[] = "__OTR__textures/segment2/segment2.04400";
|
||||
|
||||
#if defined(VERSION_JP) || defined(VERSION_EU) || defined(VERSION_SH)
|
||||
ALIGNED8 static const Texture texture_hud_char_Z[] = "__OTR__textures/segment2/segment2.04600";
|
||||
#endif
|
||||
|
||||
ALIGNED8 static const Texture texture_hud_char_apostrophe[] = "__OTR__textures/segment2/segment2.04800";
|
||||
|
||||
@@ -100,17 +90,15 @@ ALIGNED8 static const Texture texture_hud_char_double_quote[] = "__OTR__textures
|
||||
ALIGNED8 static const Texture texture_hud_char_umlaut[] = "__OTR__textures/segment2/segment2.umlaut"// EU ¨;
|
||||
#endif
|
||||
|
||||
#if defined(VERSION_JP) || defined(VERSION_SH)
|
||||
ALIGNED8 static const Texture texture_hud_char_exclamation[] = "__OTR__textures/segment2/segment2.04C00"// JP !;
|
||||
ALIGNED8 static const Texture texture_hud_char_exclamation[] = "__OTR__textures/segment2/segment2.04C00";
|
||||
|
||||
ALIGNED8 static const Texture texture_hud_char_double_exclamation[] = "__OTR__textures/segment2/segment2.04E00"// JP !!;
|
||||
ALIGNED8 static const Texture texture_hud_char_double_exclamation[] = "__OTR__textures/segment2/segment2.04E00";
|
||||
|
||||
ALIGNED8 static const Texture texture_hud_char_question[] = "__OTR__textures/segment2/segment2.05000"// JP ?;
|
||||
ALIGNED8 static const Texture texture_hud_char_question[] = "__OTR__textures/segment2/segment2.05000";
|
||||
|
||||
ALIGNED8 static const Texture texture_hud_char_ampersand[] = "__OTR__textures/segment2/segment2.05200"// JP &;
|
||||
ALIGNED8 static const Texture texture_hud_char_ampersand[] = "__OTR__textures/segment2/segment2.05200";
|
||||
|
||||
ALIGNED8 static const Texture texture_hud_char_percent[] = "__OTR__textures/segment2/segment2.05400"// JP %;
|
||||
#endif
|
||||
ALIGNED8 static const Texture texture_hud_char_percent[] = "__OTR__textures/segment2/segment2.05400";
|
||||
|
||||
ALIGNED8 static const Texture texture_hud_char_multiply[] = "__OTR__textures/segment2/segment2.05600";
|
||||
|
||||
@@ -120,13 +108,9 @@ ALIGNED8 static const Texture texture_hud_char_mario_head[] = "__OTR__textures/s
|
||||
|
||||
ALIGNED8 static const Texture texture_hud_char_star[] = "__OTR__textures/segment2/segment2.05C00";
|
||||
|
||||
#if defined(VERSION_JP) || defined(VERSION_SH)
|
||||
ALIGNED8 static const Texture texture_hud_char_decimal_point[] = "__OTR__textures/segment2/segment2.05E00";
|
||||
#endif
|
||||
|
||||
#if defined(VERSION_JP) || defined(VERSION_SH)
|
||||
ALIGNED8 static const Texture texture_hud_char_beta_key[] = "__OTR__textures/segment2/segment2.06000";
|
||||
#endif
|
||||
|
||||
ALIGNED8 static const Texture texture_credits_char_3[] = "__OTR__textures/segment2/segment2.06200";
|
||||
|
||||
@@ -189,7 +173,6 @@ ALIGNED8 static const Texture texture_credits_char_Z[] = "__OTR__textures/segmen
|
||||
ALIGNED8 static const Texture texture_credits_char_period[] = "__OTR__textures/segment2/segment2.07080";
|
||||
|
||||
// JP Small Font
|
||||
#if defined(VERSION_JP) || defined(VERSION_SH)
|
||||
ALIGNED8 static const Texture texture_font_char_jp_0[] = "__OTR__textures/segment2/segment2.07100";
|
||||
|
||||
ALIGNED8 static const Texture texture_font_char_jp_1[] = "__OTR__textures/segment2/segment2.07110";
|
||||
@@ -521,7 +504,7 @@ ALIGNED8 static const Texture texture_font_char_jp_wave_dash[] = "__OTR__texture
|
||||
ALIGNED8 static const Texture texture_font_char_jp_ellipsis[] = "__OTR__textures/segment2/segment2.07B40";
|
||||
|
||||
// EU Small Font
|
||||
#elif defined(VERSION_EU)
|
||||
#if defined(VERSION_EU)
|
||||
|
||||
ALIGNED8 static const Texture texture_font_char_eu_0[] = "__OTR__textures/segment2/font_graphics.05F00";
|
||||
|
||||
@@ -724,7 +707,8 @@ ALIGNED8 static const Texture texture_font_char_eu_Cedilla[] = "__OTR__textures/
|
||||
ALIGNED8 static const Texture texture_font_char_eu_eszeet[] = "__OTR__textures/segment2/font_graphics.06530";
|
||||
|
||||
// US Small Font
|
||||
#else
|
||||
#endif
|
||||
|
||||
ALIGNED8 static const Texture texture_font_char_us_0[] = "__OTR__textures/segment2/font_graphics.05900";
|
||||
|
||||
ALIGNED8 static const Texture texture_font_char_us_1[] = "__OTR__textures/segment2/font_graphics.05940";
|
||||
@@ -908,7 +892,6 @@ ALIGNED8 static const Texture texture_font_char_us_button_C_down[] = "__OTR__tex
|
||||
ALIGNED8 static const Texture texture_font_char_us_button_C_left[] = "__OTR__textures/segment2/font_graphics.06F80";
|
||||
|
||||
ALIGNED8 static const Texture texture_font_char_us_button_C_right[] = "__OTR__textures/segment2/font_graphics.06FC0";
|
||||
#endif
|
||||
|
||||
ALIGNED8 static const Texture texture_hud_char_camera[] = "__OTR__textures/segment2/segment2.07B50";
|
||||
|
||||
@@ -938,22 +921,6 @@ const Texture *const main_hud_lut[] = {
|
||||
0x0, 0x0, texture_hud_char_multiply, texture_hud_char_coin,
|
||||
texture_hud_char_mario_head, texture_hud_char_star, 0x0, 0x0,
|
||||
texture_hud_char_apostrophe, texture_hud_char_double_quote, texture_hud_char_umlaut,
|
||||
#elif defined(VERSION_US)
|
||||
texture_hud_char_0, texture_hud_char_1, texture_hud_char_2, texture_hud_char_3,
|
||||
texture_hud_char_4, texture_hud_char_5, texture_hud_char_6, texture_hud_char_7,
|
||||
texture_hud_char_8, texture_hud_char_9, texture_hud_char_A, texture_hud_char_B,
|
||||
texture_hud_char_C, texture_hud_char_D, texture_hud_char_E, texture_hud_char_F,
|
||||
texture_hud_char_G, texture_hud_char_H, texture_hud_char_I, 0x0,
|
||||
texture_hud_char_K, texture_hud_char_L, texture_hud_char_M, texture_hud_char_N,
|
||||
texture_hud_char_O, texture_hud_char_P, 0x0, texture_hud_char_R,
|
||||
texture_hud_char_S, texture_hud_char_T, texture_hud_char_U, 0x0,
|
||||
texture_hud_char_W, 0x0, texture_hud_char_Y, 0x0,
|
||||
0x0, 0x0, 0x0, 0x0,
|
||||
0x0, 0x0, 0x0, 0x0,
|
||||
0x0, 0x0, 0x0, 0x0,
|
||||
0x0, 0x0, texture_hud_char_multiply, texture_hud_char_coin,
|
||||
texture_hud_char_mario_head, texture_hud_char_star, 0x0, 0x0,
|
||||
texture_hud_char_apostrophe, texture_hud_char_double_quote,
|
||||
#else
|
||||
texture_hud_char_0, texture_hud_char_1, texture_hud_char_2, texture_hud_char_3,
|
||||
texture_hud_char_4, texture_hud_char_5, texture_hud_char_6, texture_hud_char_7,
|
||||
|
||||
@@ -17,6 +17,10 @@
|
||||
#include <PR/ucode.h>
|
||||
#include <libultra/os.h>
|
||||
#include <math.h>
|
||||
#include "port/Engine.h"
|
||||
|
||||
#define GAME_VERSION GameEngine_GetGameVersion()
|
||||
#define ROM_JP (GAME_VERSION == 0xE3DAA4E)
|
||||
|
||||
#ifdef _WIN32
|
||||
#define bzero(b,len) (memset((b), '\0', (len)), (void) 0)
|
||||
|
||||
+1
-1
Submodule libultraship updated: 69b7b61602...8ba2cdddb2
+3
-3
@@ -139,9 +139,9 @@ extern OSMesgQueue *D_SH_80350FA8;
|
||||
#define AUDIO_HEAP_SIZE 0x2c500
|
||||
#define AUDIO_INIT_POOL_SIZE 0x2c00
|
||||
#else
|
||||
#define UNUSED_COUNT_80333EE8 16
|
||||
#define AUDIO_HEAP_SIZE 0x31150
|
||||
#define AUDIO_INIT_POOL_SIZE 0x2500
|
||||
#define UNUSED_COUNT_80333EE8 24
|
||||
#define AUDIO_HEAP_SIZE 0x41150
|
||||
#define AUDIO_INIT_POOL_SIZE 0x3500
|
||||
#endif
|
||||
|
||||
#ifdef VERSION_SH
|
||||
|
||||
@@ -96,12 +96,10 @@ static void camera_lakitu_intro_act_show_dialog(void) {
|
||||
|
||||
approach_f32_ptr(&o->oCameraLakituCircleRadius, 200.0f, 50.0f);
|
||||
if (o->oDistanceToMario < 1000.0f) {
|
||||
#ifndef VERSION_JP
|
||||
if (!o->oCameraLakituUnk104) {
|
||||
if (!ROM_JP && !o->oCameraLakituUnk104) {
|
||||
play_music(SEQ_PLAYER_LEVEL, SEQUENCE_ARGS(15, SEQ_EVENT_CUTSCENE_LAKITU), 0);
|
||||
o->oCameraLakituUnk104 = TRUE;
|
||||
}
|
||||
#endif
|
||||
// Once within 1000 units, slow down
|
||||
approach_f32_ptr(&o->oCameraLakituSpeed, 20.0f, 1.0f);
|
||||
if (o->oDistanceToMario < 500.0f
|
||||
|
||||
@@ -56,21 +56,20 @@ void bhv_red_coin_loop(void) {
|
||||
// ...increment the star's counter.
|
||||
o->parentObj->oHiddenStarTriggerCounter++;
|
||||
|
||||
// For JP version, play an identical sound for all coins.
|
||||
#ifdef VERSION_JP
|
||||
create_sound_spawner(SOUND_GENERAL_RED_COIN);
|
||||
#endif
|
||||
// Spawn the orange number counter, as long as it isn't the last coin.
|
||||
if (o->parentObj->oHiddenStarTriggerCounter != 8) {
|
||||
spawn_orange_number(o->parentObj->oHiddenStarTriggerCounter, 0, 0, 0);
|
||||
}
|
||||
|
||||
// On all versions but the JP version, each coin collected plays a higher noise.
|
||||
#ifndef VERSION_JP
|
||||
play_sound(SOUND_MENU_COLLECT_RED_COIN
|
||||
if(ROM_JP){
|
||||
// For JP version, play an identical sound for all coins.
|
||||
create_sound_spawner(SOUND_GENERAL_RED_COIN);
|
||||
} else {
|
||||
// On all versions but the JP version, each coin collected plays a higher noise.
|
||||
play_sound(SOUND_MENU_COLLECT_RED_COIN
|
||||
+ (((u8) o->parentObj->oHiddenStarTriggerCounter - 1) << 16),
|
||||
gGlobalSoundSource);
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
coin_collected();
|
||||
|
||||
@@ -60,13 +60,7 @@ void water_ring_check_collection(f32 avgScale, struct Object *ringManager) {
|
||||
ringSpawner->oWaterRingSpawnerRingsCollected++;
|
||||
if (ringSpawner->oWaterRingSpawnerRingsCollected < 6) {
|
||||
spawn_orange_number(ringSpawner->oWaterRingSpawnerRingsCollected, 0, -40, 0);
|
||||
#ifdef VERSION_JP
|
||||
play_sound(SOUND_MENU_STAR_SOUND, gGlobalSoundSource);
|
||||
#else
|
||||
play_sound(SOUND_MENU_COLLECT_SECRET
|
||||
+ (((u8) ringSpawner->oWaterRingSpawnerRingsCollected - 1) << 16),
|
||||
gGlobalSoundSource);
|
||||
#endif
|
||||
play_sound(ROM_JP ? SOUND_MENU_STAR_SOUND : SOUND_MENU_COLLECT_SECRET + (((u8) ringSpawner->oWaterRingSpawnerRingsCollected - 1) << 16), gGlobalSoundSource);
|
||||
}
|
||||
ringManager->oWaterRingMgrLastRingCollected = o->oWaterRingIndex;
|
||||
} else {
|
||||
|
||||
+10
-12
@@ -4941,9 +4941,8 @@ s32 radial_camera_input(struct Camera *c, UNUSED f32 unused) {
|
||||
if (gPlayer1Controller->buttonPressed & D_CBUTTONS) {
|
||||
if (gCameraMovementFlags & CAM_MOVE_ZOOMED_OUT) {
|
||||
gCameraMovementFlags |= CAM_MOVE_ALREADY_ZOOMED_OUT;
|
||||
#ifndef VERSION_JP
|
||||
if(ROM_JP) return;
|
||||
play_camera_buzz_if_cdown();
|
||||
#endif
|
||||
} else {
|
||||
gCameraMovementFlags |= CAM_MOVE_ZOOMED_OUT;
|
||||
play_sound_cbutton_down();
|
||||
@@ -4995,9 +4994,8 @@ void handle_c_button_movement(struct Camera *c) {
|
||||
if (gCameraMovementFlags & CAM_MOVE_ZOOMED_OUT) {
|
||||
gCameraMovementFlags |= CAM_MOVE_ALREADY_ZOOMED_OUT;
|
||||
sZoomAmount = gCameraZoomDist + 400.f;
|
||||
#ifndef VERSION_JP
|
||||
if(ROM_JP) return;
|
||||
play_camera_buzz_if_cdown();
|
||||
#endif
|
||||
} else {
|
||||
gCameraMovementFlags |= CAM_MOVE_ZOOMED_OUT;
|
||||
sZoomAmount = gCameraZoomDist + 400.f;
|
||||
@@ -9515,11 +9513,11 @@ BAD_RETURN(s32) peach_letter_text(UNUSED struct Camera *c) {
|
||||
create_dialog_box(DIALOG_020);
|
||||
}
|
||||
|
||||
#ifndef VERSION_JP
|
||||
BAD_RETURN(s32) play_sound_peach_reading_letter(UNUSED struct Camera *c) {
|
||||
play_sound(SOUND_PEACH_DEAR_MARIO, gGlobalSoundSource);
|
||||
if(!ROM_JP){
|
||||
play_sound(SOUND_PEACH_DEAR_MARIO, gGlobalSoundSource);
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
/**
|
||||
* Move the camera from peach reading the letter all the way to Mario's warp pipe. Follow the
|
||||
@@ -9585,11 +9583,10 @@ BAD_RETURN(s32) intro_pipe_exit_text(UNUSED struct Camera *c) {
|
||||
create_dialog_box(DIALOG_033);
|
||||
}
|
||||
|
||||
#ifndef VERSION_JP
|
||||
BAD_RETURN(s32) play_sound_intro_turn_on_hud(UNUSED struct Camera *c) {
|
||||
if(ROM_JP) return;
|
||||
play_sound_rbutton_changed();
|
||||
}
|
||||
#endif
|
||||
|
||||
/**
|
||||
* Fly to the pipe. Near the end, the camera jumps to Lakitu's position and the hud turns on.
|
||||
@@ -9654,9 +9651,10 @@ BAD_RETURN(s32) cutscene_intro_peach_letter(struct Camera *c) {
|
||||
#endif
|
||||
cutscene_event(cutscene_intro_peach_start_to_pipe_spline, c, 0, 0);
|
||||
cutscene_event(peach_letter_text, c, 65, 65);
|
||||
#ifndef VERSION_JP
|
||||
cutscene_event(play_sound_peach_reading_letter, c, 83, 83);
|
||||
#endif
|
||||
|
||||
if(!ROM_JP){
|
||||
cutscene_event(play_sound_peach_reading_letter, c, 83, 83);
|
||||
}
|
||||
|
||||
if ((gCutsceneTimer > 120) && (get_dialog_id() == DIALOG_NONE)) {
|
||||
// Start the next scene
|
||||
|
||||
@@ -1345,9 +1345,9 @@ u32 interact_hit_from_below(struct MarioState *m, UNUSED u32 interactType, struc
|
||||
if (o->oInteractionSubtype & INT_SUBTYPE_TWIRL_BOUNCE) {
|
||||
bounce_off_object(m, o, 80.0f);
|
||||
reset_mario_pitch(m);
|
||||
#ifndef VERSION_JP
|
||||
play_sound(SOUND_MARIO_TWIRL_BOUNCE, m->marioObj->header.gfx.cameraToObject);
|
||||
#endif
|
||||
if(!ROM_JP){
|
||||
play_sound(SOUND_MARIO_TWIRL_BOUNCE, m->marioObj->header.gfx.cameraToObject);
|
||||
}
|
||||
return drop_and_set_mario_action(m, ACT_TWIRLING, 0);
|
||||
} else {
|
||||
bounce_off_object(m, o, 30.0f);
|
||||
@@ -1383,9 +1383,9 @@ u32 interact_bounce_top(struct MarioState *m, UNUSED u32 interactType, struct Ob
|
||||
if (o->oInteractionSubtype & INT_SUBTYPE_TWIRL_BOUNCE) {
|
||||
bounce_off_object(m, o, 80.0f);
|
||||
reset_mario_pitch(m);
|
||||
#ifndef VERSION_JP
|
||||
play_sound(SOUND_MARIO_TWIRL_BOUNCE, m->marioObj->header.gfx.cameraToObject);
|
||||
#endif
|
||||
if(!ROM_JP){
|
||||
play_sound(SOUND_MARIO_TWIRL_BOUNCE, m->marioObj->header.gfx.cameraToObject);
|
||||
}
|
||||
return drop_and_set_mario_action(m, ACT_TWIRLING, 0);
|
||||
} else {
|
||||
bounce_off_object(m, o, 30.0f);
|
||||
|
||||
@@ -455,13 +455,11 @@ void init_mario_after_warp(void) {
|
||||
play_sound(SOUND_MENU_MARIO_CASTLE_WARP, gGlobalSoundSource);
|
||||
}
|
||||
|
||||
#ifndef VERSION_JP
|
||||
if (sWarpDest.levelNum == LEVEL_CASTLE_GROUNDS && sWarpDest.areaIdx == 1
|
||||
if (!ROM_JP && sWarpDest.levelNum == LEVEL_CASTLE_GROUNDS && sWarpDest.areaIdx == 1
|
||||
&& (sWarpDest.nodeId == 7 || sWarpDest.nodeId == 10 || sWarpDest.nodeId == 20
|
||||
|| sWarpDest.nodeId == 30)) {
|
||||
play_sound(SOUND_MENU_MARIO_CASTLE_WARP, gGlobalSoundSource);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
@@ -761,9 +759,9 @@ s16 level_trigger_warp(struct MarioState *m, s32 warpOp) {
|
||||
sDelayedWarpTimer = 30;
|
||||
sSourceWarpNodeId = WARP_NODE_F2;
|
||||
play_transition(WARP_TRANSITION_FADE_INTO_COLOR, 0x1E, 0xFF, 0xFF, 0xFF);
|
||||
#ifndef VERSION_JP
|
||||
play_sound(SOUND_MENU_STAR_SOUND, gGlobalSoundSource);
|
||||
#endif
|
||||
if(!ROM_JP){
|
||||
play_sound(SOUND_MENU_STAR_SOUND, gGlobalSoundSource);
|
||||
}
|
||||
break;
|
||||
|
||||
case WARP_OP_UNKNOWN_02: // bbh enter
|
||||
|
||||
+7
-11
@@ -248,17 +248,13 @@ void play_sound_if_no_flag(struct MarioState *m, u32 soundBits, u32 flags) {
|
||||
*/
|
||||
void play_mario_jump_sound(struct MarioState *m) {
|
||||
if (!(m->flags & MARIO_MARIO_SOUND_PLAYED)) {
|
||||
#ifndef VERSION_JP
|
||||
if (m->action == ACT_TRIPLE_JUMP) {
|
||||
if (!ROM_JP && m->action == ACT_TRIPLE_JUMP) {
|
||||
play_sound(SOUND_MARIO_YAHOO_WAHA_YIPPEE + ((gAudioRandom % 5) << 16),
|
||||
m->marioObj->header.gfx.cameraToObject);
|
||||
} else {
|
||||
#endif
|
||||
play_sound(SOUND_MARIO_YAH_WAH_HOO + ((gAudioRandom % 3) << 16),
|
||||
m->marioObj->header.gfx.cameraToObject);
|
||||
#ifndef VERSION_JP
|
||||
}
|
||||
#endif
|
||||
m->flags |= MARIO_MARIO_SOUND_PLAYED;
|
||||
}
|
||||
}
|
||||
@@ -1756,16 +1752,16 @@ s32 execute_mario_action(UNUSED struct Object *o) {
|
||||
// non-Japanese releases.
|
||||
if (gMarioState->floor->type == SURFACE_HORIZONTAL_WIND) {
|
||||
spawn_wind_particles(0, (gMarioState->floor->force << 8));
|
||||
#ifndef VERSION_JP
|
||||
play_sound(SOUND_ENV_WIND2, gMarioState->marioObj->header.gfx.cameraToObject);
|
||||
#endif
|
||||
if(!ROM_JP){
|
||||
play_sound(SOUND_ENV_WIND2, gMarioState->marioObj->header.gfx.cameraToObject);
|
||||
}
|
||||
}
|
||||
|
||||
if (gMarioState->floor->type == SURFACE_VERTICAL_WIND) {
|
||||
spawn_wind_particles(1, 0);
|
||||
#ifndef VERSION_JP
|
||||
play_sound(SOUND_ENV_WIND2, gMarioState->marioObj->header.gfx.cameraToObject);
|
||||
#endif
|
||||
if(!ROM_JP){
|
||||
play_sound(SOUND_ENV_WIND2, gMarioState->marioObj->header.gfx.cameraToObject);
|
||||
}
|
||||
}
|
||||
|
||||
play_infinite_stairs_music();
|
||||
|
||||
@@ -32,7 +32,6 @@ void play_far_fall_sound(struct MarioState *m) {
|
||||
}
|
||||
}
|
||||
|
||||
#ifndef VERSION_JP
|
||||
void play_knockback_sound(struct MarioState *m) {
|
||||
if (m->actionArg == 0 && (m->forwardVel <= -28.0f || m->forwardVel >= 28.0f)) {
|
||||
play_sound_if_no_flag(m, SOUND_MARIO_DOH, MARIO_MARIO_SOUND_PLAYED);
|
||||
@@ -40,7 +39,6 @@ void play_knockback_sound(struct MarioState *m) {
|
||||
play_sound_if_no_flag(m, SOUND_MARIO_UH, MARIO_MARIO_SOUND_PLAYED);
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
s32 lava_boost_on_wall(struct MarioState *m) {
|
||||
m->faceAngle[1] = atan2s(m->wall->normal.z, m->wall->normal.x);
|
||||
@@ -130,11 +128,7 @@ s32 should_get_stuck_in_ground(struct MarioState *m) {
|
||||
|
||||
s32 check_fall_damage_or_get_stuck(struct MarioState *m, u32 hardFallAction) {
|
||||
if (should_get_stuck_in_ground(m)) {
|
||||
#ifdef VERSION_JP
|
||||
play_sound(SOUND_MARIO_OOOF, m->marioObj->header.gfx.cameraToObject);
|
||||
#else
|
||||
play_sound(SOUND_MARIO_OOOF2, m->marioObj->header.gfx.cameraToObject);
|
||||
#endif
|
||||
play_sound(ROM_JP ? SOUND_MARIO_OOOF : SOUND_MARIO_OOOF2, m->marioObj->header.gfx.cameraToObject);
|
||||
m->particleFlags |= PARTICLE_MIST_CIRCLE;
|
||||
drop_and_set_mario_action(m, ACT_FEET_STUCK_IN_GROUND, 0);
|
||||
#if ENABLE_RUMBLE
|
||||
@@ -174,9 +168,9 @@ s32 check_horizontal_wind(struct MarioState *m) {
|
||||
m->slideYaw = atan2s(m->slideVelZ, m->slideVelX);
|
||||
m->forwardVel = speed * coss(m->faceAngle[1] - m->slideYaw);
|
||||
|
||||
#ifdef VERSION_JP
|
||||
play_sound(SOUND_ENV_WIND2, m->marioObj->header.gfx.cameraToObject);
|
||||
#endif
|
||||
if(ROM_JP){
|
||||
play_sound(SOUND_ENV_WIND2, m->marioObj->header.gfx.cameraToObject);
|
||||
}
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
@@ -490,11 +484,7 @@ s32 act_triple_jump(struct MarioState *m) {
|
||||
return set_mario_action(m, ACT_GROUND_POUND, 0);
|
||||
}
|
||||
|
||||
#ifndef VERSION_JP
|
||||
play_mario_sound(m, SOUND_ACTION_TERRAIN_JUMP, 0);
|
||||
#else
|
||||
play_mario_sound(m, SOUND_ACTION_TERRAIN_JUMP, SOUND_MARIO_YAHOO);
|
||||
#endif
|
||||
play_mario_sound(m, SOUND_ACTION_TERRAIN_JUMP, ROM_JP ? SOUND_MARIO_YAHOO : 0);
|
||||
|
||||
common_air_action_step(m, ACT_TRIPLE_JUMP_LAND, MARIO_ANIM_TRIPLE_JUMP, 0);
|
||||
#if ENABLE_RUMBLE
|
||||
@@ -756,11 +746,7 @@ s32 act_dive(struct MarioState *m) {
|
||||
#if ENABLE_RUMBLE
|
||||
queue_rumble_data(5, 80);
|
||||
#endif
|
||||
#ifdef VERSION_JP
|
||||
play_sound(SOUND_MARIO_OOOF, m->marioObj->header.gfx.cameraToObject);
|
||||
#else
|
||||
play_sound(SOUND_MARIO_OOOF2, m->marioObj->header.gfx.cameraToObject);
|
||||
#endif
|
||||
play_sound(ROM_JP ? SOUND_MARIO_OOOF : SOUND_MARIO_OOOF2, m->marioObj->header.gfx.cameraToObject);
|
||||
m->particleFlags |= PARTICLE_MIST_CIRCLE;
|
||||
drop_and_set_mario_action(m, ACT_HEAD_STUCK_IN_GROUND, 0);
|
||||
} else if (!check_fall_damage(m, ACT_HARD_FORWARD_GROUND_KB)) {
|
||||
@@ -954,11 +940,7 @@ s32 act_ground_pound(struct MarioState *m) {
|
||||
#if ENABLE_RUMBLE
|
||||
queue_rumble_data(5, 80);
|
||||
#endif
|
||||
#ifdef VERSION_JP
|
||||
play_sound(SOUND_MARIO_OOOF, m->marioObj->header.gfx.cameraToObject);
|
||||
#else
|
||||
play_sound(SOUND_MARIO_OOOF2, m->marioObj->header.gfx.cameraToObject);
|
||||
#endif
|
||||
play_sound(ROM_JP ? SOUND_MARIO_OOOF : SOUND_MARIO_OOOF2, m->marioObj->header.gfx.cameraToObject);
|
||||
m->particleFlags |= PARTICLE_MIST_CIRCLE;
|
||||
set_mario_action(m, ACT_BUTT_STUCK_IN_GROUND, 0);
|
||||
} else {
|
||||
@@ -1158,11 +1140,11 @@ s32 act_backward_air_kb(struct MarioState *m) {
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
#ifndef VERSION_JP
|
||||
play_knockback_sound(m);
|
||||
#else
|
||||
play_sound_if_no_flag(m, SOUND_MARIO_UH, MARIO_MARIO_SOUND_PLAYED);
|
||||
#endif
|
||||
if(!ROM_JP){
|
||||
play_knockback_sound(m);
|
||||
} else {
|
||||
play_sound_if_no_flag(m, SOUND_MARIO_UH, MARIO_MARIO_SOUND_PLAYED);
|
||||
}
|
||||
common_air_knockback_step(m, ACT_BACKWARD_GROUND_KB, ACT_HARD_BACKWARD_GROUND_KB, 0x0002, -16.0f);
|
||||
return FALSE;
|
||||
}
|
||||
@@ -1172,32 +1154,32 @@ s32 act_forward_air_kb(struct MarioState *m) {
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
#ifndef VERSION_JP
|
||||
play_knockback_sound(m);
|
||||
#else
|
||||
play_sound_if_no_flag(m, SOUND_MARIO_UH, MARIO_MARIO_SOUND_PLAYED);
|
||||
#endif
|
||||
if(!ROM_JP){
|
||||
play_knockback_sound(m);
|
||||
} else {
|
||||
play_sound_if_no_flag(m, SOUND_MARIO_UH, MARIO_MARIO_SOUND_PLAYED);
|
||||
}
|
||||
common_air_knockback_step(m, ACT_FORWARD_GROUND_KB, ACT_HARD_FORWARD_GROUND_KB, 0x002D, 16.0f);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
s32 act_hard_backward_air_kb(struct MarioState *m) {
|
||||
#ifndef VERSION_JP
|
||||
play_knockback_sound(m);
|
||||
#else
|
||||
play_sound_if_no_flag(m, SOUND_MARIO_UH, MARIO_MARIO_SOUND_PLAYED);
|
||||
#endif
|
||||
if(!ROM_JP){
|
||||
play_knockback_sound(m);
|
||||
} else {
|
||||
play_sound_if_no_flag(m, SOUND_MARIO_UH, MARIO_MARIO_SOUND_PLAYED);
|
||||
}
|
||||
common_air_knockback_step(m, ACT_HARD_BACKWARD_GROUND_KB, ACT_HARD_BACKWARD_GROUND_KB, 0x0002,
|
||||
-16.0f);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
s32 act_hard_forward_air_kb(struct MarioState *m) {
|
||||
#ifndef VERSION_JP
|
||||
play_knockback_sound(m);
|
||||
#else
|
||||
play_sound_if_no_flag(m, SOUND_MARIO_UH, MARIO_MARIO_SOUND_PLAYED);
|
||||
#endif
|
||||
if(!ROM_JP){
|
||||
play_knockback_sound(m);
|
||||
} else {
|
||||
play_sound_if_no_flag(m, SOUND_MARIO_UH, MARIO_MARIO_SOUND_PLAYED);
|
||||
}
|
||||
common_air_knockback_step(m, ACT_HARD_FORWARD_GROUND_KB, ACT_HARD_FORWARD_GROUND_KB, 0x002D, 16.0f);
|
||||
return FALSE;
|
||||
}
|
||||
@@ -1249,11 +1231,11 @@ s32 act_soft_bonk(struct MarioState *m) {
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
#ifndef VERSION_JP
|
||||
play_knockback_sound(m);
|
||||
#else
|
||||
play_sound_if_no_flag(m, SOUND_MARIO_UH, MARIO_MARIO_SOUND_PLAYED);
|
||||
#endif
|
||||
if(!ROM_JP){
|
||||
play_knockback_sound(m);
|
||||
} else {
|
||||
play_sound_if_no_flag(m, SOUND_MARIO_UH, MARIO_MARIO_SOUND_PLAYED);
|
||||
}
|
||||
|
||||
common_air_knockback_step(m, ACT_FREEFALL_LAND, ACT_HARD_BACKWARD_GROUND_KB, 0x0056, m->forwardVel);
|
||||
return FALSE;
|
||||
@@ -1281,9 +1263,9 @@ s32 act_getting_blown(struct MarioState *m) {
|
||||
}
|
||||
|
||||
mario_set_forward_vel(m, m->forwardVel);
|
||||
#ifdef VERSION_JP
|
||||
play_sound_if_no_flag(m, SOUND_MARIO_UH, MARIO_MARIO_SOUND_PLAYED);
|
||||
#endif
|
||||
if(ROM_JP){
|
||||
play_sound_if_no_flag(m, SOUND_MARIO_UH, MARIO_MARIO_SOUND_PLAYED);
|
||||
}
|
||||
set_mario_animation(m, MARIO_ANIM_BACKWARD_AIR_KB);
|
||||
|
||||
switch (perform_air_step(m, 0)) {
|
||||
@@ -1823,10 +1805,10 @@ s32 act_flying(struct MarioState *m) {
|
||||
|
||||
if (startPitch <= 0 && m->faceAngle[0] > 0 && m->forwardVel >= 48.0f) {
|
||||
play_sound(SOUND_ACTION_FLYING_FAST, m->marioObj->header.gfx.cameraToObject);
|
||||
#ifndef VERSION_JP
|
||||
play_sound(SOUND_MARIO_YAHOO_WAHA_YIPPEE + ((gAudioRandom % 5) << 16),
|
||||
if(!ROM_JP){
|
||||
play_sound(SOUND_MARIO_YAHOO_WAHA_YIPPEE + ((gAudioRandom % 5) << 16),
|
||||
m->marioObj->header.gfx.cameraToObject);
|
||||
#endif
|
||||
}
|
||||
#if ENABLE_RUMBLE
|
||||
queue_rumble_data(50, 40);
|
||||
#endif
|
||||
|
||||
@@ -1156,11 +1156,7 @@ s32 act_exit_land_save_dialog(struct MarioState *m) {
|
||||
s32 act_death_exit(struct MarioState *m) {
|
||||
if (15 < m->actionTimer++
|
||||
&& launch_mario_until_land(m, ACT_DEATH_EXIT_LAND, MARIO_ANIM_GENERAL_FALL, -32.0f)) {
|
||||
#ifdef VERSION_JP
|
||||
play_sound(SOUND_MARIO_OOOF, m->marioObj->header.gfx.cameraToObject);
|
||||
#else
|
||||
play_sound(SOUND_MARIO_OOOF2, m->marioObj->header.gfx.cameraToObject);
|
||||
#endif
|
||||
play_sound(ROM_JP ? SOUND_MARIO_OOOF : SOUND_MARIO_OOOF2, m->marioObj->header.gfx.cameraToObject);
|
||||
#if ENABLE_RUMBLE
|
||||
queue_rumble_data(5, 80);
|
||||
#endif
|
||||
@@ -1175,11 +1171,7 @@ s32 act_death_exit(struct MarioState *m) {
|
||||
|
||||
s32 act_unused_death_exit(struct MarioState *m) {
|
||||
if (launch_mario_until_land(m, ACT_FREEFALL_LAND_STOP, MARIO_ANIM_GENERAL_FALL, 0.0f)) {
|
||||
#ifdef VERSION_JP
|
||||
play_sound(SOUND_MARIO_OOOF, m->marioObj->header.gfx.cameraToObject);
|
||||
#else
|
||||
play_sound(SOUND_MARIO_OOOF2, m->marioObj->header.gfx.cameraToObject);
|
||||
#endif
|
||||
play_sound(ROM_JP ? SOUND_MARIO_OOOF : SOUND_MARIO_OOOF2, m->marioObj->header.gfx.cameraToObject);
|
||||
m->numLives--;
|
||||
// restore 7.75 units of health
|
||||
m->healCounter = 31;
|
||||
@@ -1191,11 +1183,7 @@ s32 act_unused_death_exit(struct MarioState *m) {
|
||||
|
||||
s32 act_falling_death_exit(struct MarioState *m) {
|
||||
if (launch_mario_until_land(m, ACT_DEATH_EXIT_LAND, MARIO_ANIM_GENERAL_FALL, 0.0f)) {
|
||||
#ifdef VERSION_JP
|
||||
play_sound(SOUND_MARIO_OOOF, m->marioObj->header.gfx.cameraToObject);
|
||||
#else
|
||||
play_sound(SOUND_MARIO_OOOF2, m->marioObj->header.gfx.cameraToObject);
|
||||
#endif
|
||||
play_sound(ROM_JP ? SOUND_MARIO_OOOF : SOUND_MARIO_OOOF2, m->marioObj->header.gfx.cameraToObject);
|
||||
#if ENABLE_RUMBLE
|
||||
queue_rumble_data(5, 80);
|
||||
#endif
|
||||
@@ -1718,9 +1706,9 @@ static void intro_cutscene_jump_out_of_pipe(struct MarioState *m) {
|
||||
play_sound_if_no_flag(m, SOUND_MARIO_YAHOO, MARIO_MARIO_SOUND_PLAYED);
|
||||
#else
|
||||
play_sound_if_no_flag(m, SOUND_MARIO_YAHOO, MARIO_MARIO_SOUND_PLAYED);
|
||||
#ifndef VERSION_JP
|
||||
play_sound_if_no_flag(m, SOUND_ACTION_HIT_3, MARIO_ACTION_SOUND_PLAYED);
|
||||
#endif
|
||||
if(!ROM_JP){
|
||||
play_sound_if_no_flag(m, SOUND_ACTION_HIT_3, MARIO_ACTION_SOUND_PLAYED);
|
||||
}
|
||||
#endif
|
||||
|
||||
set_mario_animation(m, MARIO_ANIM_SINGLE_JUMP);
|
||||
@@ -1728,9 +1716,9 @@ static void intro_cutscene_jump_out_of_pipe(struct MarioState *m) {
|
||||
if (perform_air_step(m, 0) == AIR_STEP_LANDED) {
|
||||
sound_banks_enable(SEQ_PLAYER_SFX, SOUND_BANKS_DISABLED_DURING_INTRO_CUTSCENE);
|
||||
play_mario_landing_sound(m, SOUND_ACTION_TERRAIN_LANDING);
|
||||
#ifndef VERSION_JP
|
||||
play_sound(SOUND_MARIO_HAHA, m->marioObj->header.gfx.cameraToObject);
|
||||
#endif
|
||||
if(!ROM_JP){
|
||||
play_sound(SOUND_MARIO_HAHA, m->marioObj->header.gfx.cameraToObject);
|
||||
}
|
||||
advance_cutscene_step(m);
|
||||
}
|
||||
}
|
||||
@@ -2225,10 +2213,10 @@ static void end_peach_cutscene_dialog_1(struct MarioState *m) {
|
||||
case 230:
|
||||
#endif
|
||||
set_cutscene_message(160, 227, 0, 30);
|
||||
#ifndef VERSION_JP
|
||||
seq_player_lower_volume(SEQ_PLAYER_LEVEL, 60, 40);
|
||||
play_sound(SOUND_PEACH_MARIO, sEndPeachObj->header.gfx.cameraToObject);
|
||||
#endif
|
||||
if(!ROM_JP){
|
||||
seq_player_lower_volume(SEQ_PLAYER_LEVEL, 60, 40);
|
||||
play_sound(SOUND_PEACH_MARIO, sEndPeachObj->header.gfx.cameraToObject);
|
||||
}
|
||||
break;
|
||||
|
||||
#ifdef VERSION_SH
|
||||
@@ -2246,9 +2234,9 @@ static void end_peach_cutscene_dialog_1(struct MarioState *m) {
|
||||
case 290:
|
||||
#endif
|
||||
set_cutscene_message(160, 227, 1, 60);
|
||||
#ifndef VERSION_JP
|
||||
play_sound(SOUND_PEACH_POWER_OF_THE_STARS, sEndPeachObj->header.gfx.cameraToObject);
|
||||
#endif
|
||||
if(!ROM_JP){
|
||||
play_sound(SOUND_PEACH_POWER_OF_THE_STARS, sEndPeachObj->header.gfx.cameraToObject);
|
||||
}
|
||||
break;
|
||||
|
||||
#ifdef VERSION_SH
|
||||
@@ -2286,9 +2274,9 @@ static void end_peach_cutscene_dialog_2(struct MarioState *m) {
|
||||
case 29:
|
||||
#endif
|
||||
set_cutscene_message(160, 227, 2, 30);
|
||||
#ifndef VERSION_JP
|
||||
play_sound(SOUND_PEACH_THANKS_TO_YOU, sEndPeachObj->header.gfx.cameraToObject);
|
||||
#endif
|
||||
if(!ROM_JP){
|
||||
play_sound(SOUND_PEACH_THANKS_TO_YOU, sEndPeachObj->header.gfx.cameraToObject);
|
||||
}
|
||||
break;
|
||||
|
||||
#ifdef VERSION_SH
|
||||
@@ -2305,16 +2293,16 @@ static void end_peach_cutscene_dialog_2(struct MarioState *m) {
|
||||
case 75:
|
||||
#endif
|
||||
set_cutscene_message(160, 227, 3, 30);
|
||||
#ifndef VERSION_JP
|
||||
play_sound(SOUND_PEACH_THANK_YOU_MARIO, sEndPeachObj->header.gfx.cameraToObject);
|
||||
#endif
|
||||
if(!ROM_JP){
|
||||
play_sound(SOUND_PEACH_THANK_YOU_MARIO, sEndPeachObj->header.gfx.cameraToObject);
|
||||
}
|
||||
break;
|
||||
|
||||
case TIMER_SOMETHING_SPECIAL:
|
||||
set_cutscene_message(160, 227, 4, 40);
|
||||
#ifndef VERSION_JP
|
||||
play_sound(SOUND_PEACH_SOMETHING_SPECIAL, sEndPeachObj->header.gfx.cameraToObject);
|
||||
#endif
|
||||
if(!ROM_JP){
|
||||
play_sound(SOUND_PEACH_SOMETHING_SPECIAL, sEndPeachObj->header.gfx.cameraToObject);
|
||||
}
|
||||
break;
|
||||
|
||||
case TIMER_PEACH_KISS:
|
||||
@@ -2443,9 +2431,9 @@ static void end_peach_cutscene_dialog_3(struct MarioState *m) {
|
||||
sEndToadAnims[1] = 2;
|
||||
D_8032CBE8 = 1;
|
||||
set_cutscene_message(160, 227, 5, 30);
|
||||
#ifndef VERSION_JP
|
||||
play_sound(SOUND_PEACH_BAKE_A_CAKE, sEndPeachObj->header.gfx.cameraToObject);
|
||||
#endif
|
||||
if(!ROM_JP){
|
||||
play_sound(SOUND_PEACH_BAKE_A_CAKE, sEndPeachObj->header.gfx.cameraToObject);
|
||||
}
|
||||
break;
|
||||
|
||||
case 55:
|
||||
@@ -2454,9 +2442,9 @@ static void end_peach_cutscene_dialog_3(struct MarioState *m) {
|
||||
|
||||
case 130:
|
||||
set_cutscene_message(160, 227, 7, 50);
|
||||
#ifndef VERSION_JP
|
||||
play_sound(SOUND_PEACH_FOR_MARIO, sEndPeachObj->header.gfx.cameraToObject);
|
||||
#endif
|
||||
if(!ROM_JP){
|
||||
play_sound(SOUND_PEACH_FOR_MARIO, sEndPeachObj->header.gfx.cameraToObject);
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -2478,9 +2466,9 @@ static void end_peach_cutscene_run_to_castle(struct MarioState *m) {
|
||||
|
||||
if (m->actionTimer == 95) {
|
||||
set_cutscene_message(160, 227, 0, 40);
|
||||
#ifndef VERSION_JP
|
||||
play_sound(SOUND_PEACH_MARIO2, sEndPeachObj->header.gfx.cameraToObject);
|
||||
#endif
|
||||
if(!ROM_JP){
|
||||
play_sound(SOUND_PEACH_MARIO2, sEndPeachObj->header.gfx.cameraToObject);
|
||||
}
|
||||
}
|
||||
if (m->actionTimer == 389) {
|
||||
advance_cutscene_step(m);
|
||||
|
||||
@@ -1595,11 +1595,7 @@ s32 common_ground_knockback_action(struct MarioState *m, s32 animation, s32 arg2
|
||||
if (arg4 > 0) {
|
||||
play_sound_if_no_flag(m, SOUND_MARIO_ATTACKED, MARIO_MARIO_SOUND_PLAYED);
|
||||
} else {
|
||||
#ifdef VERSION_JP
|
||||
play_sound_if_no_flag(m, SOUND_MARIO_OOOF, MARIO_MARIO_SOUND_PLAYED);
|
||||
#else
|
||||
play_sound_if_no_flag(m, SOUND_MARIO_OOOF2, MARIO_MARIO_SOUND_PLAYED);
|
||||
#endif
|
||||
play_sound_if_no_flag(m, ROM_JP ? SOUND_MARIO_OOOF : SOUND_MARIO_OOOF2, MARIO_MARIO_SOUND_PLAYED);
|
||||
}
|
||||
|
||||
if (m->forwardVel > 32.0f) {
|
||||
@@ -1645,11 +1641,9 @@ s32 act_hard_backward_ground_kb(struct MarioState *m) {
|
||||
set_mario_action(m, ACT_DEATH_ON_BACK, 0);
|
||||
}
|
||||
|
||||
#ifndef VERSION_JP
|
||||
if (animFrame == 54 && m->prevAction == ACT_SPECIAL_DEATH_EXIT) {
|
||||
if (!ROM_JP && animFrame == 54 && m->prevAction == ACT_SPECIAL_DEATH_EXIT) {
|
||||
play_sound(SOUND_MARIO_MAMA_MIA, m->marioObj->header.gfx.cameraToObject);
|
||||
}
|
||||
#endif
|
||||
|
||||
if (animFrame == 69) {
|
||||
play_mario_landing_sound_once(m, SOUND_ACTION_TERRAIN_LANDING);
|
||||
|
||||
@@ -337,15 +337,17 @@ s32 act_holding_bowser(struct MarioState *m) {
|
||||
s16 spin;
|
||||
|
||||
if (m->input & INPUT_B_PRESSED) {
|
||||
#ifndef VERSION_JP
|
||||
if (m->angleVel[1] <= -0xE00 || m->angleVel[1] >= 0xE00) {
|
||||
play_sound(SOUND_MARIO_SO_LONGA_BOWSER, m->marioObj->header.gfx.cameraToObject);
|
||||
|
||||
if(!ROM_JP){
|
||||
if (m->angleVel[1] <= -0xE00 || m->angleVel[1] >= 0xE00) {
|
||||
play_sound(SOUND_MARIO_SO_LONGA_BOWSER, m->marioObj->header.gfx.cameraToObject);
|
||||
} else {
|
||||
play_sound(SOUND_MARIO_HERE_WE_GO, m->marioObj->header.gfx.cameraToObject);
|
||||
}
|
||||
} else {
|
||||
play_sound(SOUND_MARIO_HERE_WE_GO, m->marioObj->header.gfx.cameraToObject);
|
||||
}
|
||||
#else
|
||||
play_sound(SOUND_MARIO_HERE_WE_GO, m->marioObj->header.gfx.cameraToObject);
|
||||
#endif
|
||||
|
||||
return set_mario_action(m, ACT_RELEASING_BOWSER, 0);
|
||||
}
|
||||
|
||||
|
||||
@@ -179,9 +179,7 @@ void play_anim_sound(struct MarioState *m, u32 actionState, s32 animFrame, u32 s
|
||||
}
|
||||
|
||||
s32 act_start_sleeping(struct MarioState *m) {
|
||||
#ifndef VERSION_JP
|
||||
s32 animFrame;
|
||||
#endif
|
||||
|
||||
if (check_common_idle_cancels(m)) {
|
||||
return TRUE;
|
||||
@@ -197,32 +195,20 @@ s32 act_start_sleeping(struct MarioState *m) {
|
||||
|
||||
switch (m->actionState) {
|
||||
case 0:
|
||||
#ifndef VERSION_JP
|
||||
animFrame =
|
||||
#endif
|
||||
set_mario_animation(m, MARIO_ANIM_START_SLEEP_IDLE);
|
||||
animFrame = set_mario_animation(m, MARIO_ANIM_START_SLEEP_IDLE);
|
||||
break;
|
||||
|
||||
case 1:
|
||||
#ifndef VERSION_JP
|
||||
animFrame =
|
||||
#endif
|
||||
set_mario_animation(m, MARIO_ANIM_START_SLEEP_SCRATCH);
|
||||
animFrame = set_mario_animation(m, MARIO_ANIM_START_SLEEP_SCRATCH);
|
||||
break;
|
||||
|
||||
case 2:
|
||||
#ifndef VERSION_JP
|
||||
animFrame =
|
||||
#endif
|
||||
set_mario_animation(m, MARIO_ANIM_START_SLEEP_YAWN);
|
||||
animFrame = set_mario_animation(m, MARIO_ANIM_START_SLEEP_YAWN);
|
||||
m->marioBodyState->eyeState = MARIO_EYES_HALF_CLOSED;
|
||||
break;
|
||||
|
||||
case 3:
|
||||
#ifndef VERSION_JP
|
||||
animFrame =
|
||||
#endif
|
||||
set_mario_animation(m, MARIO_ANIM_START_SLEEP_SITTING);
|
||||
animFrame = set_mario_animation(m, MARIO_ANIM_START_SLEEP_SITTING);
|
||||
m->marioBodyState->eyeState = MARIO_EYES_HALF_CLOSED;
|
||||
break;
|
||||
}
|
||||
@@ -235,19 +221,17 @@ s32 act_start_sleeping(struct MarioState *m) {
|
||||
m->actionState++;
|
||||
}
|
||||
|
||||
#ifndef VERSION_JP
|
||||
if (m->actionState == 2 && animFrame == -1) {
|
||||
if (!ROM_JP && m->actionState == 2 && animFrame == -1) {
|
||||
play_sound(SOUND_MARIO_YAWNING, m->marioObj->header.gfx.cameraToObject);
|
||||
}
|
||||
|
||||
if (m->actionState == 1 && animFrame == -1) {
|
||||
if (!ROM_JP && m->actionState == 1 && animFrame == -1) {
|
||||
play_sound(SOUND_MARIO_IMA_TIRED, m->marioObj->header.gfx.cameraToObject);
|
||||
}
|
||||
#else
|
||||
if (m->actionState == 2) {
|
||||
|
||||
if (ROM_JP && m->actionState == 2) {
|
||||
play_sound_if_no_flag(m, SOUND_MARIO_YAWNING, MARIO_MARIO_SOUND_PLAYED);
|
||||
}
|
||||
#endif
|
||||
|
||||
stationary_ground_step(m);
|
||||
return FALSE;
|
||||
@@ -307,17 +291,19 @@ s32 act_sleeping(struct MarioState *m) {
|
||||
|
||||
case 2:
|
||||
animFrame = set_mario_animation(m, MARIO_ANIM_SLEEP_LYING);
|
||||
#ifndef VERSION_JP
|
||||
play_sound_if_no_flag(m, SOUND_MARIO_SNORING3, MARIO_ACTION_SOUND_PLAYED);
|
||||
#else
|
||||
if (animFrame == 2) {
|
||||
play_sound(SOUND_MARIO_SNORING2, m->marioObj->header.gfx.cameraToObject);
|
||||
|
||||
if(!ROM_JP){
|
||||
play_sound_if_no_flag(m, SOUND_MARIO_SNORING3, MARIO_ACTION_SOUND_PLAYED);
|
||||
} else {
|
||||
if (animFrame == 2) {
|
||||
play_sound(SOUND_MARIO_SNORING2, m->marioObj->header.gfx.cameraToObject);
|
||||
}
|
||||
|
||||
if (animFrame == 25) {
|
||||
play_sound(SOUND_MARIO_SNORING1, m->marioObj->header.gfx.cameraToObject);
|
||||
}
|
||||
}
|
||||
|
||||
if (animFrame == 25) {
|
||||
play_sound(SOUND_MARIO_SNORING1, m->marioObj->header.gfx.cameraToObject);
|
||||
}
|
||||
#endif
|
||||
break;
|
||||
}
|
||||
return FALSE;
|
||||
@@ -327,9 +313,9 @@ s32 act_waking_up(struct MarioState *m) {
|
||||
if (!m->actionTimer) {
|
||||
stop_sound(SOUND_MARIO_SNORING1, m->marioObj->header.gfx.cameraToObject);
|
||||
stop_sound(SOUND_MARIO_SNORING2, m->marioObj->header.gfx.cameraToObject);
|
||||
#ifndef VERSION_JP
|
||||
stop_sound(SOUND_MARIO_SNORING3, m->marioObj->header.gfx.cameraToObject);
|
||||
#endif
|
||||
if(!ROM_JP){
|
||||
stop_sound(SOUND_MARIO_SNORING3, m->marioObj->header.gfx.cameraToObject);
|
||||
}
|
||||
raise_background_noise(2);
|
||||
}
|
||||
|
||||
|
||||
@@ -211,9 +211,9 @@ u32 mario_update_windy_ground(struct MarioState *m) {
|
||||
m->vel[0] += pushSpeed * sins(pushAngle);
|
||||
m->vel[2] += pushSpeed * coss(pushAngle);
|
||||
|
||||
#ifdef VERSION_JP
|
||||
play_sound(SOUND_ENV_WIND2, m->marioObj->header.gfx.cameraToObject);
|
||||
#endif
|
||||
if(ROM_JP){
|
||||
play_sound(SOUND_ENV_WIND2, m->marioObj->header.gfx.cameraToObject);
|
||||
}
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
@@ -600,9 +600,9 @@ void apply_vertical_wind(struct MarioState *m) {
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef VERSION_JP
|
||||
play_sound(SOUND_ENV_WIND2, m->marioObj->header.gfx.cameraToObject);
|
||||
#endif
|
||||
if(ROM_JP){
|
||||
play_sound(SOUND_ENV_WIND2, m->marioObj->header.gfx.cameraToObject);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -461,7 +461,9 @@ s32 save_file_get_total_star_count(s32 fileIndex, s32 minCourse, s32 maxCourse)
|
||||
}
|
||||
|
||||
// Add castle secret star count.
|
||||
return save_file_get_course_star_count(fileIndex, COURSE_NUM_TO_INDEX(COURSE_NONE)) + count;
|
||||
// return save_file_get_course_star_count(fileIndex, COURSE_NUM_TO_INDEX(COURSE_NONE)) + count;
|
||||
// TODO: Implement this
|
||||
return 255;
|
||||
}
|
||||
|
||||
void save_file_set_flags(u32 flags) {
|
||||
|
||||
+1
-13
@@ -1371,11 +1371,7 @@ void bhv_menu_button_manager_init(void) {
|
||||
sTextBaseAlpha = 0;
|
||||
}
|
||||
|
||||
#ifdef VERSION_JP
|
||||
#define SAVE_FILE_SOUND SOUND_MENU_STAR_SOUND
|
||||
#else
|
||||
#define SAVE_FILE_SOUND SOUND_MENU_STAR_SOUND_OKEY_DOKEY
|
||||
#endif
|
||||
#define SAVE_FILE_SOUND ( ROM_JP ? SOUND_MENU_STAR_SOUND : SOUND_MENU_STAR_SOUND_OKEY_DOKEY)
|
||||
|
||||
/**
|
||||
* In the main menu, check if a button was clicked to play it's button growing state.
|
||||
@@ -1481,8 +1477,6 @@ void check_main_menu_clicked_buttons(void) {
|
||||
#endif
|
||||
}
|
||||
|
||||
#undef SAVE_FILE_SOUND
|
||||
|
||||
/**
|
||||
* Menu Buttons Menu Manager Loop Action
|
||||
* Calls a menu function depending of the button chosen.
|
||||
@@ -2687,16 +2681,10 @@ void print_score_file_star_score(s8 fileIndex, s16 courseIndex, s16 x, s16 y) {
|
||||
void print_save_file_scores(s8 fileIndex) {
|
||||
#ifndef VERSION_EU
|
||||
unsigned char textMario[] = { TEXT_MARIO };
|
||||
#ifdef VERSION_JP
|
||||
unsigned char textFileLetter[] = { TEXT_ZERO };
|
||||
void **levelNameTable = segmented_to_virtual(seg2_course_name_table);
|
||||
#endif
|
||||
unsigned char textHiScore[] = { TEXT_HI_SCORE };
|
||||
unsigned char textMyScore[] = { TEXT_MY_SCORE };
|
||||
#if defined(VERSION_US) || defined(VERSION_SH)
|
||||
unsigned char textFileLetter[] = { TEXT_ZERO };
|
||||
void **levelNameTable = segmented_to_virtual(seg2_course_name_table);
|
||||
#endif
|
||||
#else
|
||||
unsigned char textFileLetter[] = { TEXT_ZERO };
|
||||
void **levelNameTable;
|
||||
|
||||
@@ -398,11 +398,7 @@ s32 lvl_update_obj_and_load_act_button_actions(UNUSED s32 arg, UNUSED s32 unused
|
||||
#else
|
||||
if ((gPlayer3Controller->buttonPressed & (A_BUTTON | START_BUTTON | B_BUTTON | Z_TRIG))) {
|
||||
#endif
|
||||
#ifdef VERSION_JP
|
||||
play_sound(SOUND_MENU_STAR_SOUND, gGlobalSoundSource);
|
||||
#else
|
||||
play_sound(SOUND_MENU_STAR_SOUND_LETS_A_GO, gGlobalSoundSource);
|
||||
#endif
|
||||
play_sound(ROM_JP ? SOUND_MENU_STAR_SOUND : SOUND_MENU_STAR_SOUND_LETS_A_GO, gGlobalSoundSource);
|
||||
#if ENABLE_RUMBLE
|
||||
queue_rumble_data(60, 70);
|
||||
func_sh_8024C89C(1);
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user