mirror of
https://github.com/n64decomp/mk64
synced 2026-07-11 13:48:45 -04:00
change bool (#644)
Co-authored-by: MegaMech <MegaMech@users.noreply.github.com>
This commit is contained in:
@@ -10,7 +10,7 @@ After boot, the game begins by setting up its four threads; [idle](@ref thread1_
|
||||
|
||||
The [idle thread](@ref thread1_idle) allows the cpu to sleep. Without it, if at any time execution of all threads were paused, the cpu would never be able to continue. The idle thread is active if all the other threads are paused.
|
||||
|
||||
As such, the [idle thread](@ref thread1_idle) runs the following loop: `while(TRUE);` (it runs in a perpetual loop of nothing; sleep). In mips assembly it looks like this:
|
||||
As such, the [idle thread](@ref thread1_idle) runs the following loop: `while(true);` (it runs in a perpetual loop of nothing; sleep). In mips assembly it looks like this:
|
||||
```
|
||||
.L800005B8:
|
||||
b .L800005B8
|
||||
|
||||
@@ -96,11 +96,11 @@ index 0000000..5569838
|
||||
+#define SENSITIVITY_X 0.0003f
|
||||
+#define SENSITIVITY_Y 0.0003f
|
||||
+
|
||||
+u32 isFlycam = FALSE;
|
||||
+u32 isFlycam = false;
|
||||
+u32 fRankIndex = 0;
|
||||
+u32 fTargetPlayer = FALSE;
|
||||
+u32 fTargetPlayer = false;
|
||||
+u32 fMode; // flycam mode should probably be an enum
|
||||
+u32 fModeInit = FALSE;
|
||||
+u32 fModeInit = false;
|
||||
+
|
||||
+typedef struct {
|
||||
+ Vec3f pos;
|
||||
@@ -217,7 +217,7 @@ index 0000000..5569838
|
||||
+ fState.rot[0] = camera->rot[0];
|
||||
+ fState.rot[1] = camera->rot[1];
|
||||
+ fState.rot[2] = camera->rot[2];
|
||||
+ fModeInit = TRUE;
|
||||
+ fModeInit = true;
|
||||
+}
|
||||
+
|
||||
+void flycam_load_state(Camera *camera) {
|
||||
|
||||
@@ -5,8 +5,8 @@
|
||||
#define NULL (void *)0
|
||||
#endif
|
||||
|
||||
#define TRUE 1
|
||||
#define FALSE 0
|
||||
#define true 1
|
||||
#define false 0
|
||||
|
||||
typedef signed char s8;
|
||||
typedef unsigned char u8;
|
||||
@@ -17,7 +17,8 @@ typedef unsigned int u32;
|
||||
typedef signed long long int s64;
|
||||
typedef unsigned long long int u64;
|
||||
|
||||
typedef signed int bool;
|
||||
#define bool signed int
|
||||
|
||||
typedef signed char bool8;
|
||||
typedef unsigned char ubool8;
|
||||
|
||||
|
||||
+6
-6
@@ -30,7 +30,7 @@ void sequence_channel_process_sound(struct SequenceChannel *seqChannel, s32 reca
|
||||
layer->noteFreqScale = layer->freqScale * seqChannel->freqScale;
|
||||
layer->noteVelocity = layer->velocitySquare * seqChannel->appliedVolume;
|
||||
layer->notePan = (seqChannel->pan + layer->pan * (0x80 - seqChannel->panChannelWeight)) >> 7;
|
||||
layer->notePropertiesNeedInit = FALSE;
|
||||
layer->notePropertiesNeedInit = false;
|
||||
} else {
|
||||
if (seqChannel->changes.as_bitfields.freqScale) {
|
||||
layer->noteFreqScale = layer->freqScale * seqChannel->freqScale;
|
||||
@@ -52,7 +52,7 @@ void sequence_player_process_sound(struct SequencePlayer *seqPlayer) {
|
||||
|
||||
if (seqPlayer->fadeRemainingFrames != 0) {
|
||||
seqPlayer->fadeVolume += seqPlayer->fadeVelocity;
|
||||
seqPlayer->recalculateVolume = TRUE;
|
||||
seqPlayer->recalculateVolume = true;
|
||||
|
||||
if (seqPlayer->fadeVolume > US_FLOAT2(1)) {
|
||||
seqPlayer->fadeVolume = US_FLOAT2(1);
|
||||
@@ -75,13 +75,13 @@ void sequence_player_process_sound(struct SequencePlayer *seqPlayer) {
|
||||
|
||||
// Process channels
|
||||
for (i = 0; i < CHANNELS_MAX; i++) {
|
||||
if (IS_SEQUENCE_CHANNEL_VALID(seqPlayer->channels[i]) == TRUE
|
||||
&& seqPlayer->channels[i]->enabled == TRUE) {
|
||||
if (IS_SEQUENCE_CHANNEL_VALID(seqPlayer->channels[i]) == true
|
||||
&& seqPlayer->channels[i]->enabled == true) {
|
||||
sequence_channel_process_sound(seqPlayer->channels[i], seqPlayer->recalculateVolume);
|
||||
}
|
||||
}
|
||||
|
||||
seqPlayer->recalculateVolume = FALSE;
|
||||
seqPlayer->recalculateVolume = false;
|
||||
}
|
||||
|
||||
f32 get_portamento_freq_scale(struct Portamento *p) {
|
||||
@@ -176,7 +176,7 @@ void note_vibrato_init(struct Note *note) {
|
||||
|
||||
vib = ¬e->vibratoState;
|
||||
|
||||
vib->active = TRUE;
|
||||
vib->active = true;
|
||||
vib->time = 0;
|
||||
|
||||
vib->curve = gWaveSamples[2];
|
||||
|
||||
+13
-13
@@ -967,10 +967,10 @@ u8 func_800C357C(s32 arg0) {
|
||||
u8 i;
|
||||
|
||||
i = D_800EA1E8;
|
||||
var_v1 = TRUE;
|
||||
var_v1 = true;
|
||||
for(i = D_800EA1E8; i < (s32) D_800EA1E4; i++) {
|
||||
if ((u32) arg0 == D_80192CD0[i]) {
|
||||
var_v1 = FALSE;
|
||||
var_v1 = false;
|
||||
i = D_800EA1E4;
|
||||
}
|
||||
}
|
||||
@@ -1237,9 +1237,9 @@ void func_800C4084(u16 bankMask) {
|
||||
|
||||
for (bank = 0; bank < SOUND_BANK_COUNT; bank++) {
|
||||
if (bankMask & 1) {
|
||||
sSoundBankDisabled[bank] = TRUE;
|
||||
sSoundBankDisabled[bank] = true;
|
||||
} else {
|
||||
sSoundBankDisabled[bank] = FALSE;
|
||||
sSoundBankDisabled[bank] = false;
|
||||
}
|
||||
bankMask = bankMask >> 1;
|
||||
}
|
||||
@@ -1258,7 +1258,7 @@ void play_sound(u32 soundBits, Vec3f *position, u8 cameraId, f32 *arg3, f32 *arg
|
||||
struct Sound *temp_v0;
|
||||
|
||||
bank = soundBits >> 0x1C;
|
||||
if (sSoundBankDisabled[bank] == FALSE) {
|
||||
if (sSoundBankDisabled[bank] == false) {
|
||||
temp_v0 = &sSoundRequests[sSoundRequestCount];
|
||||
temp_v0->soundBits = soundBits;
|
||||
temp_v0->position = position;
|
||||
@@ -1276,37 +1276,37 @@ void func_800C41CC(u8 arg0, struct SoundCharacteristics *arg1) {
|
||||
struct Sound *sound;
|
||||
|
||||
for (soundId = sNumProcessedSoundRequests; soundId != sSoundRequestCount; soundId++) {
|
||||
found = FALSE;
|
||||
found = false;
|
||||
sound = &sSoundRequests[soundId];
|
||||
switch (arg0) {
|
||||
case 0:
|
||||
if ((sound->soundBits & 0xF0000000) == (arg1->soundBits & 0xF0000000)) {
|
||||
found = TRUE;
|
||||
found = true;
|
||||
}
|
||||
break;
|
||||
case 1:
|
||||
if (((sound->soundBits & 0xF0000000) == (arg1->soundBits & 0xF0000000)) && (sound->position == arg1->unk00)) {
|
||||
found = TRUE;
|
||||
found = true;
|
||||
}
|
||||
break;
|
||||
case 2:
|
||||
if (sound->position == arg1->unk00) {
|
||||
found = TRUE;
|
||||
found = true;
|
||||
}
|
||||
break;
|
||||
case 3:
|
||||
if ((sound->position == arg1->unk00) && (sound->soundBits == arg1->soundBits)) {
|
||||
found = TRUE;
|
||||
found = true;
|
||||
}
|
||||
break;
|
||||
case 4:
|
||||
if ((sound->cameraId == arg1->cameraId) && (sound->soundBits == arg1->soundBits)) {
|
||||
found = TRUE;
|
||||
found = true;
|
||||
}
|
||||
break;
|
||||
case 5:
|
||||
if (sound->soundBits == arg1->soundBits) {
|
||||
found = TRUE;
|
||||
found = true;
|
||||
}
|
||||
break;
|
||||
}
|
||||
@@ -1806,7 +1806,7 @@ void sound_init(void) {
|
||||
sSoundBankUsedListBack[var_v0] = 0;
|
||||
sSoundBankFreeListFront[var_v0] = 1;
|
||||
sNumSoundsInBank[var_v0] = 0;
|
||||
sSoundBankDisabled[var_v0] = FALSE;
|
||||
sSoundBankDisabled[var_v0] = false;
|
||||
D_80192C48[var_v0].current = 1.0f;
|
||||
D_80192C48[var_v0].remainingFrames = 0;
|
||||
}
|
||||
|
||||
+3
-3
@@ -126,8 +126,8 @@ void discard_bank(s32 bankId) {
|
||||
if (note->priority >= NOTE_PRIORITY_MIN) {
|
||||
// eu_stubbed_printf_3("Kill Voice %d (ID %d) %d\n", note->waveId, bankId, note->priority);
|
||||
// eu_stubbed_printf_0("Warning: Running Sequence's data disappear!\n");
|
||||
note->parentLayer->enabled = FALSE; // is 0x48, should be 0x44
|
||||
note->parentLayer->finished = TRUE;
|
||||
note->parentLayer->enabled = false; // is 0x48, should be 0x44
|
||||
note->parentLayer->finished = true;
|
||||
}
|
||||
note_disable(note);
|
||||
audio_list_remove(¬e->listItem);
|
||||
@@ -380,7 +380,7 @@ void *alloc_bank_or_seq(struct SoundMultiPool *arg0, s32 arg1, s32 size, s32 arg
|
||||
pool = &arg0->temporary.pool;
|
||||
if (tp->entries[tp->nextSide].id != (s8)-1) {
|
||||
table[tp->entries[tp->nextSide].id] = SOUND_LOAD_STATUS_NOT_LOADED;
|
||||
if (isSound == TRUE) {
|
||||
if (isSound == true) {
|
||||
discard_bank(tp->entries[tp->nextSide].id);
|
||||
}
|
||||
}
|
||||
|
||||
+9
-9
@@ -164,7 +164,7 @@ void decrease_sample_dma_ttls() {
|
||||
}
|
||||
|
||||
void *dma_sample_data(uintptr_t devAddr, u32 size, s32 arg2, u8 *dmaIndexRef) {
|
||||
s32 hasDma = FALSE;
|
||||
s32 hasDma = false;
|
||||
struct SharedDma *dma;
|
||||
uintptr_t dmaDevAddr;
|
||||
u32 transfer;
|
||||
@@ -199,7 +199,7 @@ void *dma_sample_data(uintptr_t devAddr, u32 size, s32 arg2, u8 *dmaIndexRef) {
|
||||
// TTL 60 is pretty large.
|
||||
dmaIndex = sSampleDmaReuseQueue2[sSampleDmaReuseQueueTail2++];
|
||||
dma = &sSampleDmas[dmaIndex];
|
||||
hasDma = TRUE;
|
||||
hasDma = true;
|
||||
}
|
||||
} else {
|
||||
dma = &sSampleDmas[*dmaIndexRef];
|
||||
@@ -231,7 +231,7 @@ void *dma_sample_data(uintptr_t devAddr, u32 size, s32 arg2, u8 *dmaIndexRef) {
|
||||
// be empty, since TTL 2 is so small.
|
||||
dmaIndex = sSampleDmaReuseQueue1[sSampleDmaReuseQueueTail1++];
|
||||
dma = &sSampleDmas[dmaIndex];
|
||||
hasDma = TRUE;
|
||||
hasDma = true;
|
||||
}
|
||||
|
||||
transfer = dma->bufSize;
|
||||
@@ -539,7 +539,7 @@ struct AudioBank *bank_load_async(s32 bankId, s32 arg1, struct SequencePlayer *s
|
||||
seqPlayer->bankDmaRemaining = alloc;
|
||||
if (1) { }
|
||||
osCreateMesgQueue(&seqPlayer->bankDmaMesgQueue, &seqPlayer->bankDmaMesg, 1);
|
||||
seqPlayer->bankDmaInProgress = TRUE;
|
||||
seqPlayer->bankDmaInProgress = true;
|
||||
audio_dma_partial_copy_async(&seqPlayer->bankDmaCurrDevAddr, &seqPlayer->bankDmaCurrMemAddr, &seqPlayer->bankDmaRemaining, &seqPlayer->bankDmaMesgQueue, &seqPlayer->bankDmaIoMesg);
|
||||
if (gBankLoadStatus[bankId] != 5) {
|
||||
gBankLoadStatus[bankId] = 1;
|
||||
@@ -590,7 +590,7 @@ void *sequence_dma_async(s32 seqId, s32 arg1, struct SequencePlayer *seqPlayer)
|
||||
audio_dma_copy_immediate(seqData, ptr, 0x00000040U);
|
||||
mesgQueue = &seqPlayer->seqDmaMesgQueue;
|
||||
osCreateMesgQueue(mesgQueue, &seqPlayer->seqDmaMesg, 1);
|
||||
seqPlayer->seqDmaInProgress = TRUE;
|
||||
seqPlayer->seqDmaInProgress = true;
|
||||
audio_dma_copy_async((uintptr_t) (seqData + 0x40), (u8*) ptr + 0x40, seqLength - 0x40, mesgQueue, &seqPlayer->seqDmaIoMesg);
|
||||
if (gSeqLoadStatus[seqId] != 5) {
|
||||
gSeqLoadStatus[seqId] = 1;
|
||||
@@ -612,7 +612,7 @@ u8 get_missing_bank(u32 seqId, s32 *nonNullCount, s32 *nullCount) {
|
||||
for (i = gAlBankSets[offset++], ret = 0; i != 0; i--) {
|
||||
bankId = gAlBankSets[offset++];
|
||||
|
||||
if (IS_BANK_LOAD_COMPLETE(bankId) == TRUE) {
|
||||
if (IS_BANK_LOAD_COMPLETE(bankId) == true) {
|
||||
temp = get_bank_or_seq(1, 2, bankId);
|
||||
} else {
|
||||
temp = NULL;
|
||||
@@ -639,7 +639,7 @@ struct AudioBank *load_banks_immediate(s32 seqId, u8 *outDefaultBank) {
|
||||
for (i = gAlBankSets[offset++]; i != 0; i--) {
|
||||
bankId = gAlBankSets[offset++];
|
||||
|
||||
if (IS_BANK_LOAD_COMPLETE(bankId) == TRUE) {
|
||||
if (IS_BANK_LOAD_COMPLETE(bankId) == true) {
|
||||
ret = get_bank_or_seq(1, 2, bankId);
|
||||
} else {
|
||||
ret = NULL;
|
||||
@@ -672,7 +672,7 @@ void preload_sequence(u32 seqId, u8 preloadMask) {
|
||||
|
||||
if (preloadMask & PRELOAD_SEQUENCE) {
|
||||
//! @bug should be IS_SEQ_LOAD_COMPLETE
|
||||
if (IS_BANK_LOAD_COMPLETE(seqId) == TRUE) {
|
||||
if (IS_BANK_LOAD_COMPLETE(seqId) == true) {
|
||||
sequenceData = get_bank_or_seq(0, 2, seqId);
|
||||
} else {
|
||||
sequenceData = NULL;
|
||||
@@ -753,7 +753,7 @@ void load_sequence_internal(u32 player, u32 seqId, s32 loadAsync) {
|
||||
init_sequence_player(player);
|
||||
seqPlayer->scriptState.depth = 0;
|
||||
seqPlayer->delay = 0;
|
||||
seqPlayer->enabled = TRUE;
|
||||
seqPlayer->enabled = true;
|
||||
seqPlayer->seqData = sequenceData;
|
||||
seqPlayer->scriptState.pc = sequenceData;
|
||||
}
|
||||
|
||||
+21
-21
@@ -28,26 +28,26 @@ void note_set_vel_pan_reverb(struct Note *note, f32 velocity, u8 pan, u8 reverbV
|
||||
|
||||
sub->headsetPanLeft = gHeadsetPanQuantization[smallPanIndex];
|
||||
sub->headsetPanRight = gHeadsetPanQuantization[ARRAY_COUNT(gHeadsetPanQuantization) - 1 - smallPanIndex];
|
||||
sub->stereoStrongRight = FALSE;
|
||||
sub->stereoStrongLeft = FALSE;
|
||||
sub->usesHeadsetPanEffects = TRUE;
|
||||
sub->stereoStrongRight = false;
|
||||
sub->stereoStrongLeft = false;
|
||||
sub->usesHeadsetPanEffects = true;
|
||||
|
||||
volLeft = gHeadsetPanVolume[pan];
|
||||
volRight = gHeadsetPanVolume[127 - pan];
|
||||
} else if (sub->stereoHeadsetEffects && gAudioLibSoundMode == SOUND_MODE_STEREO) {
|
||||
strongRight = FALSE;
|
||||
strongLeft = FALSE;
|
||||
strongRight = false;
|
||||
strongLeft = false;
|
||||
sub->headsetPanRight = 0;
|
||||
sub->headsetPanLeft = 0;
|
||||
|
||||
sub->usesHeadsetPanEffects = FALSE;
|
||||
sub->usesHeadsetPanEffects = false;
|
||||
|
||||
volLeft = gStereoPanVolume[pan];
|
||||
volRight = gStereoPanVolume[127 - pan];
|
||||
if (pan < 0x20) {
|
||||
strongLeft = TRUE;
|
||||
strongLeft = true;
|
||||
} else if (pan > 0x60) {
|
||||
strongRight = TRUE;
|
||||
strongRight = true;
|
||||
}
|
||||
|
||||
sub->stereoStrongRight = strongRight;
|
||||
@@ -76,14 +76,14 @@ void note_set_vel_pan_reverb(struct Note *note, f32 velocity, u8 pan, u8 reverbV
|
||||
//! @bug for the change to UQ0.7, the if statement should also have been changed accordingly
|
||||
if (sub->reverbVol != reverbVol) {
|
||||
sub->reverbVol = reverbVol;
|
||||
sub->envMixerNeedsInit = TRUE;
|
||||
sub->envMixerNeedsInit = true;
|
||||
return;
|
||||
}
|
||||
|
||||
if (sub->needsInit) {
|
||||
sub->envMixerNeedsInit = TRUE;
|
||||
sub->envMixerNeedsInit = true;
|
||||
} else {
|
||||
sub->envMixerNeedsInit = FALSE;
|
||||
sub->envMixerNeedsInit = false;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -130,7 +130,7 @@ struct AudioBankSound *instrument_get_audio_bank_sound(struct Instrument *instru
|
||||
struct Instrument *get_instrument_inner(s32 bankId, s32 instId) {
|
||||
struct Instrument *inst;
|
||||
|
||||
if (IS_BANK_LOAD_COMPLETE(bankId) == FALSE) {
|
||||
if (IS_BANK_LOAD_COMPLETE(bankId) == false) {
|
||||
stubbed_printf("Audio: voiceman: No bank error %d\n", bankId);
|
||||
gAudioErrorFlags = bankId + 0x10000000;
|
||||
return NULL;
|
||||
@@ -155,7 +155,7 @@ struct Instrument *get_instrument_inner(s32 bankId, s32 instId) {
|
||||
struct Drum *get_drum(s32 bankId, s32 drumId) {
|
||||
struct Drum *drum;
|
||||
|
||||
if (IS_BANK_LOAD_COMPLETE(bankId) == FALSE) {
|
||||
if (IS_BANK_LOAD_COMPLETE(bankId) == false) {
|
||||
stubbed_printf("Audio: voiceman: No bank error %d\n", bankId);
|
||||
gAudioErrorFlags = bankId + 0x10000000;
|
||||
return NULL;
|
||||
@@ -196,16 +196,16 @@ void note_init(struct Note *note) {
|
||||
}
|
||||
|
||||
void note_disable(struct Note *note) {
|
||||
if (note->noteSubEu.needsInit == TRUE) {
|
||||
note->noteSubEu.needsInit = FALSE;
|
||||
if (note->noteSubEu.needsInit == true) {
|
||||
note->noteSubEu.needsInit = false;
|
||||
} else {
|
||||
note_set_vel_pan_reverb(note, 0, 0x40, 0);
|
||||
}
|
||||
note->priority = NOTE_PRIORITY_DISABLED;
|
||||
note->parentLayer = NO_LAYER;
|
||||
note->prevParentLayer = NO_LAYER;
|
||||
note->noteSubEu.enabled = FALSE;
|
||||
note->noteSubEu.finished = FALSE;
|
||||
note->noteSubEu.enabled = false;
|
||||
note->noteSubEu.finished = false;
|
||||
}
|
||||
|
||||
void process_notes(void) {
|
||||
@@ -625,7 +625,7 @@ void note_init_for_layer(struct Note *note, struct SequenceChannelLayer *seqLaye
|
||||
note->prevParentLayer = NO_LAYER;
|
||||
note->parentLayer = seqLayer;
|
||||
note->priority = seqLayer->seqChannel->notePriority;
|
||||
seqLayer->notePropertiesNeedInit = TRUE;
|
||||
seqLayer->notePropertiesNeedInit = true;
|
||||
seqLayer->status = SOUND_LOAD_STATUS_DISCARDABLE; // "loaded"
|
||||
seqLayer->note = note;
|
||||
seqLayer->seqChannel->noteUnused = note;
|
||||
@@ -639,9 +639,9 @@ void note_init_for_layer(struct Note *note, struct SequenceChannelLayer *seqLaye
|
||||
sub->sound.audioBankSound = seqLayer->sound;
|
||||
|
||||
if (instId >= 0x80) {
|
||||
sub->isSyntheticWave = TRUE;
|
||||
sub->isSyntheticWave = true;
|
||||
} else {
|
||||
sub->isSyntheticWave = FALSE;
|
||||
sub->isSyntheticWave = false;
|
||||
}
|
||||
|
||||
if (sub->isSyntheticWave) {
|
||||
@@ -781,7 +781,7 @@ void note_init_all(void) {
|
||||
note->adsrVolScale = 0;
|
||||
note->adsr.state = ADSR_STATE_DISABLED;
|
||||
note->adsr.action = 0;
|
||||
note->vibratoState.active = FALSE;
|
||||
note->vibratoState.active = false;
|
||||
note->portamento.cur = 0.0f;
|
||||
note->portamento.speed = 0.0f;
|
||||
// This only works if NoteSynthesisBuffers are size 0xA0. See internal.h
|
||||
|
||||
+11
-11
@@ -168,7 +168,7 @@ void eu_process_audio_cmd(struct EuAudioCmd *cmd) {
|
||||
break;
|
||||
|
||||
case 0x83:
|
||||
if (gSequencePlayers[cmd->u.s.bankId].enabled != FALSE) {
|
||||
if (gSequencePlayers[cmd->u.s.bankId].enabled != false) {
|
||||
if (cmd->u2.as_s32 == 0) {
|
||||
sequence_player_disable(&gSequencePlayers[cmd->u.s.bankId]);
|
||||
}
|
||||
@@ -184,15 +184,15 @@ void eu_process_audio_cmd(struct EuAudioCmd *cmd) {
|
||||
|
||||
case 0xf1:
|
||||
for (i = 0; i < 4; i++) {
|
||||
gSequencePlayers[i].muted = TRUE;
|
||||
gSequencePlayers[i].recalculateVolume = TRUE;
|
||||
gSequencePlayers[i].muted = true;
|
||||
gSequencePlayers[i].recalculateVolume = true;
|
||||
}
|
||||
break;
|
||||
|
||||
case 0xf2:
|
||||
for (i = 0; i < 4; i++) {
|
||||
gSequencePlayers[i].muted = FALSE;
|
||||
gSequencePlayers[i].recalculateVolume = TRUE;
|
||||
gSequencePlayers[i].muted = false;
|
||||
gSequencePlayers[i].recalculateVolume = true;
|
||||
}
|
||||
break;
|
||||
case 0xF3:
|
||||
@@ -297,7 +297,7 @@ void func_800CBCB0(u32 arg0) {
|
||||
switch (cmd->u.s.op) {
|
||||
case 0x41:
|
||||
seqPlayer->fadeVolumeScale = cmd->u2.as_f32;
|
||||
seqPlayer->recalculateVolume = TRUE;
|
||||
seqPlayer->recalculateVolume = true;
|
||||
break;
|
||||
|
||||
case 0x47:
|
||||
@@ -313,25 +313,25 @@ void func_800CBCB0(u32 arg0) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
else if (seqPlayer->enabled != FALSE && cmd->u.s.arg2 < 0x10) {
|
||||
else if (seqPlayer->enabled != false && cmd->u.s.arg2 < 0x10) {
|
||||
chan = seqPlayer->channels[cmd->u.s.arg2];
|
||||
if (IS_SEQUENCE_CHANNEL_VALID(chan)) {
|
||||
switch (cmd->u.s.op) {
|
||||
case 1:
|
||||
chan->volumeScale = cmd->u2.as_f32;
|
||||
chan->changes.as_bitfields.volume = TRUE;
|
||||
chan->changes.as_bitfields.volume = true;
|
||||
break;
|
||||
case 2:
|
||||
chan->volume = cmd->u2.as_f32;
|
||||
chan->changes.as_bitfields.volume = TRUE;
|
||||
chan->changes.as_bitfields.volume = true;
|
||||
break;
|
||||
case 3:
|
||||
chan->newPan = cmd->u2.as_s8;
|
||||
chan->changes.as_bitfields.pan = TRUE;
|
||||
chan->changes.as_bitfields.pan = true;
|
||||
break;
|
||||
case 4:
|
||||
chan->freqScale = cmd->u2.as_f32;
|
||||
chan->changes.as_bitfields.freqScale = TRUE;
|
||||
chan->changes.as_bitfields.freqScale = true;
|
||||
break;
|
||||
case 5:
|
||||
chan->reverbVol = cmd->u2.as_s8;
|
||||
|
||||
+64
-64
@@ -52,14 +52,14 @@ char seqplayer_unused_string25[] = "Group:Undefined Command\n";
|
||||
void sequence_channel_init(struct SequenceChannel *seqChannel) {
|
||||
s32 i;
|
||||
|
||||
seqChannel->enabled = FALSE;
|
||||
seqChannel->finished = FALSE;
|
||||
seqChannel->stopScript = FALSE;
|
||||
seqChannel->stopSomething2 = FALSE;
|
||||
seqChannel->hasInstrument = FALSE;
|
||||
seqChannel->stereoHeadsetEffects = FALSE;
|
||||
seqChannel->enabled = false;
|
||||
seqChannel->finished = false;
|
||||
seqChannel->stopScript = false;
|
||||
seqChannel->stopSomething2 = false;
|
||||
seqChannel->hasInstrument = false;
|
||||
seqChannel->stereoHeadsetEffects = false;
|
||||
seqChannel->transposition = 0;
|
||||
seqChannel->largeNotes = FALSE;
|
||||
seqChannel->largeNotes = false;
|
||||
seqChannel->bookOffset = 0;
|
||||
seqChannel->changes.as_u8 = 0xff;
|
||||
seqChannel->scriptState.depth = 0;
|
||||
@@ -86,7 +86,7 @@ void sequence_channel_init(struct SequenceChannel *seqChannel) {
|
||||
for (i = 0; i < 8; i++) {
|
||||
seqChannel->soundScriptIO[i] = -1;
|
||||
}
|
||||
seqChannel->unused = FALSE;
|
||||
seqChannel->unused = false;
|
||||
init_note_lists(&seqChannel->notePool);
|
||||
}
|
||||
|
||||
@@ -109,11 +109,11 @@ s32 seq_channel_set_layer(struct SequenceChannel *seqChannel, s32 layerIndex) {
|
||||
layer->seqChannel = seqChannel;
|
||||
layer->adsr = seqChannel->adsr;
|
||||
layer->adsr.releaseRate = 0;
|
||||
layer->enabled = TRUE;
|
||||
layer->stopSomething = FALSE;
|
||||
layer->continuousNotes = FALSE;
|
||||
layer->finished = FALSE;
|
||||
layer->ignoreDrumPan = FALSE;
|
||||
layer->enabled = true;
|
||||
layer->stopSomething = false;
|
||||
layer->continuousNotes = false;
|
||||
layer->finished = false;
|
||||
layer->ignoreDrumPan = false;
|
||||
layer->portamento.mode = 0;
|
||||
layer->scriptState.depth = 0;
|
||||
layer->status = SOUND_LOAD_STATUS_NOT_LOADED;
|
||||
@@ -134,8 +134,8 @@ s32 seq_channel_set_layer(struct SequenceChannel *seqChannel, s32 layerIndex) {
|
||||
void seq_channel_layer_disable(struct SequenceChannelLayer *layer) {
|
||||
if (layer != NULL) {
|
||||
seq_channel_layer_note_decay(layer);
|
||||
layer->enabled = FALSE;
|
||||
layer->finished = TRUE;
|
||||
layer->enabled = false;
|
||||
layer->finished = true;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -156,8 +156,8 @@ void sequence_channel_disable(struct SequenceChannel *seqChannel) {
|
||||
}
|
||||
|
||||
note_pool_clear(&seqChannel->notePool);
|
||||
seqChannel->enabled = FALSE;
|
||||
seqChannel->finished = TRUE;
|
||||
seqChannel->enabled = false;
|
||||
seqChannel->finished = true;
|
||||
}
|
||||
|
||||
struct SequenceChannel *allocate_sequence_channel(void) {
|
||||
@@ -177,12 +177,12 @@ void sequence_player_init_channels(struct SequencePlayer *seqPlayer, u16 channel
|
||||
for (i = 0; i < CHANNELS_MAX; i++) {
|
||||
if (channelBits & 1) {
|
||||
seqChannel = seqPlayer->channels[i];
|
||||
if (IS_SEQUENCE_CHANNEL_VALID(seqChannel) == TRUE && seqChannel->seqPlayer == seqPlayer) {
|
||||
if (IS_SEQUENCE_CHANNEL_VALID(seqChannel) == true && seqChannel->seqPlayer == seqPlayer) {
|
||||
sequence_channel_disable(seqChannel);
|
||||
seqChannel->seqPlayer = NULL;
|
||||
}
|
||||
seqChannel = allocate_sequence_channel();
|
||||
if (IS_SEQUENCE_CHANNEL_VALID(seqChannel) == FALSE) {
|
||||
if (IS_SEQUENCE_CHANNEL_VALID(seqChannel) == false) {
|
||||
//eu_stubbed_printf_0("Audio:Track:Warning: No Free Notetrack\n");
|
||||
gAudioErrorFlags = i + 0x10000;
|
||||
seqPlayer->channels[i] = seqChannel;
|
||||
@@ -207,7 +207,7 @@ void sequence_player_disable_channels(struct SequencePlayer *seqPlayer, u16 chan
|
||||
for (i = 0; i < CHANNELS_MAX; i++) {
|
||||
if (channelBits & 1) {
|
||||
seqChannel = seqPlayer->channels[i];
|
||||
if (IS_SEQUENCE_CHANNEL_VALID(seqChannel) == TRUE) {
|
||||
if (IS_SEQUENCE_CHANNEL_VALID(seqChannel) == true) {
|
||||
if (seqChannel->seqPlayer == seqPlayer) {
|
||||
sequence_channel_disable(seqChannel);
|
||||
seqChannel->seqPlayer = NULL;
|
||||
@@ -225,12 +225,12 @@ void sequence_player_disable_channels(struct SequencePlayer *seqPlayer, u16 chan
|
||||
void sequence_channel_enable(struct SequencePlayer *seqPlayer, u8 channelIndex, void *script) {
|
||||
struct SequenceChannel *seqChannel = seqPlayer->channels[channelIndex];
|
||||
s32 i;
|
||||
if (IS_SEQUENCE_CHANNEL_VALID(seqChannel) == FALSE) {
|
||||
if (IS_SEQUENCE_CHANNEL_VALID(seqChannel) == false) {
|
||||
//stubbed_printf("SEQID %d,BANKID %d\n", seqPlayer->seqId, seqPlayer->defaultBank[0]);
|
||||
//stubbed_printf("ERR:SUBTRACK %d NOT ALLOCATED\n", channelIndex);
|
||||
} else {
|
||||
seqChannel->enabled = TRUE;
|
||||
seqChannel->finished = FALSE;
|
||||
seqChannel->enabled = true;
|
||||
seqChannel->finished = false;
|
||||
seqChannel->scriptState.depth = 0;
|
||||
seqChannel->scriptState.pc = script;
|
||||
seqChannel->delay = 0;
|
||||
@@ -245,8 +245,8 @@ void sequence_channel_enable(struct SequencePlayer *seqPlayer, u8 channelIndex,
|
||||
void sequence_player_disable(struct SequencePlayer *seqPlayer) {
|
||||
sequence_player_disable_channels(seqPlayer, 0xffff);
|
||||
note_pool_clear(&seqPlayer->notePool);
|
||||
seqPlayer->finished = TRUE;
|
||||
seqPlayer->enabled = FALSE;
|
||||
seqPlayer->finished = true;
|
||||
seqPlayer->enabled = false;
|
||||
|
||||
if (IS_SEQ_LOAD_COMPLETE(seqPlayer->seqId) && gSeqLoadStatus[seqPlayer->seqId] != 5) {
|
||||
gSeqLoadStatus[seqPlayer->seqId] = SOUND_LOAD_STATUS_DISCARDABLE;
|
||||
@@ -347,8 +347,8 @@ void seq_channel_layer_process_script(struct SequenceChannelLayer *layer) {
|
||||
f32 temp_f12;
|
||||
f32 temp_f2;
|
||||
|
||||
sameSound = TRUE;
|
||||
if (layer->enabled == FALSE) {
|
||||
sameSound = true;
|
||||
if (layer->enabled == false) {
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -356,7 +356,7 @@ void seq_channel_layer_process_script(struct SequenceChannelLayer *layer) {
|
||||
layer->delay--;
|
||||
if (!layer->stopSomething && layer->delay <= layer->duration) {
|
||||
seq_channel_layer_note_decay(layer);
|
||||
layer->stopSomething = TRUE;
|
||||
layer->stopSomething = true;
|
||||
}
|
||||
return;
|
||||
}
|
||||
@@ -379,7 +379,7 @@ void seq_channel_layer_process_script(struct SequenceChannelLayer *layer) {
|
||||
|
||||
seqChannel = layer->seqChannel;
|
||||
seqPlayer = seqChannel->seqPlayer;
|
||||
layer->notePropertiesNeedInit = TRUE;
|
||||
layer->notePropertiesNeedInit = true;
|
||||
|
||||
for (;;) {
|
||||
state = &layer->scriptState;
|
||||
@@ -455,9 +455,9 @@ void seq_channel_layer_process_script(struct SequenceChannelLayer *layer) {
|
||||
case 0xc4: // layer_somethingon
|
||||
case 0xc5: // layer_somethingoff
|
||||
if (cmd == 0xc4) {
|
||||
layer->continuousNotes = TRUE;
|
||||
layer->continuousNotes = true;
|
||||
} else {
|
||||
layer->continuousNotes = FALSE;
|
||||
layer->continuousNotes = false;
|
||||
}
|
||||
seq_channel_layer_note_decay(layer);
|
||||
break;
|
||||
@@ -525,7 +525,7 @@ void seq_channel_layer_process_script(struct SequenceChannelLayer *layer) {
|
||||
break;
|
||||
|
||||
case 0xcc:
|
||||
layer->ignoreDrumPan = TRUE;
|
||||
layer->ignoreDrumPan = true;
|
||||
break;
|
||||
|
||||
default:
|
||||
@@ -545,11 +545,11 @@ void seq_channel_layer_process_script(struct SequenceChannelLayer *layer) {
|
||||
|
||||
if (cmd == 0xc0) { // layer_delay
|
||||
layer->delay = m64_read_compressed_u16(state);
|
||||
layer->stopSomething = TRUE;
|
||||
layer->stopSomething = true;
|
||||
} else {
|
||||
layer->stopSomething = FALSE;
|
||||
layer->stopSomething = false;
|
||||
|
||||
if (seqChannel->largeNotes == TRUE) {
|
||||
if (seqChannel->largeNotes == true) {
|
||||
switch (cmd & 0xc0) {
|
||||
case 0x00: // layer_note0 (play percentage, velocity, duration)
|
||||
sp3A = m64_read_compressed_u16(state);
|
||||
@@ -602,7 +602,7 @@ void seq_channel_layer_process_script(struct SequenceChannelLayer *layer) {
|
||||
if ((seqPlayer->muted && (seqChannel->muteBehavior & MUTE_BEHAVIOR_STOP_NOTES) != 0)
|
||||
|| seqChannel->stopSomething2
|
||||
) {
|
||||
layer->stopSomething = TRUE;
|
||||
layer->stopSomething = true;
|
||||
|
||||
} else {
|
||||
s32 temp = layer->instOrWave;
|
||||
@@ -617,7 +617,7 @@ void seq_channel_layer_process_script(struct SequenceChannelLayer *layer) {
|
||||
|
||||
drum = get_drum(seqChannel->bankId, cmd);
|
||||
if (drum == NULL) {
|
||||
layer->stopSomething = TRUE;
|
||||
layer->stopSomething = true;
|
||||
layer->delayUnused = layer->delay;
|
||||
return;
|
||||
} else {
|
||||
@@ -634,7 +634,7 @@ void seq_channel_layer_process_script(struct SequenceChannelLayer *layer) {
|
||||
cmd += seqPlayer->transposition + seqChannel->transposition + layer->transposition;
|
||||
|
||||
if (cmd >= 0x80) {
|
||||
layer->stopSomething = TRUE;
|
||||
layer->stopSomething = true;
|
||||
} else {
|
||||
if (layer->instOrWave == 0xffu) {
|
||||
instrument = seqChannel->instrument;
|
||||
@@ -706,30 +706,30 @@ void seq_channel_layer_process_script(struct SequenceChannelLayer *layer) {
|
||||
}
|
||||
}
|
||||
|
||||
if (layer->stopSomething == TRUE) {
|
||||
if (layer->stopSomething == true) {
|
||||
if (layer->note != NULL || layer->continuousNotes) {
|
||||
seq_channel_layer_note_decay(layer);
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
cmd = FALSE;
|
||||
cmd = false;
|
||||
if (!layer->continuousNotes) {
|
||||
cmd = TRUE;
|
||||
cmd = true;
|
||||
} else if (layer->note == NULL || layer->status == SOUND_LOAD_STATUS_NOT_LOADED) {
|
||||
cmd = TRUE;
|
||||
} else if (sameSound == FALSE) {
|
||||
cmd = true;
|
||||
} else if (sameSound == false) {
|
||||
seq_channel_layer_note_decay(layer);
|
||||
cmd = TRUE;
|
||||
cmd = true;
|
||||
}
|
||||
else if (layer != layer->note->parentLayer) {
|
||||
cmd = TRUE;
|
||||
cmd = true;
|
||||
}
|
||||
else if (layer->sound == NULL) {
|
||||
init_synthetic_wave(layer->note, layer);
|
||||
}
|
||||
|
||||
if (cmd != FALSE) {
|
||||
if (cmd != false) {
|
||||
layer->note = alloc_note(layer);
|
||||
}
|
||||
|
||||
@@ -764,11 +764,11 @@ void set_instrument(struct SequenceChannel *seqChannel, u8 instId) {
|
||||
} else {
|
||||
if ((seqChannel->instOrWave = get_instrument(seqChannel, instId, &seqChannel->instrument, &seqChannel->adsr)) == 0)
|
||||
{
|
||||
seqChannel->hasInstrument = FALSE;
|
||||
seqChannel->hasInstrument = false;
|
||||
return;
|
||||
}
|
||||
}
|
||||
seqChannel->hasInstrument = TRUE;
|
||||
seqChannel->hasInstrument = true;
|
||||
}
|
||||
|
||||
void sequence_channel_set_volume(struct SequenceChannel *seqChannel, u8 volume) {
|
||||
@@ -1215,16 +1215,16 @@ void sequence_player_process_sequence(struct SequencePlayer *seqPlayer) {
|
||||
struct M64ScriptState *state;
|
||||
s32 temp32;
|
||||
|
||||
if (seqPlayer->enabled == FALSE) {
|
||||
if (seqPlayer->enabled == false) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (seqPlayer->bankDmaInProgress == TRUE) {
|
||||
if (seqPlayer->bankDmaInProgress == true) {
|
||||
if (osRecvMesg(&seqPlayer->bankDmaMesgQueue, NULL, 0) == -1) {
|
||||
return;
|
||||
}
|
||||
if (seqPlayer->bankDmaRemaining == 0) {
|
||||
seqPlayer->bankDmaInProgress = FALSE;
|
||||
seqPlayer->bankDmaInProgress = false;
|
||||
func_800BB584(seqPlayer->loadingBankId);
|
||||
if (gBankLoadStatus[seqPlayer->loadingBankId] != 5) {
|
||||
gBankLoadStatus[seqPlayer->loadingBankId] = 2;
|
||||
@@ -1237,11 +1237,11 @@ void sequence_player_process_sequence(struct SequencePlayer *seqPlayer) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (seqPlayer->seqDmaInProgress == TRUE) {
|
||||
if (seqPlayer->seqDmaInProgress == true) {
|
||||
if (osRecvMesg(&seqPlayer->seqDmaMesgQueue, NULL, 0) == -1) {
|
||||
return;
|
||||
}
|
||||
seqPlayer->seqDmaInProgress = FALSE;
|
||||
seqPlayer->seqDmaInProgress = false;
|
||||
if (gSeqLoadStatus[seqPlayer->seqId] != 5) {
|
||||
gSeqLoadStatus[seqPlayer->seqId] = 2;
|
||||
}
|
||||
@@ -1249,9 +1249,9 @@ void sequence_player_process_sequence(struct SequencePlayer *seqPlayer) {
|
||||
|
||||
// If discarded, bail out.
|
||||
temp32 = 2; // I beg your pardon?
|
||||
if (IS_SEQ_LOAD_COMPLETE(seqPlayer->seqId) == FALSE
|
||||
if (IS_SEQ_LOAD_COMPLETE(seqPlayer->seqId) == false
|
||||
|| (
|
||||
IS_BANK_LOAD_COMPLETE(seqPlayer->defaultBank[0]) == FALSE)) {
|
||||
IS_BANK_LOAD_COMPLETE(seqPlayer->defaultBank[0]) == false)) {
|
||||
sequence_player_disable(seqPlayer);
|
||||
return;
|
||||
}
|
||||
@@ -1457,7 +1457,7 @@ void sequence_player_process_sequence(struct SequencePlayer *seqPlayer) {
|
||||
break;
|
||||
|
||||
case 0xd4: // seq_mute
|
||||
seqPlayer->muted = TRUE;
|
||||
seqPlayer->muted = true;
|
||||
break;
|
||||
|
||||
case 0xd3: // seq_setmutebhv
|
||||
@@ -1534,7 +1534,7 @@ void sequence_player_process_sequence(struct SequencePlayer *seqPlayer) {
|
||||
}
|
||||
|
||||
for (i = 0; i < CHANNELS_MAX; i++) {
|
||||
if (IS_SEQUENCE_CHANNEL_VALID(seqPlayer->channels[i]) == TRUE) {
|
||||
if (IS_SEQUENCE_CHANNEL_VALID(seqPlayer->channels[i]) == true) {
|
||||
sequence_channel_process_script(seqPlayer->channels[i]);
|
||||
}
|
||||
}
|
||||
@@ -1543,7 +1543,7 @@ void sequence_player_process_sequence(struct SequencePlayer *seqPlayer) {
|
||||
void process_sequences(UNUSED s32 iterationsRemaining) {
|
||||
s32 i;
|
||||
for (i = 0; i < SEQUENCE_PLAYERS; i++) {
|
||||
if (gSequencePlayers[i].enabled == TRUE) {
|
||||
if (gSequencePlayers[i].enabled == true) {
|
||||
sequence_player_process_sequence(&gSequencePlayers[i]);
|
||||
sequence_player_process_sound(&gSequencePlayers[i]);
|
||||
}
|
||||
@@ -1577,7 +1577,7 @@ void init_sequence_players(void) {
|
||||
|
||||
for (i = 0; i < ARRAY_COUNT(gSequenceChannels); i++) {
|
||||
gSequenceChannels[i].seqPlayer = NULL;
|
||||
gSequenceChannels[i].enabled = FALSE;
|
||||
gSequenceChannels[i].enabled = false;
|
||||
/**
|
||||
* @bug Size of wrong array. Zeroes out second half of gSequenceChannels[0],
|
||||
* all of gSequenceChannels[1..31], and part of gSequenceLayers[0].
|
||||
@@ -1597,7 +1597,7 @@ void init_sequence_players(void) {
|
||||
|
||||
for (i = 0; i < ARRAY_COUNT(gSequenceLayers); i++) {
|
||||
gSequenceLayers[i].seqChannel = NULL;
|
||||
gSequenceLayers[i].enabled = FALSE;
|
||||
gSequenceLayers[i].enabled = false;
|
||||
}
|
||||
|
||||
for (i = 0; i < SEQUENCE_PLAYERS; i++) {
|
||||
@@ -1607,10 +1607,10 @@ void init_sequence_players(void) {
|
||||
|
||||
gSequencePlayers[i].seqVariationEu[0] = -1;
|
||||
gSequencePlayers[i].muteBehavior = MUTE_BEHAVIOR_STOP_SCRIPT | MUTE_BEHAVIOR_STOP_NOTES | MUTE_BEHAVIOR_SOFTEN;
|
||||
gSequencePlayers[i].enabled = FALSE;
|
||||
gSequencePlayers[i].muted = FALSE;
|
||||
gSequencePlayers[i].bankDmaInProgress = FALSE;
|
||||
gSequencePlayers[i].seqDmaInProgress = FALSE;
|
||||
gSequencePlayers[i].enabled = false;
|
||||
gSequencePlayers[i].muted = false;
|
||||
gSequencePlayers[i].bankDmaInProgress = false;
|
||||
gSequencePlayers[i].seqDmaInProgress = false;
|
||||
init_note_lists(&gSequencePlayers[i].notePool);
|
||||
init_sequence_player(i);
|
||||
}
|
||||
|
||||
+15
-15
@@ -127,7 +127,7 @@ void func_800B6FB4(s32 updateIndexStart, s32 noteIndex) {
|
||||
|
||||
for (i = updateIndexStart + 1; i < gAudioBufferParameters.updatesPerFrame; i++) {
|
||||
if (!gNoteSubsEu[gMaxSimultaneousNotes * i + noteIndex].needsInit) {
|
||||
gNoteSubsEu[gMaxSimultaneousNotes * i + noteIndex].enabled = FALSE;
|
||||
gNoteSubsEu[gMaxSimultaneousNotes * i + noteIndex].enabled = false;
|
||||
} else {
|
||||
break;
|
||||
}
|
||||
@@ -144,9 +144,9 @@ void synthesis_load_note_subs_eu(s32 updateIndex) {
|
||||
dest = &gNoteSubsEu[gMaxSimultaneousNotes * updateIndex + i];
|
||||
if (src->enabled) {
|
||||
*dest = *src;
|
||||
src->needsInit = FALSE;
|
||||
src->needsInit = false;
|
||||
} else {
|
||||
dest->enabled = FALSE;
|
||||
dest->enabled = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -307,7 +307,7 @@ Acmd *synthesis_do_one_audio_update(s16 *aiBuf, s32 bufLen, Acmd *acmd, s32 upda
|
||||
}
|
||||
for (; i < notePos; i++) {
|
||||
temp = updateIndex * gMaxSimultaneousNotes;
|
||||
if (IS_BANK_LOAD_COMPLETE(gNoteSubsEu[temp + noteIndices[i]].bankId) == TRUE) {
|
||||
if (IS_BANK_LOAD_COMPLETE(gNoteSubsEu[temp + noteIndices[i]].bankId) == true) {
|
||||
acmd = synthesis_process_note(noteIndices[i],
|
||||
&gNoteSubsEu[temp + noteIndices[i]],
|
||||
&gNotes[noteIndices[i]].synthesisState,
|
||||
@@ -376,7 +376,7 @@ Acmd *synthesis_process_note(s32 noteIndex, struct NoteSubEu *noteSubEu, struct
|
||||
curLoadedBook = NULL;
|
||||
note = &gNotes[noteIndex];
|
||||
flags = 0;
|
||||
if (noteSubEu->needsInit == TRUE) {
|
||||
if (noteSubEu->needsInit == true) {
|
||||
flags = A_INIT;
|
||||
synthesisState->restart = 0;
|
||||
synthesisState->samplePosInt = 0;
|
||||
@@ -432,13 +432,13 @@ Acmd *synthesis_process_note(s32 noteIndex, struct NoteSubEu *noteSubEu, struct
|
||||
s32 samplesRemaining;
|
||||
s32 s1;
|
||||
|
||||
noteFinished = FALSE;
|
||||
restart = FALSE;
|
||||
noteFinished = false;
|
||||
restart = false;
|
||||
|
||||
s3 = synthesisState->samplePosInt & 0xF;
|
||||
samplesRemaining = endPos - synthesisState->samplePosInt;
|
||||
nSamplesToProcess = samplesLenAdjusted - nAdpcmSamplesProcessed;
|
||||
if ((s3 == 0) && (synthesisState->restart == FALSE)) {
|
||||
if ((s3 == 0) && (synthesisState->restart == false)) {
|
||||
s3 = 16;
|
||||
}
|
||||
|
||||
@@ -483,11 +483,11 @@ Acmd *synthesis_process_note(s32 noteIndex, struct NoteSubEu *noteSubEu, struct
|
||||
var_t2 = 0;
|
||||
}
|
||||
|
||||
if (synthesisState->restart != FALSE) {
|
||||
if (synthesisState->restart != false) {
|
||||
aSetLoop(cmd++, VIRTUAL_TO_PHYSICAL2(audioBookSample->loop->state));
|
||||
|
||||
flags = A_LOOP;
|
||||
synthesisState->restart = FALSE;
|
||||
synthesisState->restart = false;
|
||||
}
|
||||
nSamplesInThisIteration = (s1 + a1) - var_s6;
|
||||
s5Aligned = ALIGN(s4 + 16, 4);
|
||||
@@ -539,7 +539,7 @@ Acmd *synthesis_process_note(s32 noteIndex, struct NoteSubEu *noteSubEu, struct
|
||||
func_800B6FB4(updateIndex, noteIndex);
|
||||
} else {
|
||||
if (restart) {
|
||||
synthesisState->restart = TRUE;
|
||||
synthesisState->restart = true;
|
||||
synthesisState->samplePosInt = loopInfo->start;
|
||||
} else {
|
||||
synthesisState->samplePosInt += nSamplesToProcess;
|
||||
@@ -557,7 +557,7 @@ Acmd *synthesis_process_note(s32 noteIndex, struct NoteSubEu *noteSubEu, struct
|
||||
aDownsampleHalf(cmd++, ALIGN(samplesLenAdjusted / 2, 3), 0x1A0 + spFC, DMEM_ADDR_RESAMPLED);
|
||||
resampledTempLen = samplesLenAdjusted;
|
||||
noteSamplesDmemAddrBeforeResampling = DMEM_ADDR_RESAMPLED;
|
||||
if (noteSubEu->finished != FALSE) {
|
||||
if (noteSubEu->finished != false) {
|
||||
aClearBuffer(cmd++, noteSamplesDmemAddrBeforeResampling + resampledTempLen, samplesLenAdjusted + 0x10);
|
||||
}
|
||||
break;
|
||||
@@ -568,15 +568,15 @@ Acmd *synthesis_process_note(s32 noteIndex, struct NoteSubEu *noteSubEu, struct
|
||||
}
|
||||
break;
|
||||
}
|
||||
if (noteSubEu->finished != FALSE) {
|
||||
if (noteSubEu->finished != false) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
flags = 0;
|
||||
if (noteSubEu->needsInit == TRUE) {
|
||||
if (noteSubEu->needsInit == true) {
|
||||
flags = A_INIT;
|
||||
noteSubEu->needsInit = FALSE;
|
||||
noteSubEu->needsInit = false;
|
||||
}
|
||||
|
||||
cmd = final_resample(cmd, synthesisState, inBuf * 2, resamplingRateFixedPoint, noteSamplesDmemAddrBeforeResampling, flags);
|
||||
|
||||
+11
-11
@@ -1199,19 +1199,19 @@ s32 func_800088D8(s32 playerId, s16 arg1, s16 arg2) {
|
||||
D_80163128[playerId] = -1;
|
||||
D_80163150[playerId] = -1;
|
||||
if (gModeSelection == 1) {
|
||||
return TRUE;
|
||||
return true;
|
||||
}
|
||||
if (arg1 < 0) {
|
||||
return TRUE;
|
||||
return true;
|
||||
} else if (arg1 >= 4) {
|
||||
arg1 = 3;
|
||||
}
|
||||
if (D_80163330[playerId] == 1) {
|
||||
return TRUE;
|
||||
return true;
|
||||
}
|
||||
player = &gPlayers[playerId];
|
||||
if (player->type & 0x4000) {
|
||||
return TRUE;
|
||||
return true;
|
||||
}
|
||||
arg1_times_8 = arg1 * 8;
|
||||
temp_a3 = &D_800DCBB4[gCurrentCourseId][arg1_times_8];
|
||||
@@ -1228,9 +1228,9 @@ s32 func_800088D8(s32 playerId, s16 arg1, s16 arg2) {
|
||||
D_80163150[playerId] = temp_a3[0];
|
||||
}
|
||||
if (D_80163150[playerId] < temp_a2 && player->unk_094 / 18.0f * 216.0f >= 20.0f) {
|
||||
return FALSE;
|
||||
return false;
|
||||
}
|
||||
return TRUE;
|
||||
return true;
|
||||
}
|
||||
progress = D_80164450[playerId] - D_80164450[D_80163478];
|
||||
rank = gGPCurrentRaceRankByPlayerId[2 + (D_80163478 * 4)];
|
||||
@@ -1248,9 +1248,9 @@ s32 func_800088D8(s32 playerId, s16 arg1, s16 arg2) {
|
||||
}
|
||||
D_80163150[playerId] = (gCCSelection + 1) * var_a0_2;
|
||||
if (D_80163150[playerId] < progress && player->unk_094 / 18.0f * 216.0f >= 20.0f) {
|
||||
return FALSE;
|
||||
return false;
|
||||
}
|
||||
return TRUE;
|
||||
return true;
|
||||
} else {
|
||||
var_a1_4 = D_80164450[(s16) *D_80163344] - D_80164450[playerId];
|
||||
if (var_a1_4 < 0) {
|
||||
@@ -1274,7 +1274,7 @@ s32 func_800088D8(s32 playerId, s16 arg1, s16 arg2) {
|
||||
}
|
||||
D_80164538[playerId] = var_t1;
|
||||
if (var_t1 < 0 || var_t1 >= 8) {
|
||||
return FALSE;
|
||||
return false;
|
||||
}
|
||||
if (arg1_times_8 < 24) {
|
||||
temp_a3 = &temp_a3[var_t1];
|
||||
@@ -1285,9 +1285,9 @@ s32 func_800088D8(s32 playerId, s16 arg1, s16 arg2) {
|
||||
}
|
||||
D_80163128[playerId] = var_a1_4;
|
||||
if (D_80163150[playerId] < var_a1_4) {
|
||||
return TRUE;
|
||||
return true;
|
||||
}
|
||||
return FALSE;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
#else
|
||||
|
||||
+26
-26
@@ -971,7 +971,7 @@ void func_80058F78(void) {
|
||||
render_hud_timer(PLAYER_ONE);
|
||||
draw_simplified_lap_count(PLAYER_ONE);
|
||||
func_8004EB38(0);
|
||||
if (D_801657E6 != FALSE) {
|
||||
if (D_801657E6 != false) {
|
||||
func_8004ED40(0);
|
||||
}
|
||||
}
|
||||
@@ -1044,10 +1044,10 @@ void func_800591B4(void) {
|
||||
|
||||
if (gIsHUDVisible != 0) {
|
||||
if (D_801657D8 == 0) {
|
||||
if (D_801657F0 != FALSE) {
|
||||
if (D_801657F0 != false) {
|
||||
func_800514BC();
|
||||
}
|
||||
if ((!gDemoMode) && (D_801657E8 != FALSE)) {
|
||||
if ((!gDemoMode) && (D_801657E8 != false)) {
|
||||
if (D_80165800[0] != 0) {
|
||||
func_8004EE54(0);
|
||||
if (gModeSelection != BATTLE) {
|
||||
@@ -1224,7 +1224,7 @@ void randomize_seed_from_controller(s32 arg0) {
|
||||
}
|
||||
|
||||
void func_8005994C(void) {
|
||||
D_8018D214 = TRUE;
|
||||
D_8018D214 = true;
|
||||
}
|
||||
|
||||
void func_8005995C(void) {
|
||||
@@ -1258,7 +1258,7 @@ void func_80059A88(s32 playerId) {
|
||||
void func_80059AC8(void) {
|
||||
s32 i;
|
||||
|
||||
if (gIsGamePaused == FALSE) {
|
||||
if (gIsGamePaused == false) {
|
||||
func_8008C1D8(&D_80165678);
|
||||
gRaceFrameCounter++;
|
||||
for (i = 0; i < NUM_PLAYERS; i++) {
|
||||
@@ -1320,7 +1320,7 @@ void func_80059D00(void) {
|
||||
switch (gScreenModeSelection) {
|
||||
case SCREEN_MODE_1P:
|
||||
randomize_seed_from_controller(PLAYER_ONE);
|
||||
if (D_8018D214 == FALSE) {
|
||||
if (D_8018D214 == false) {
|
||||
func_80059820(PLAYER_ONE);
|
||||
func_8005B914();
|
||||
if (!gDemoMode) {
|
||||
@@ -1420,7 +1420,7 @@ void func_8005A070(void) {
|
||||
gMatrixHudCount = 0;
|
||||
D_801655C0 = 0;
|
||||
func_80041D34();
|
||||
if (gIsGamePaused == FALSE) {
|
||||
if (gIsGamePaused == false) {
|
||||
func_8005C728();
|
||||
if (gGamestate == ENDING) {
|
||||
func_80086604();
|
||||
@@ -1497,7 +1497,7 @@ void func_8005A380(void) {
|
||||
}
|
||||
|
||||
void func_8005A3C0(void) {
|
||||
bool b = FALSE;
|
||||
bool b = false;
|
||||
if ((gGamestate != ENDING) && (gGamestate != CREDITS_SEQUENCE) && !D_8018D204) {
|
||||
switch (gPlayerCountSelection1) {
|
||||
case 1:
|
||||
@@ -1506,38 +1506,38 @@ void func_8005A3C0(void) {
|
||||
D_801657E4 = 0;
|
||||
}
|
||||
if (D_801657E4 == 2) {
|
||||
D_801657E8 = FALSE;
|
||||
D_801657E6 = FALSE;
|
||||
D_801657F0 = TRUE;
|
||||
D_801657E8 = false;
|
||||
D_801657E6 = false;
|
||||
D_801657F0 = true;
|
||||
} else if (D_801657E4 == 1) {
|
||||
D_801657E8 = FALSE;
|
||||
D_801657E6 = TRUE;
|
||||
D_801657F0 = FALSE;
|
||||
D_801657E8 = false;
|
||||
D_801657E6 = true;
|
||||
D_801657F0 = false;
|
||||
} else {
|
||||
D_801657E8 = TRUE;
|
||||
D_801657E6 = FALSE;
|
||||
D_801657F0 = FALSE;
|
||||
D_801657E8 = true;
|
||||
D_801657E6 = false;
|
||||
D_801657F0 = false;
|
||||
}
|
||||
b = TRUE;
|
||||
b = true;
|
||||
}
|
||||
break;
|
||||
case 2:
|
||||
if (gModeSelection != BATTLE) {
|
||||
if (gControllerOne->buttonPressed & R_CBUTTONS) {
|
||||
D_80165800[0] = (D_80165800[0] + 1) & 1;
|
||||
b = TRUE;
|
||||
b = true;
|
||||
}
|
||||
if (gControllerTwo->buttonPressed & R_CBUTTONS) {
|
||||
D_80165800[1] = (D_80165800[1] + 1) & 1;
|
||||
b = TRUE;
|
||||
b = true;
|
||||
}
|
||||
if (D_80165800[0] && D_80165800[1]) {
|
||||
D_801657F0 = FALSE;
|
||||
D_801657F0 = false;
|
||||
} else {
|
||||
D_801657F0 = TRUE;
|
||||
D_801657F0 = true;
|
||||
}
|
||||
if (gDemoMode) {
|
||||
D_801657F0 = FALSE;
|
||||
D_801657F0 = false;
|
||||
}
|
||||
}
|
||||
break;
|
||||
@@ -1549,7 +1549,7 @@ void func_8005A3C0(void) {
|
||||
D_801657F0 = (D_801657F0 + 1) & 1;
|
||||
}
|
||||
D_801657E4 = (D_801657E4 + 1) & 1;
|
||||
b = TRUE;
|
||||
b = true;
|
||||
}
|
||||
break;
|
||||
case 4:
|
||||
@@ -1563,7 +1563,7 @@ void func_8005A3C0(void) {
|
||||
if (gModeSelection != BATTLE) {
|
||||
D_801657F0 = (D_801657F0 + 1) & 1;
|
||||
}
|
||||
b = TRUE;
|
||||
b = true;
|
||||
}
|
||||
break;
|
||||
}
|
||||
@@ -1664,7 +1664,7 @@ void func_8005A99C(void) {
|
||||
func_8005AA34();
|
||||
}
|
||||
if (gPlayerCountSelection1 == 3) {
|
||||
D_801657E8 = TRUE;
|
||||
D_801657E8 = true;
|
||||
}
|
||||
gIsHUDVisible = (s32) 1;
|
||||
D_8018D170 = (s32) 1;
|
||||
|
||||
+38
-38
@@ -45,9 +45,9 @@ void func_80086F60(s32 objectIndex) {
|
||||
}
|
||||
|
||||
bool func_80086FA4(s32 objectIndex) {
|
||||
bool ret = FALSE;
|
||||
bool ret = false;
|
||||
if (gObjectList[objectIndex].unk_0AE == 0) {
|
||||
ret = TRUE;
|
||||
ret = true;
|
||||
}
|
||||
return ret;
|
||||
}
|
||||
@@ -66,7 +66,7 @@ s32 func_80087060(s32 objectIndex, s32 arg1) {
|
||||
s32 sp1C;
|
||||
|
||||
sp1C = 0;
|
||||
if (is_obj_index_flag_status_inactive(objectIndex, 8) != FALSE) {
|
||||
if (is_obj_index_flag_status_inactive(objectIndex, 8) != false) {
|
||||
set_object_flag_status_true(objectIndex, 8);
|
||||
gObjectList[objectIndex].unk_0B0 = arg1;
|
||||
}
|
||||
@@ -82,7 +82,7 @@ s32 func_80087104(s32 objectIndex, u16 arg1) {
|
||||
s32 sp24;
|
||||
|
||||
sp24 = 0;
|
||||
if (is_obj_index_flag_status_inactive(objectIndex, 8) != FALSE) {
|
||||
if (is_obj_index_flag_status_inactive(objectIndex, 8) != false) {
|
||||
set_object_flag_status_true(objectIndex, 8);
|
||||
gObjectList[objectIndex].unk_0B0 = random_int(arg1);
|
||||
}
|
||||
@@ -98,7 +98,7 @@ s32 func_800871AC(s32 objectIndex, s32 arg1) {
|
||||
s32 sp24;
|
||||
|
||||
sp24 = 0;
|
||||
if (is_obj_index_flag_status_inactive(objectIndex, 8) != FALSE) {
|
||||
if (is_obj_index_flag_status_inactive(objectIndex, 8) != false) {
|
||||
set_object_flag_status_true(objectIndex, 8);
|
||||
gObjectList[objectIndex].unk_0B0 = (s16) arg1;
|
||||
}
|
||||
@@ -218,7 +218,7 @@ s32 func_8008789C(s32 objectIndex, s32 arg1) {
|
||||
s32 sp24;
|
||||
|
||||
sp24 = 0;
|
||||
if (is_obj_index_flag_status_inactive(objectIndex, 8) != FALSE) {
|
||||
if (is_obj_index_flag_status_inactive(objectIndex, 8) != false) {
|
||||
set_object_flag_status_true(objectIndex, 8);
|
||||
func_8008751C(objectIndex);
|
||||
gObjectList[objectIndex].unk_0B0 = arg1;
|
||||
@@ -237,7 +237,7 @@ s32 func_80087954(s32 objectIndex, s32 arg1) {
|
||||
s32 sp24;
|
||||
|
||||
sp24 = 0;
|
||||
if (is_obj_index_flag_status_inactive(objectIndex, 8) != FALSE) {
|
||||
if (is_obj_index_flag_status_inactive(objectIndex, 8) != false) {
|
||||
set_object_flag_status_true(objectIndex, 8);
|
||||
func_80087620(objectIndex);
|
||||
gObjectList[objectIndex].unk_0B0 = arg1;
|
||||
@@ -258,8 +258,8 @@ bool func_80087A0C(s32 objectIndex, s16 arg1, s16 arg2, s16 arg3, s16 arg4) {
|
||||
s16 temp_v0;
|
||||
bool sp2C;
|
||||
|
||||
sp2C = FALSE;
|
||||
if (is_obj_index_flag_status_inactive(objectIndex, 8) != FALSE) {
|
||||
sp2C = false;
|
||||
if (is_obj_index_flag_status_inactive(objectIndex, 8) != false) {
|
||||
set_object_flag_status_true(objectIndex, 8);
|
||||
temp_v0 = arg2 - arg1;
|
||||
temp_a0 = arg4 - arg3;
|
||||
@@ -272,7 +272,7 @@ bool func_80087A0C(s32 objectIndex, s16 arg1, s16 arg2, s16 arg3, s16 arg4) {
|
||||
gObjectList[objectIndex].unk_0B0--;
|
||||
if (gObjectList[objectIndex].unk_0B0 < 0) {
|
||||
set_object_flag_status_false(objectIndex, 8);
|
||||
sp2C = TRUE;
|
||||
sp2C = true;
|
||||
} else {
|
||||
object_add_velocity_offset_xz(objectIndex);
|
||||
}
|
||||
@@ -283,7 +283,7 @@ s32 func_80087B84(s32 objectIndex, f32 arg1, f32 arg2) {
|
||||
s32 sp24;
|
||||
|
||||
sp24 = 0;
|
||||
if (is_obj_index_flag_status_inactive(objectIndex, 8) != FALSE) {
|
||||
if (is_obj_index_flag_status_inactive(objectIndex, 8) != false) {
|
||||
set_object_flag_status_true(objectIndex, 8);
|
||||
gObjectList[objectIndex].velocity[1] = -arg1;
|
||||
}
|
||||
@@ -300,7 +300,7 @@ s32 func_80087C48(s32 objectIndex, f32 arg1, f32 arg2, s32 arg3) {
|
||||
s32 sp24;
|
||||
|
||||
sp24 = 0;
|
||||
if (is_obj_index_flag_status_inactive(objectIndex, 8) != FALSE) {
|
||||
if (is_obj_index_flag_status_inactive(objectIndex, 8) != false) {
|
||||
set_object_flag_status_true(objectIndex, 8);
|
||||
gObjectList[objectIndex].velocity[1] = arg1;
|
||||
gObjectList[objectIndex].unk_0B0 = (s16) arg3;
|
||||
@@ -340,7 +340,7 @@ bool func_80087E08(s32 objectIndex, f32 arg1, f32 arg2, f32 arg3, s16 arg4, s32
|
||||
bool sp2C;
|
||||
UNUSED s32 pad;
|
||||
|
||||
sp2C = FALSE;
|
||||
sp2C = false;
|
||||
if (is_obj_index_flag_status_inactive(objectIndex, 8) != 0) {
|
||||
set_object_flag_status_true(objectIndex, 8);
|
||||
gObjectList[objectIndex].offset[2] = 0.0f;
|
||||
@@ -356,7 +356,7 @@ bool func_80087E08(s32 objectIndex, f32 arg1, f32 arg2, f32 arg3, s16 arg4, s32
|
||||
if (gObjectList[objectIndex].unk_0B0 < 0) {
|
||||
set_object_flag_status_false(objectIndex, 8);
|
||||
func_80086FD4(objectIndex);
|
||||
sp2C = TRUE;
|
||||
sp2C = true;
|
||||
} else {
|
||||
gObjectList[objectIndex].velocity[1] -= arg2;
|
||||
object_add_velocity_offset_xyz(objectIndex);
|
||||
@@ -665,11 +665,11 @@ bool is_within_horizontal_distance_of_player(s32 objectIndex, Player *player, f3
|
||||
f32 y;
|
||||
bool var_v1;
|
||||
|
||||
var_v1 = FALSE;
|
||||
var_v1 = false;
|
||||
x = gObjectList[objectIndex].pos[0] - player->pos[0];
|
||||
y = gObjectList[objectIndex].pos[2] - player->pos[2];
|
||||
if (((x * x) + (y * y)) <= (distance * distance)) {
|
||||
var_v1 = TRUE;
|
||||
var_v1 = true;
|
||||
}
|
||||
return var_v1;
|
||||
}
|
||||
@@ -690,12 +690,12 @@ bool is_in_bounds_to_player(s32 objectIndex, Player *player, f32 distance_min, f
|
||||
f32 z;
|
||||
bool var_v1;
|
||||
|
||||
var_v1 = FALSE;
|
||||
var_v1 = false;
|
||||
x = gObjectList[objectIndex].pos[0] - player->pos[0];
|
||||
z = gObjectList[objectIndex].pos[2] - player->pos[2];
|
||||
distance = (x * x) + (z * z);
|
||||
if (((distance_min * distance_min) <= distance) && (distance <= (distance_max * distance_max))) {
|
||||
var_v1 = TRUE;
|
||||
var_v1 = true;
|
||||
}
|
||||
return var_v1;
|
||||
}
|
||||
@@ -715,12 +715,12 @@ bool is_within_distance_to_player(s32 objectIndex, Player *player, f32 distance)
|
||||
f32 y;
|
||||
bool var_v1;
|
||||
|
||||
var_v1 = FALSE;
|
||||
var_v1 = false;
|
||||
x = gObjectList[objectIndex].pos[0] - player->pos[0];
|
||||
y = gObjectList[objectIndex].pos[1] - player->pos[1];
|
||||
z = gObjectList[objectIndex].pos[2] - player->pos[2];
|
||||
if (((x * x) + (y * y) + (z * z)) <= (distance * distance)) {
|
||||
var_v1 = TRUE;
|
||||
var_v1 = true;
|
||||
}
|
||||
return var_v1;
|
||||
}
|
||||
@@ -739,11 +739,11 @@ bool is_within_horizontal_distance_to_camera(s32 objectIndex, Camera *camera, f3
|
||||
f32 y;
|
||||
bool var_v1;
|
||||
|
||||
var_v1 = FALSE;
|
||||
var_v1 = false;
|
||||
x = gObjectList[objectIndex].pos[0] - camera->pos[0];
|
||||
y = gObjectList[objectIndex].pos[2] - camera->pos[2];
|
||||
if (((x * x) + (y * y)) <= (distance * distance)) {
|
||||
var_v1 = TRUE;
|
||||
var_v1 = true;
|
||||
}
|
||||
return var_v1;
|
||||
}
|
||||
@@ -763,12 +763,12 @@ UNUSED bool is_within_bounds_to_camera(s32 objectIndex, Camera *camera, f32 dist
|
||||
f32 z;
|
||||
bool var_v1;
|
||||
|
||||
var_v1 = FALSE;
|
||||
var_v1 = false;
|
||||
x = gObjectList[objectIndex].pos[0] - camera->pos[0];
|
||||
z = gObjectList[objectIndex].pos[2] - camera->pos[2];
|
||||
distance = (x * x) + (z * z);
|
||||
if (((distance_min * distance_min) <= distance) && (distance <= (distance_max * distance_max))) {
|
||||
var_v1 = TRUE;
|
||||
var_v1 = true;
|
||||
}
|
||||
return var_v1;
|
||||
}
|
||||
@@ -787,12 +787,12 @@ UNUSED bool is_within_distance_to_camera(s32 objectIndex, Camera *camera, f32 di
|
||||
f32 y;
|
||||
bool var_v1;
|
||||
|
||||
var_v1 = FALSE;
|
||||
var_v1 = false;
|
||||
x = gObjectList[objectIndex].pos[0] - camera->pos[0];
|
||||
y = gObjectList[objectIndex].pos[1] - camera->pos[1];
|
||||
z = gObjectList[objectIndex].pos[2] - camera->pos[2];
|
||||
if (((x * x) + (y * y) + (z * z)) <= (distance * distance)) {
|
||||
var_v1 = TRUE;
|
||||
var_v1 = true;
|
||||
}
|
||||
return var_v1;
|
||||
}
|
||||
@@ -811,12 +811,12 @@ bool has_collided_horizontally_with_player(s32 objectIndex, Player *player) {
|
||||
f32 z;
|
||||
bool var_v1;
|
||||
|
||||
var_v1 = FALSE;
|
||||
var_v1 = false;
|
||||
x = gObjectList[objectIndex].pos[0] - player->pos[0];
|
||||
z = gObjectList[objectIndex].pos[2] - player->pos[2];
|
||||
distance = gObjectList[objectIndex].boundingBoxSize + player->boundingBoxSize;
|
||||
if (((x * x) + (z * z)) <= (distance * distance)) {
|
||||
var_v1 = TRUE;
|
||||
var_v1 = true;
|
||||
}
|
||||
return var_v1;
|
||||
}
|
||||
@@ -836,13 +836,13 @@ bool has_collided_with_player(s32 objectIndex, Player *player) {
|
||||
f32 y;
|
||||
bool var_v1;
|
||||
|
||||
var_v1 = FALSE;
|
||||
var_v1 = false;
|
||||
x = gObjectList[objectIndex].pos[0] - player->pos[0];
|
||||
y = gObjectList[objectIndex].pos[1] - player->pos[1];
|
||||
z = gObjectList[objectIndex].pos[2] - player->pos[2];
|
||||
distance = gObjectList[objectIndex].boundingBoxSize + player->boundingBoxSize;
|
||||
if (((x * x) + (y * y) + (z * z)) <= (distance * distance)) {
|
||||
var_v1 = TRUE;
|
||||
var_v1 = true;
|
||||
}
|
||||
return var_v1;
|
||||
}
|
||||
@@ -859,10 +859,10 @@ UNUSED bool has_collided_with_player_1d(s32 objectIndex, Player *player, f32 dis
|
||||
f32 x;
|
||||
bool var_v1;
|
||||
|
||||
var_v1 = FALSE;
|
||||
var_v1 = false;
|
||||
x = gObjectList[objectIndex].pos[1] - player->pos[1];
|
||||
if ((x * x) <= (distance * distance)) {
|
||||
var_v1 = TRUE;
|
||||
var_v1 = true;
|
||||
}
|
||||
return var_v1;
|
||||
}
|
||||
@@ -883,7 +883,7 @@ bool has_collided_with_player_and_within_height(s32 objectIndex, Player *player,
|
||||
f32 y;
|
||||
bool var_v1;
|
||||
|
||||
var_v1 = FALSE;
|
||||
var_v1 = false;
|
||||
x = gObjectList[objectIndex].pos[0] - player->pos[0];
|
||||
y = gObjectList[objectIndex].pos[1] - player->pos[1];
|
||||
z = gObjectList[objectIndex].pos[2] - player->pos[2];
|
||||
@@ -893,7 +893,7 @@ bool has_collided_with_player_and_within_height(s32 objectIndex, Player *player,
|
||||
y = -y;
|
||||
}
|
||||
if ((((x * x) + (z * z)) <= (distance * distance)) && (y <= distance_y)) {
|
||||
var_v1 = TRUE;
|
||||
var_v1 = true;
|
||||
}
|
||||
return var_v1;
|
||||
}
|
||||
@@ -914,13 +914,13 @@ UNUSED bool func_80088F94(s32 objectIndex, Player *player, f32 arg2) {
|
||||
bool var_v1;
|
||||
|
||||
distance = gObjectList[objectIndex].pos[1] - player->unk_074;
|
||||
var_v1 = FALSE;
|
||||
var_v1 = false;
|
||||
// abs(distance)
|
||||
if (distance < 0.0f) {
|
||||
distance = -distance;
|
||||
}
|
||||
if (distance <= arg2) {
|
||||
var_v1 = TRUE;
|
||||
var_v1 = true;
|
||||
}
|
||||
return var_v1;
|
||||
}
|
||||
@@ -1266,10 +1266,10 @@ bool is_object_visible_on_camera(s32 objectIndex, Camera *camera, u16 angle) {
|
||||
u16 temp_t2;
|
||||
s32 var_t0;
|
||||
|
||||
var_t0 = FALSE;
|
||||
var_t0 = false;
|
||||
temp_t2 = (get_angle_between_xy(camera->pos[0], gObjectList[objectIndex].pos[0], camera->pos[2], gObjectList[objectIndex].pos[2]) + ((s32) angle / 2)) - camera->rot[1];
|
||||
if ((temp_t2 >= 0) && (angle >= temp_t2)) {
|
||||
var_t0 = TRUE;
|
||||
var_t0 = true;
|
||||
}
|
||||
return var_t0;
|
||||
}
|
||||
|
||||
+6
-6
@@ -4391,11 +4391,11 @@ Gfx *func_8009B9D0(Gfx *displayListHead, MkTexture *textures) {
|
||||
bool found;
|
||||
s32 index;
|
||||
|
||||
found = FALSE;
|
||||
found = false;
|
||||
for (index = 0; index < D_8018E768_SIZE; index++) {
|
||||
if (D_8018E768[index].textures == segmented_to_virtual_dupe(textures)) {
|
||||
displayList = D_8018E768[index].displayList;
|
||||
found = TRUE;
|
||||
found = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -7993,7 +7993,7 @@ void func_800A5738(struct_8018D9E0_entry *arg0) {
|
||||
void func_800A6034(struct_8018D9E0_entry *arg0) {
|
||||
char *text;
|
||||
|
||||
if (D_801657E8 != TRUE) {
|
||||
if (D_801657E8 != true) {
|
||||
gDPSetPrimColor(gDisplayListHead++, 0, 0, 0x00, 0x00, 0x00, arg0->unk1C);
|
||||
text = gCupNames[D_800DC540];
|
||||
set_text_color(TEXT_BLUE_GREEN_RED_CYCLE_2);
|
||||
@@ -10004,7 +10004,7 @@ struct_8018D9E0_entry *func_800AAE68(void) {
|
||||
}
|
||||
|
||||
// Something VERY wrong has occurred
|
||||
while(TRUE);
|
||||
while(true);
|
||||
escape:
|
||||
return entry;
|
||||
}
|
||||
@@ -10024,7 +10024,7 @@ struct_8018D9E0_entry *func_800AAEB4(s32 arg0) {
|
||||
}
|
||||
|
||||
// Something VERY wrong has occurred
|
||||
while(TRUE);
|
||||
while(true);
|
||||
escape:
|
||||
return entry;
|
||||
}
|
||||
@@ -10048,7 +10048,7 @@ struct_8018D9E0_entry *find_8018D9E0_entry_dupe(s32 arg0) {
|
||||
}
|
||||
|
||||
// Something VERY wrong has occurred
|
||||
while(TRUE);
|
||||
while(true);
|
||||
escape:
|
||||
return entry;
|
||||
}
|
||||
|
||||
+2
-2
@@ -203,7 +203,7 @@ void thread9_crash_screen(UNUSED void *arg0)
|
||||
osSetEventMesg(10, &D_80162D40, (OSMesg) 16);
|
||||
sButtonSequenceIndex = 0;
|
||||
|
||||
while (TRUE) {
|
||||
while (true) {
|
||||
osRecvMesg(&D_80162D40, &mesg, 1);
|
||||
thread = get_faulted_thread();
|
||||
|
||||
@@ -212,7 +212,7 @@ void thread9_crash_screen(UNUSED void *arg0)
|
||||
if (sCounter == 0) {
|
||||
crash_screen_draw_square(pFramebuffer);
|
||||
#ifndef DEBUG
|
||||
while(TRUE)
|
||||
while(true)
|
||||
{
|
||||
read_controllers();
|
||||
|
||||
|
||||
@@ -215,6 +215,6 @@ void crash_screen_draw(OSThread* thread) {
|
||||
crash_screen_print_float_reg(120, 210, 26, &tc->fp26.f.f_even);
|
||||
crash_screen_print_float_reg(210, 210, 28, &tc->fp28.f.f_even);
|
||||
crash_screen_print_float_reg(30, 220, 30, &tc->fp30.f.f_even);
|
||||
osViBlack(FALSE);
|
||||
osViBlack(false);
|
||||
osViSwapBuffer(pFramebuffer);
|
||||
}
|
||||
|
||||
+13
-13
@@ -311,7 +311,7 @@ void func_8008C73C(Player *player, s8 arg1) {
|
||||
D_80165190[3][arg1] = 1;
|
||||
D_80165280[arg1] = player->currentSpeed;
|
||||
gTimerBoostTripleACombo[arg1] = 0;
|
||||
gIsPlayerTripleAButtonCombo[arg1] = FALSE;
|
||||
gIsPlayerTripleAButtonCombo[arg1] = false;
|
||||
gCountASwitch[arg1] = 0;
|
||||
gFrameSinceLastACombo[arg1] = 0;
|
||||
D_8018D920[arg1] = 0;
|
||||
@@ -340,7 +340,7 @@ void func_8008C8C4(Player* player, s8 playerId) {
|
||||
|
||||
player->unk_046 &= 0xFFBF;
|
||||
|
||||
if ((gIsPlayerTripleAButtonCombo[playerId] == TRUE) && ((player->type & PLAYER_HUMAN) == PLAYER_HUMAN)) {
|
||||
if ((gIsPlayerTripleAButtonCombo[playerId] == true) && ((player->type & PLAYER_HUMAN) == PLAYER_HUMAN)) {
|
||||
player->currentSpeed = (f32) (player->currentSpeed + 100.0f);
|
||||
}
|
||||
if ((gModeSelection == VERSUS) && ((player->type & PLAYER_KART_AI) == PLAYER_KART_AI) && (!gDemoMode) && ((player->unk_0CA & 2) == 0) && (gGPCurrentRaceRankByPlayerId[playerId] != 0)) {
|
||||
@@ -394,7 +394,7 @@ void func_8008C9EC(Player *player, s8 arg1) {
|
||||
}
|
||||
}
|
||||
}
|
||||
if ((gIsPlayerTripleAButtonCombo[arg1] == TRUE) && ((player->type & PLAYER_HUMAN) == PLAYER_HUMAN)) {
|
||||
if ((gIsPlayerTripleAButtonCombo[arg1] == true) && ((player->type & PLAYER_HUMAN) == PLAYER_HUMAN)) {
|
||||
gTimerBoostTripleACombo[arg1] = 0x00000078;
|
||||
if (player->currentSpeed <= 90.0f) {
|
||||
player->currentSpeed = 90.0f;
|
||||
@@ -985,7 +985,7 @@ void func_8008E4A4(Player* player, s8 arg1) {
|
||||
player->unk_042 = 0;
|
||||
player->type &= ~0x80;
|
||||
|
||||
if ((gIsPlayerTripleAButtonCombo[arg1] == TRUE) && ((player->type & PLAYER_HUMAN) == PLAYER_HUMAN)) {
|
||||
if ((gIsPlayerTripleAButtonCombo[arg1] == true) && ((player->type & PLAYER_HUMAN) == PLAYER_HUMAN)) {
|
||||
player->currentSpeed += 100.0f;
|
||||
}
|
||||
if (gModeSelection == BATTLE) {
|
||||
@@ -1008,7 +1008,7 @@ void func_8008E4A4(Player* player, s8 arg1) {
|
||||
if (gModeSelection == BATTLE) {
|
||||
func_8006B8B4(player, arg1);
|
||||
}
|
||||
if ((gIsPlayerTripleAButtonCombo[arg1] == TRUE) && ((player->type & PLAYER_HUMAN) == PLAYER_HUMAN)) {
|
||||
if ((gIsPlayerTripleAButtonCombo[arg1] == true) && ((player->type & PLAYER_HUMAN) == PLAYER_HUMAN)) {
|
||||
player->currentSpeed += 100.0f;
|
||||
}
|
||||
|
||||
@@ -1055,7 +1055,7 @@ void apply_reverse_sound_effect(Player *player, s8 arg1)
|
||||
player->soundEffects &= ~(REVERSE_SOUND_EFFECT | 0x80000);
|
||||
player->unk_0B6 |= 0x40;
|
||||
gTimerBoostTripleACombo[arg1] = 0;
|
||||
gIsPlayerTripleAButtonCombo[arg1] = FALSE;
|
||||
gIsPlayerTripleAButtonCombo[arg1] = false;
|
||||
gCountASwitch[arg1] = 0;
|
||||
gFrameSinceLastACombo[arg1] = 0;
|
||||
}
|
||||
@@ -1096,7 +1096,7 @@ void apply_hit_by_item_effect(Player *player, s8 arg1) {
|
||||
D_80165190[2][arg1] = 1;
|
||||
player->unk_042 = 0;
|
||||
|
||||
if ((gIsPlayerTripleAButtonCombo[arg1] == TRUE) && ((player->type & PLAYER_HUMAN) == PLAYER_HUMAN)) {
|
||||
if ((gIsPlayerTripleAButtonCombo[arg1] == true) && ((player->type & PLAYER_HUMAN) == PLAYER_HUMAN)) {
|
||||
player->currentSpeed += 100.0f;
|
||||
}
|
||||
|
||||
@@ -1116,7 +1116,7 @@ void apply_hit_by_item_effect(Player *player, s8 arg1) {
|
||||
D_80165190[2][arg1] = 1;
|
||||
D_80165190[3][arg1] = 1;
|
||||
player->unk_042 = 0;
|
||||
if ((gIsPlayerTripleAButtonCombo[arg1] == TRUE) && ((player->type & PLAYER_HUMAN) == PLAYER_HUMAN)) {
|
||||
if ((gIsPlayerTripleAButtonCombo[arg1] == true) && ((player->type & PLAYER_HUMAN) == PLAYER_HUMAN)) {
|
||||
player->currentSpeed += 100.0f;
|
||||
}
|
||||
|
||||
@@ -1155,7 +1155,7 @@ void apply_hit_by_item_sound_effect(Player* player, s8 arg1) {
|
||||
player->soundEffects &= ~0x01000002;
|
||||
|
||||
gTimerBoostTripleACombo[arg1] = 0;
|
||||
gIsPlayerTripleAButtonCombo[arg1] = FALSE;
|
||||
gIsPlayerTripleAButtonCombo[arg1] = false;
|
||||
gCountASwitch[arg1] = 0;
|
||||
gFrameSinceLastACombo[arg1] = 0;
|
||||
}
|
||||
@@ -2009,7 +2009,7 @@ void func_80090970(Player *player, s8 playerId, s8 arg2) {
|
||||
bool prevent_item_use(Player *player) {
|
||||
s32 phi_v0 = 0;
|
||||
if ((((((player->unk_0CA & 2) == 2) || ((player->unk_0CA & 8) == 8)) || ((player->type & PLAYER_UNKNOWN_0x40) != 0)) || ((player->type & PLAYER_CINEMATIC_MODE) != 0)) || ((player->type & PLAYER_EXISTS) == 0)) {
|
||||
return TRUE;
|
||||
return true;
|
||||
}
|
||||
|
||||
switch (player->currentItemCopy) {
|
||||
@@ -2018,7 +2018,7 @@ bool prevent_item_use(Player *player) {
|
||||
case ITEM_TRIPLE_MUSHROOM:
|
||||
case ITEM_SUPER_MUSHROOM:
|
||||
if ((player->effects & 8) != 0) {
|
||||
return TRUE;
|
||||
return true;
|
||||
}
|
||||
phi_v0 = EFFECT_BLACKLIST_USE_ITEM;
|
||||
goto prevent_item_use_label;
|
||||
@@ -2029,9 +2029,9 @@ bool prevent_item_use(Player *player) {
|
||||
prevent_item_use_label:
|
||||
default:
|
||||
if ((player->effects & phi_v0) != 0) {
|
||||
return TRUE;
|
||||
return true;
|
||||
}
|
||||
return FALSE;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -359,7 +359,7 @@ void func_80282C40(struct struct_80283430 *arg0, struct struct_80282C40 *arg1, s
|
||||
|
||||
j++;
|
||||
goto dummy_label_888430;
|
||||
while(TRUE) {
|
||||
while(true) {
|
||||
do {
|
||||
|
||||
dummy_label_888430: ;
|
||||
|
||||
+10
-10
@@ -231,7 +231,7 @@ void thread1_idle(void *arg) {
|
||||
osViSetMode(&osViModeTable[OS_VI_MPAL_LAN1]);
|
||||
}
|
||||
#endif
|
||||
osViBlack(TRUE);
|
||||
osViBlack(true);
|
||||
osViSetSpecialFeatures(OS_VI_GAMMA_OFF);
|
||||
osCreatePiManager(OS_PRIORITY_PIMGR, &gPIMesgQueue, gPIMesgBuf, ARRAY_COUNT(gPIMesgBuf));
|
||||
wasSoftReset = (s16) osResetType;
|
||||
@@ -242,7 +242,7 @@ void thread1_idle(void *arg) {
|
||||
osSetThreadPri(NULL, 0);
|
||||
|
||||
// Halt
|
||||
while (TRUE);
|
||||
while (true);
|
||||
}
|
||||
|
||||
void setup_mesg_queues(void) {
|
||||
@@ -307,9 +307,9 @@ void init_controllers(void) {
|
||||
osSetEventMesg(OS_EVENT_SI, &gSIEventMesgQueue, (OSMesg) 0x33333333);
|
||||
osContInit(&gSIEventMesgQueue, &gControllerBits, gControllerStatuses);
|
||||
if ((gControllerBits & 1) == 0) {
|
||||
sIsController1Unplugged = TRUE;
|
||||
sIsController1Unplugged = true;
|
||||
} else {
|
||||
sIsController1Unplugged = FALSE;
|
||||
sIsController1Unplugged = false;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -614,14 +614,14 @@ void race_logic_loop(void) {
|
||||
D_8015F788 = 0;
|
||||
render_player_one_1p_screen();
|
||||
if (!gEnableDebugMode) {
|
||||
D_800DC514 = FALSE;
|
||||
D_800DC514 = false;
|
||||
} else {
|
||||
if (D_800DC514) {
|
||||
|
||||
if ((gControllerOne->buttonPressed & R_TRIG) &&
|
||||
(gControllerOne->button & A_BUTTON) &&
|
||||
(gControllerOne->button & B_BUTTON)) {
|
||||
D_800DC514 = FALSE;
|
||||
D_800DC514 = false;
|
||||
}
|
||||
|
||||
rotY = camera1->rot[1];
|
||||
@@ -642,7 +642,7 @@ void race_logic_loop(void) {
|
||||
if ((gControllerOne->buttonPressed & L_TRIG) &&
|
||||
(gControllerOne->button & A_BUTTON) &&
|
||||
(gControllerOne->button & B_BUTTON)) {
|
||||
D_800DC514 = TRUE;
|
||||
D_800DC514 = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1081,7 +1081,7 @@ void thread3_video(UNUSED void *arg0) {
|
||||
create_thread(&gGameLoopThread, 5, &thread5_game_loop, 0, gGameLoopThreadStack + ARRAY_COUNT(gGameLoopThreadStack), 10);
|
||||
osStartThread(&gGameLoopThread);
|
||||
|
||||
while (TRUE) {
|
||||
while (true) {
|
||||
osRecvMesg(&gIntrMesgQueue, &msg, OS_MESG_BLOCK);
|
||||
switch ((u32) msg) {
|
||||
case MESG_VI_VBLANK:
|
||||
@@ -1190,7 +1190,7 @@ void thread5_game_loop(UNUSED void *arg) {
|
||||
read_controllers();
|
||||
func_800C5CB8();
|
||||
|
||||
while(TRUE) {
|
||||
while(true) {
|
||||
func_800CB2C4();
|
||||
|
||||
// Update the gamestate if it has changed (racing, menus, credits, etc.).
|
||||
@@ -1216,7 +1216,7 @@ void thread4_audio(UNUSED void *arg) {
|
||||
osCreateMesgQueue(&sSoundMesgQueue, sSoundMesgBuf, ARRAY_COUNT(sSoundMesgBuf));
|
||||
set_vblank_handler(1, &sSoundVblankHandler, &sSoundMesgQueue, (OSMesg) 512);
|
||||
|
||||
while (TRUE) {
|
||||
while (true) {
|
||||
OSMesg msg;
|
||||
struct SPTask *spTask;
|
||||
|
||||
|
||||
+4
-4
@@ -30,9 +30,9 @@ UNUSED void operator_xor(s32 *arg0, s32 arg1) {
|
||||
UNUSED bool func_80040E84(s32 *arg0, s32 arg1) {
|
||||
bool phi_v1;
|
||||
|
||||
phi_v1 = FALSE;
|
||||
phi_v1 = false;
|
||||
if ((*arg0 & arg1) != 0) {
|
||||
phi_v1 = TRUE;
|
||||
phi_v1 = true;
|
||||
}
|
||||
return phi_v1;
|
||||
}
|
||||
@@ -455,10 +455,10 @@ bool is_particle_on_screen(Vec3f arg0, Camera *arg1, u16 arg2) {
|
||||
u16 temp_t9;
|
||||
s32 ret;
|
||||
|
||||
ret = FALSE;
|
||||
ret = false;
|
||||
temp_t9 = (get_angle_between_xy(arg1->pos[0], arg0[0], arg1->pos[2], arg0[2]) + (arg2 / 2)) - arg1->rot[1];
|
||||
if ((temp_t9 >= 0) && (arg2 >= temp_t9)) {
|
||||
ret = TRUE;
|
||||
ret = true;
|
||||
}
|
||||
return ret;
|
||||
}
|
||||
|
||||
+22
-22
@@ -240,7 +240,7 @@ void options_menu_act(struct Controller *controller, u16 arg1) {
|
||||
case 0x17:
|
||||
case 0x18:
|
||||
{
|
||||
sp2C = FALSE;
|
||||
sp2C = false;
|
||||
if ((btnAndStick & D_JPAD) && (D_8018EDEC < 0x18)) {
|
||||
D_8018EDEC += 1;
|
||||
play_sound2(SOUND_MENU_CURSOR_MOVE);
|
||||
@@ -248,7 +248,7 @@ void options_menu_act(struct Controller *controller, u16 arg1) {
|
||||
sp38->unk24 += 4.0;
|
||||
}
|
||||
sp38->unk8 = 1;
|
||||
sp2C = TRUE;
|
||||
sp2C = true;
|
||||
}
|
||||
if ((btnAndStick & U_JPAD) && (D_8018EDEC >= 0x16)) {
|
||||
D_8018EDEC -= 1;
|
||||
@@ -256,7 +256,7 @@ void options_menu_act(struct Controller *controller, u16 arg1) {
|
||||
if (sp38->unk24 < 4.2) {
|
||||
sp38->unk24 += 4.0;
|
||||
}
|
||||
sp2C = TRUE;
|
||||
sp2C = true;
|
||||
sp38->unk8 = -1;
|
||||
}
|
||||
if (sp2C && gSoundMode != sp38->cursor) {
|
||||
@@ -1008,7 +1008,7 @@ void splash_menu_act(struct Controller *controller, u16 arg1) {
|
||||
u16 i;
|
||||
s32 sp28;
|
||||
|
||||
sp28 = TRUE;
|
||||
sp28 = true;
|
||||
btnAndStick = controller->buttonPressed | controller->stickPressed;
|
||||
|
||||
if (func_800B4520() == 0) {
|
||||
@@ -1018,7 +1018,7 @@ void splash_menu_act(struct Controller *controller, u16 arg1) {
|
||||
switch (gDebugMenuSelection) {
|
||||
case DEBUG_MENU_DISABLED:
|
||||
{
|
||||
sp28 = FALSE;
|
||||
sp28 = false;
|
||||
if ((gMenuDelayTimer >= 0x2E) && (btnAndStick & (A_BUTTON | START_BUTTON))) {
|
||||
func_8009E1C0();
|
||||
func_800CA330(0x19);
|
||||
@@ -1035,7 +1035,7 @@ void splash_menu_act(struct Controller *controller, u16 arg1) {
|
||||
if (gEnableDebugMode) {
|
||||
gEnableDebugMode = DEBUG_MODE;
|
||||
} else {
|
||||
gEnableDebugMode = TRUE;
|
||||
gEnableDebugMode = true;
|
||||
}
|
||||
}
|
||||
if (btnAndStick & D_JPAD) {
|
||||
@@ -1398,15 +1398,15 @@ void main_menu_act(struct Controller *controller, u16 arg1) {
|
||||
}
|
||||
// L800B3068
|
||||
if (btnAndStick & D_JPAD) {
|
||||
sp24 = FALSE;
|
||||
sp24 = false;
|
||||
if (func_800B555C()) {
|
||||
if (sp28 < D_800F2B60[gPlayerCount + 4][D_800E86AC[gPlayerCount - 1] + 1]) {
|
||||
sp24 = TRUE;
|
||||
sp24 = true;
|
||||
}
|
||||
} else {
|
||||
// L800B30D4
|
||||
if (sp28 < D_800F2B60[gPlayerCount][D_800E86AC[gPlayerCount - 1] + 1]) {
|
||||
sp24 = TRUE;
|
||||
sp24 = true;
|
||||
}
|
||||
}
|
||||
// L800B3110
|
||||
@@ -1500,10 +1500,10 @@ bool is_character_spot_free(s32 gridId) {
|
||||
s32 i;
|
||||
for (i = 0; i < ARRAY_COUNT(gCharacterGridSelections); i++) {
|
||||
if (gridId == gCharacterGridSelections[i]) {
|
||||
return FALSE;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
return TRUE;
|
||||
return true;
|
||||
}
|
||||
|
||||
#ifdef NON_MATCHING
|
||||
@@ -1536,7 +1536,7 @@ void player_select_menu_act(struct Controller *controller, u16 arg1) {
|
||||
// L800B3630
|
||||
if (btnAndStick & B_BUTTON) {
|
||||
if (D_8018EDE8[arg1]) {
|
||||
D_8018EDE8[arg1] = FALSE;
|
||||
D_8018EDE8[arg1] = false;
|
||||
play_sound2(0x49008002);
|
||||
} else {
|
||||
func_8009E208();
|
||||
@@ -1545,15 +1545,15 @@ void player_select_menu_act(struct Controller *controller, u16 arg1) {
|
||||
}
|
||||
// L800B3684
|
||||
if ((btnAndStick & A_BUTTON) && (D_8018EDE8[arg1] == 0)) {
|
||||
D_8018EDE8[arg1] = TRUE;
|
||||
D_8018EDE8[arg1] = true;
|
||||
i = D_800F2BAC[gCharacterGridSelections[arg1] - 1];
|
||||
func_800C90F4(arg1, 0x2900800e + (i << 4));
|
||||
}
|
||||
// L800B36F4
|
||||
selected = FALSE;
|
||||
selected = false;
|
||||
for (i = 0; i < 4; i++) { // for (i = 0; i < ARRAY_COUNT(gCharacterGridSelections); i++) {
|
||||
if ((gCharacterGridSelections[i] != 0) && (D_8018EDE8[i] == 0)) { //(gCharacterGridSelections[i] && D_8018EDE8[i]) {
|
||||
selected = TRUE;
|
||||
selected = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -1669,7 +1669,7 @@ void player_select_menu_act(struct Controller *controller, u16 arg1) {
|
||||
// L800B3AA4
|
||||
if (btnAndStick & B_BUTTON) {
|
||||
D_8018EDEE = 1;
|
||||
D_8018EDE8[arg1] = FALSE;
|
||||
D_8018EDE8[arg1] = false;
|
||||
play_sound2(0x49008002);
|
||||
break;
|
||||
}
|
||||
@@ -1920,7 +1920,7 @@ void func_800B3F74(s32 menuSelection) {
|
||||
} else {
|
||||
gCharacterGridSelections[i] = 0;
|
||||
}
|
||||
D_8018EDE8[i] = FALSE;
|
||||
D_8018EDE8[i] = false;
|
||||
gCharacterSelections[i] = i;
|
||||
}
|
||||
play_sound2(SOUND_MENU_SELECT_PLAYER);
|
||||
@@ -1931,7 +1931,7 @@ void func_800B3F74(s32 menuSelection) {
|
||||
gGamestateNext = 0;
|
||||
func_800C8EAC(2);
|
||||
for (i = 0; i < ARRAY_COUNT(D_8018EDE8); i++) {
|
||||
D_8018EDE8[i] = FALSE;
|
||||
D_8018EDE8[i] = false;
|
||||
}
|
||||
}
|
||||
break;
|
||||
@@ -1941,9 +1941,9 @@ void func_800B3F74(s32 menuSelection) {
|
||||
D_8018EDEE = 3;
|
||||
for (i = 0; i < ARRAY_COUNT(D_8018EDE8); i++) {
|
||||
if (gPlayerCount > i) {
|
||||
D_8018EDE8[i] = TRUE;
|
||||
D_8018EDE8[i] = true;
|
||||
} else {
|
||||
D_8018EDE8[i] = FALSE;
|
||||
D_8018EDE8[i] = false;
|
||||
}
|
||||
}
|
||||
break;
|
||||
@@ -2004,9 +2004,9 @@ void func_800B44BC(void) {
|
||||
bool func_800B4520(void) {
|
||||
|
||||
if ((D_8018E7AC[4] == 2) || (D_8018E7AC[4] == 3) || (D_8018E7AC[4] == 4) || (D_8018E7AC[4] == 7)) {
|
||||
return TRUE;
|
||||
return true;
|
||||
}
|
||||
return FALSE;
|
||||
return false;
|
||||
}
|
||||
|
||||
UNUSED void func_800B4560(s32 arg0, s32 arg1) {
|
||||
|
||||
+1
-1
@@ -47,7 +47,7 @@ s32 _Printf(char *(*prout)(char *, const char *, size_t), char *dst, const char
|
||||
u8 sp4c[0x20]; // probably a buffer?
|
||||
s32 sp48, sp44, sp40, sp3c, sp38, sp34, sp30, sp2c, sp28, sp24;
|
||||
sp78.size = 0;
|
||||
while (TRUE) {
|
||||
while (true) {
|
||||
fmt_ptr = (u8 *) fmt;
|
||||
#ifdef VERSION_SH
|
||||
// new version: don't point fmt_ptr beyond NUL character
|
||||
|
||||
@@ -22,7 +22,7 @@ void __osDevMgrMain(void *args) {
|
||||
mb = NULL;
|
||||
ret = 0;
|
||||
sp34 = (OSMgrArgs *) args;
|
||||
while (TRUE) {
|
||||
while (true) {
|
||||
osRecvMesg(sp34->cmdQueue, (OSMesg) &mb, OS_MESG_BLOCK);
|
||||
if (mb->piHandle != NULL && mb->piHandle->type == 2
|
||||
&& (mb->piHandle->transferInfo.cmdType == 0
|
||||
@@ -41,7 +41,7 @@ void __osDevMgrMain(void *args) {
|
||||
osRecvMesg(sp34->accessQueue, &dummy, OS_MESG_BLOCK);
|
||||
__osResetGlobalIntMask(0x00100401); // remove magic constant!
|
||||
__osEPiRawWriteIo(mb->piHandle, 0x05000510, (sp24->bmCtlShadow | 0x80000000));
|
||||
while (TRUE) {
|
||||
while (true) {
|
||||
osRecvMesg(sp34->eventQueue, &em, OS_MESG_BLOCK);
|
||||
sp30 = osSendMesg(mb->hdr.retQueue, mb, OS_MESG_NOBLOCK);
|
||||
if (sp2c != 1 || mb->piHandle->transferInfo.errStatus != 0) {
|
||||
|
||||
+8
-8
@@ -65,7 +65,7 @@ s32 __osRepairPackId(OSPfs *pfs, __OSPackId *badid, __OSPackId *newid)
|
||||
temp[i] = ~temp[i];
|
||||
}
|
||||
|
||||
ERRCK(__osContRamWrite(pfs->queue, pfs->channel, 0, (u8*)temp, FALSE)); //oddr 0, don't force
|
||||
ERRCK(__osContRamWrite(pfs->queue, pfs->channel, 0, (u8*)temp, false)); //oddr 0, don't force
|
||||
ERRCK(__osContRamRead(pfs->queue, pfs->channel, 0, (u8*)&comp));
|
||||
|
||||
for (i = 0; i < ARRLEN(temp); i++)
|
||||
@@ -102,7 +102,7 @@ s32 __osRepairPackId(OSPfs *pfs, __OSPackId *badid, __OSPackId *newid)
|
||||
index[3] = 6;
|
||||
for (i = 0; i < ARRLEN(index); i++)
|
||||
{
|
||||
ERRCK(__osContRamWrite(pfs->queue, pfs->channel, index[i], (u8*)newid, TRUE));
|
||||
ERRCK(__osContRamWrite(pfs->queue, pfs->channel, index[i], (u8*)newid, true));
|
||||
}
|
||||
ERRCK(__osContRamRead(pfs->queue, pfs->channel, 1, (u8*)temp));
|
||||
for (i = 0; i < ARRLEN(temp); i++)
|
||||
@@ -142,7 +142,7 @@ s32 __osCheckPackId(OSPfs *pfs, __OSPackId *temp)
|
||||
{
|
||||
if (j != i)
|
||||
{
|
||||
ERRCK(__osContRamWrite(pfs->queue, pfs->channel, index[j], (u8*)temp, TRUE));
|
||||
ERRCK(__osContRamWrite(pfs->queue, pfs->channel, index[j], (u8*)temp, true));
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
@@ -250,8 +250,8 @@ s32 __osPfsRWInode(OSPfs *pfs, __OSInode *inode, u8 flag, u8 bank)
|
||||
addr = ((u8 *)inode->inode_page + j * 32);
|
||||
if (flag == PFS_WRITE)
|
||||
{
|
||||
ret = __osContRamWrite(pfs->queue, pfs->channel, pfs->inode_table + bank * 8 + j, addr, FALSE);
|
||||
ret = __osContRamWrite(pfs->queue, pfs->channel, pfs->minode_table + bank * 8 + j, addr, FALSE);
|
||||
ret = __osContRamWrite(pfs->queue, pfs->channel, pfs->inode_table + bank * 8 + j, addr, false);
|
||||
ret = __osContRamWrite(pfs->queue, pfs->channel, pfs->minode_table + bank * 8 + j, addr, false);
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -275,7 +275,7 @@ s32 __osPfsRWInode(OSPfs *pfs, __OSInode *inode, u8 flag, u8 bank)
|
||||
for (j = 0; j < PFS_ONE_PAGE; j++)
|
||||
{
|
||||
addr = ((u8 *)inode->inode_page + j * 32);
|
||||
ret = __osContRamWrite(pfs->queue, pfs->channel, pfs->inode_table + bank * PFS_ONE_PAGE + j, addr, FALSE);
|
||||
ret = __osContRamWrite(pfs->queue, pfs->channel, pfs->inode_table + bank * PFS_ONE_PAGE + j, addr, false);
|
||||
}
|
||||
}
|
||||
else
|
||||
@@ -283,7 +283,7 @@ s32 __osPfsRWInode(OSPfs *pfs, __OSInode *inode, u8 flag, u8 bank)
|
||||
for (j = 0; j < PFS_ONE_PAGE; j++)
|
||||
{
|
||||
addr = ((u8 *)inode->inode_page + j * 32);
|
||||
ret = __osContRamWrite(pfs->queue, pfs->channel, pfs->minode_table + bank * PFS_ONE_PAGE + j, addr, FALSE);
|
||||
ret = __osContRamWrite(pfs->queue, pfs->channel, pfs->minode_table + bank * PFS_ONE_PAGE + j, addr, false);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -300,6 +300,6 @@ s32 __osPfsSelectBank(OSPfs *pfs)
|
||||
{
|
||||
temp[i] = pfs->activebank;
|
||||
}
|
||||
ret = __osContRamWrite(pfs->queue, pfs->channel, 1024, (u8*)temp, FALSE);
|
||||
ret = __osContRamWrite(pfs->queue, pfs->channel, 1024, (u8*)temp, false);
|
||||
return ret;
|
||||
}
|
||||
|
||||
@@ -39,7 +39,7 @@ void osCreatePiManager(OSPri pri, OSMesgQueue *cmdQ, OSMesg *cmdBuf, s32 cmdMsgC
|
||||
osSetThreadPri(NULL, pri);
|
||||
}
|
||||
int_disabled = __osDisableInt();
|
||||
__osPiDevMgr.initialized = TRUE;
|
||||
__osPiDevMgr.initialized = true;
|
||||
__osPiDevMgr.mgrThread = &piMgrThread;
|
||||
__osPiDevMgr.cmdQueue = cmdQ;
|
||||
__osPiDevMgr.eventQueue = &__osPiMesgQueue;
|
||||
|
||||
@@ -41,7 +41,7 @@ void osCreateViManager(OSPri pri) {
|
||||
osSetThreadPri(NULL, pri);
|
||||
}
|
||||
int_disabled = __osDisableInt();
|
||||
viMgrMainArgs.initialized = TRUE;
|
||||
viMgrMainArgs.initialized = true;
|
||||
viMgrMainArgs.mgrThread = &viMgrThread;
|
||||
viMgrMainArgs.cmdQueue = &__osViMesgQueue;
|
||||
viMgrMainArgs.eventQueue = &__osViMesgQueue;
|
||||
@@ -67,7 +67,7 @@ void viMgrMain(void *vargs) {
|
||||
u32 sp28; // always 0
|
||||
u32 sp24; // time related
|
||||
mesg = NULL;
|
||||
sp28 = FALSE;
|
||||
sp28 = false;
|
||||
context = __osViGetCurrentContext();
|
||||
|
||||
if ((retrace = context->retraceCount) == 0) {
|
||||
@@ -76,7 +76,7 @@ void viMgrMain(void *vargs) {
|
||||
|
||||
args = (OSMgrArgs *) vargs;
|
||||
|
||||
while (TRUE) {
|
||||
while (true) {
|
||||
osRecvMesg(args->eventQueue, &mesg, OS_MESG_BLOCK);
|
||||
switch (*(u16 *) mesg) {
|
||||
case 13:
|
||||
|
||||
@@ -33,7 +33,7 @@ void osInitialize(void) {
|
||||
UNUSED u32 eu_sp34;
|
||||
UNUSED u32 eu_sp30;
|
||||
UNUSED u32 sp2c;
|
||||
D_80194040 = TRUE;
|
||||
D_80194040 = true;
|
||||
__osSetSR(__osGetSR() | 0x20000000);
|
||||
__osSetFpcCsr(0x01000800);
|
||||
while (__osSiRawReadIo(PIF_ADDR_START, &sp34)) {
|
||||
|
||||
@@ -29,7 +29,7 @@ s32 osPfsAllocateFile(OSPfs *pfs, u16 company_code, u32 game_code, u8 *game_name
|
||||
return PFS_ERR_INVALID;
|
||||
|
||||
file_size_in_pages = (file_size_in_bytes + 255) / (BLOCKSIZE * PFS_ONE_PAGE);
|
||||
if ((pfs->status & PFS_INITIALIZED) == FALSE)
|
||||
if ((pfs->status & PFS_INITIALIZED) == false)
|
||||
return PFS_ERR_INVALID;
|
||||
|
||||
PFS_CHECK_ID;
|
||||
@@ -99,7 +99,7 @@ s32 osPfsAllocateFile(OSPfs *pfs, u16 company_code, u32 game_code, u8 *game_name
|
||||
dir.game_name[j] = *game_name++;
|
||||
for (j = 0; j < ARRLEN(dir.ext_name); j++)
|
||||
dir.ext_name[j] = *ext_name++;
|
||||
ERRCK(__osContRamWrite(pfs->queue, pfs->channel, *file_no + pfs->dir_table, (u8*)&dir, FALSE));
|
||||
ERRCK(__osContRamWrite(pfs->queue, pfs->channel, *file_no + pfs->dir_table, (u8*)&dir, false));
|
||||
return ret;
|
||||
}
|
||||
return PFS_ERR_INVALID;
|
||||
@@ -171,7 +171,7 @@ static s32 __osClearPage(OSPfs *pfs, int page_no, u8 *data, u8 bank)
|
||||
ERRCK(__osPfsSelectBank(pfs));
|
||||
for (i = 0; i < PFS_ONE_PAGE; i++)
|
||||
{
|
||||
ret = __osContRamWrite(pfs->queue, pfs->channel, page_no * PFS_ONE_PAGE + i, data, FALSE);
|
||||
ret = __osContRamWrite(pfs->queue, pfs->channel, page_no * PFS_ONE_PAGE + i, data, false);
|
||||
if (ret != 0)
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -59,7 +59,7 @@ s32 osPfsChecker(OSPfs *pfs)
|
||||
tmp_dir.status = DIR_STATUS_EMPTY;
|
||||
tmp_dir.data_sum = 0;
|
||||
SET_ACTIVEBANK_TO_ZERO;
|
||||
ERRCK(__osContRamWrite(pfs->queue, pfs->channel, pfs->dir_table + j, (u8*)&tmp_dir, FALSE));
|
||||
ERRCK(__osContRamWrite(pfs->queue, pfs->channel, pfs->dir_table + j, (u8*)&tmp_dir, false));
|
||||
fixed++;
|
||||
}
|
||||
else
|
||||
@@ -73,7 +73,7 @@ s32 osPfsChecker(OSPfs *pfs)
|
||||
tmp_dir.data_sum = 0;
|
||||
|
||||
SET_ACTIVEBANK_TO_ZERO;
|
||||
ERRCK(__osContRamWrite(pfs->queue, pfs->channel, pfs->dir_table + j, (u8*)&tmp_dir, FALSE));
|
||||
ERRCK(__osContRamWrite(pfs->queue, pfs->channel, pfs->dir_table + j, (u8*)&tmp_dir, false));
|
||||
fixed++;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -56,7 +56,7 @@ s32 osPfsDeleteFile(OSPfs *pfs, u16 company_code, u32 game_code, u8 *game_name,
|
||||
dir.ext_name[k] = 0;
|
||||
}
|
||||
dir.status = DIR_STATUS_EMPTY;
|
||||
ret = __osContRamWrite(pfs->queue, pfs->channel, pfs->dir_table + file_no, (u8*)&dir, FALSE);
|
||||
ret = __osContRamWrite(pfs->queue, pfs->channel, pfs->dir_table + file_no, (u8*)&dir, false);
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
@@ -17,7 +17,7 @@ s32 osPfsIsPlug(OSMesgQueue *queue, u8 *pattern) {
|
||||
bits = 0;
|
||||
crc_error_cnt = 3;
|
||||
__osSiGetAccess();
|
||||
while (TRUE) {
|
||||
while (true) {
|
||||
__osPfsRequestData(CONT_CMD_REQUEST_STATUS);
|
||||
ret = __osSiRawStartDma(OS_WRITE, &__osPfsPifRam);
|
||||
osRecvMesg(queue, &dummy, OS_MESG_BLOCK);
|
||||
|
||||
@@ -82,7 +82,7 @@ s32 osPfsReadWriteFile(OSPfs *pfs, s32 file_no, u8 flag, int offset, int size_in
|
||||
if (flag == OS_READ)
|
||||
ret = __osContRamRead(pfs->queue, pfs->channel, blockno, buffer);
|
||||
else
|
||||
ret = __osContRamWrite(pfs->queue, pfs->channel, blockno, buffer, FALSE);
|
||||
ret = __osContRamWrite(pfs->queue, pfs->channel, blockno, buffer, false);
|
||||
if (ret != 0)
|
||||
return ret;
|
||||
buffer += BLOCKSIZE;
|
||||
@@ -94,7 +94,7 @@ s32 osPfsReadWriteFile(OSPfs *pfs, s32 file_no, u8 flag, int offset, int size_in
|
||||
dir.status |= DIR_STATUS_OCCUPIED;
|
||||
pfs->activebank = 0;
|
||||
ERRCK(__osPfsSelectBank(pfs));
|
||||
ERRCK(__osContRamWrite(pfs->queue, pfs->channel, pfs->dir_table + file_no, (u8*)&dir, FALSE));
|
||||
ERRCK(__osContRamWrite(pfs->queue, pfs->channel, pfs->dir_table + file_no, (u8*)&dir, false));
|
||||
}
|
||||
return 0;
|
||||
|
||||
|
||||
@@ -15,14 +15,14 @@ s32 osPfsFindFile(OSPfs *pfs, u16 company_code, u32 game_code, u8 *game_name, u8
|
||||
ERRCK(__osContRamRead(pfs->queue, pfs->channel, pfs->dir_table + j, (u8*)&dir));
|
||||
if ((dir.company_code == company_code) && dir.game_code == game_code)
|
||||
{
|
||||
fail = FALSE;
|
||||
fail = false;
|
||||
if (game_name != NULL)
|
||||
{
|
||||
for (i = 0; i < ARRLEN(dir.game_name); i++)
|
||||
{
|
||||
if (dir.game_name[i] != game_name[i])
|
||||
{
|
||||
fail = TRUE;
|
||||
fail = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -34,7 +34,7 @@ s32 osPfsFindFile(OSPfs *pfs, u16 company_code, u32 game_code, u8 *game_name, u8
|
||||
{
|
||||
if (dir.ext_name[i] != ext_name[i])
|
||||
{
|
||||
fail = TRUE;
|
||||
fail = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
+1
-1
@@ -26,7 +26,7 @@ void __osTimerInterrupt(void) {
|
||||
if (__osTimerList->next == __osTimerList) {
|
||||
return;
|
||||
}
|
||||
while (TRUE) {
|
||||
while (true) {
|
||||
sp24 = __osTimerList->next;
|
||||
if (sp24 == __osTimerList) {
|
||||
__osSetCompare(0);
|
||||
|
||||
+22
-22
@@ -3228,15 +3228,15 @@ void detect_triple_a_combo_a_released(Player *player) {
|
||||
if (player == gPlayerEight) {
|
||||
playerIndex = 7;
|
||||
}
|
||||
if (gIsPlayerTripleAButtonCombo[playerIndex] == FALSE) {
|
||||
if (gPlayerIsThrottleActive[playerIndex] == TRUE) {
|
||||
if (gIsPlayerTripleAButtonCombo[playerIndex] == false) {
|
||||
if (gPlayerIsThrottleActive[playerIndex] == true) {
|
||||
if ((gFrameSinceLastACombo[playerIndex] < 2) || (gFrameSinceLastACombo[playerIndex] >= 9)) {
|
||||
gCountASwitch[playerIndex] = 0;
|
||||
}
|
||||
gFrameSinceLastACombo[playerIndex] = 0;
|
||||
D_80165400[playerIndex] = 0;
|
||||
}
|
||||
gPlayerIsThrottleActive[playerIndex] = FALSE;
|
||||
gPlayerIsThrottleActive[playerIndex] = false;
|
||||
gFrameSinceLastACombo[playerIndex]++;
|
||||
if (gFrameSinceLastACombo[playerIndex] >= 9) {
|
||||
gFrameSinceLastACombo[playerIndex] = 9;
|
||||
@@ -3248,7 +3248,7 @@ void detect_triple_a_combo_a_released(Player *player) {
|
||||
D_80165400[playerIndex] = 1;
|
||||
}
|
||||
if (gCountASwitch[playerIndex] == 5) {
|
||||
gIsPlayerTripleAButtonCombo[playerIndex] = TRUE;
|
||||
gIsPlayerTripleAButtonCombo[playerIndex] = true;
|
||||
gTimerBoostTripleACombo[playerIndex] = 120;
|
||||
gCountASwitch[playerIndex] = 0;
|
||||
gFrameSinceLastACombo[playerIndex] = 0;
|
||||
@@ -3256,7 +3256,7 @@ void detect_triple_a_combo_a_released(Player *player) {
|
||||
} else {
|
||||
gTimerBoostTripleACombo[playerIndex]--;
|
||||
if (gTimerBoostTripleACombo[playerIndex] <= 0) {
|
||||
gIsPlayerTripleAButtonCombo[playerIndex] = FALSE;
|
||||
gIsPlayerTripleAButtonCombo[playerIndex] = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -3288,15 +3288,15 @@ void detect_triple_a_combo_a_pressed(Player *player) {
|
||||
if (player == gPlayerEight) {
|
||||
playerIndex = 7;
|
||||
}
|
||||
if (gIsPlayerTripleAButtonCombo[playerIndex] == FALSE) {
|
||||
if (gPlayerIsThrottleActive[playerIndex] == FALSE) {
|
||||
if (gIsPlayerTripleAButtonCombo[playerIndex] == false) {
|
||||
if (gPlayerIsThrottleActive[playerIndex] == false) {
|
||||
if ((gFrameSinceLastACombo[playerIndex] < 2) || (gFrameSinceLastACombo[playerIndex] >= 9)) {
|
||||
gCountASwitch[playerIndex] = 0;
|
||||
}
|
||||
gFrameSinceLastACombo[playerIndex] = 0;
|
||||
D_80165400[playerIndex] = 0;
|
||||
}
|
||||
gPlayerIsThrottleActive[playerIndex] = TRUE;
|
||||
gPlayerIsThrottleActive[playerIndex] = true;
|
||||
gFrameSinceLastACombo[playerIndex]++;
|
||||
if (gFrameSinceLastACombo[playerIndex] >= 9) {
|
||||
gFrameSinceLastACombo[playerIndex] = 9;
|
||||
@@ -3308,7 +3308,7 @@ void detect_triple_a_combo_a_pressed(Player *player) {
|
||||
D_80165400[playerIndex] = 1;
|
||||
}
|
||||
if (gCountASwitch[playerIndex] == 5) {
|
||||
gIsPlayerTripleAButtonCombo[playerIndex] = TRUE;
|
||||
gIsPlayerTripleAButtonCombo[playerIndex] = true;
|
||||
gTimerBoostTripleACombo[playerIndex] = 120;
|
||||
gCountASwitch[playerIndex] = 0;
|
||||
gFrameSinceLastACombo[playerIndex] = 0;
|
||||
@@ -3316,7 +3316,7 @@ void detect_triple_a_combo_a_pressed(Player *player) {
|
||||
} else {
|
||||
gTimerBoostTripleACombo[playerIndex]--;
|
||||
if (gTimerBoostTripleACombo[playerIndex] <= 0) {
|
||||
gIsPlayerTripleAButtonCombo[playerIndex] = FALSE;
|
||||
gIsPlayerTripleAButtonCombo[playerIndex] = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -3325,7 +3325,7 @@ void player_speed(Player *player) {
|
||||
s32 player_index;
|
||||
|
||||
player_index = get_player_index_for_player(player);
|
||||
if (gIsPlayerTripleAButtonCombo[player_index] == FALSE) {
|
||||
if (gIsPlayerTripleAButtonCombo[player_index] == false) {
|
||||
if ((0.0 <= player->currentSpeed) && (player->currentSpeed < (player->topSpeed * 0.1))) {
|
||||
player->currentSpeed += gKartAccelerationTables[player->characterId][0] + (0.05 * (player->slopeAccel / 182));
|
||||
}
|
||||
@@ -3456,15 +3456,15 @@ void detect_triple_b_combo_b_released(Player *player) {
|
||||
playerIndex = 7;
|
||||
}
|
||||
|
||||
if (gIsPlayerTripleBButtonCombo[playerIndex] == FALSE) {
|
||||
if (gPlayerIsBrakeActive[playerIndex] == TRUE) {
|
||||
if (gIsPlayerTripleBButtonCombo[playerIndex] == false) {
|
||||
if (gPlayerIsBrakeActive[playerIndex] == true) {
|
||||
if ((gFrameSinceLastBCombo[playerIndex] < 2) || (gFrameSinceLastBCombo[playerIndex] >= 9)) {
|
||||
gCountBChangement[playerIndex] = 0;
|
||||
}
|
||||
gFrameSinceLastBCombo[playerIndex] = 0;
|
||||
D_801654C0[playerIndex] = 0;
|
||||
}
|
||||
gPlayerIsBrakeActive[playerIndex] = FALSE;
|
||||
gPlayerIsBrakeActive[playerIndex] = false;
|
||||
gFrameSinceLastBCombo[playerIndex]++;
|
||||
if (gFrameSinceLastBCombo[playerIndex] >= 9) {
|
||||
gFrameSinceLastBCombo[playerIndex] = 9;
|
||||
@@ -3476,7 +3476,7 @@ void detect_triple_b_combo_b_released(Player *player) {
|
||||
D_801654C0[playerIndex] = 1;
|
||||
}
|
||||
if (gCountBChangement[playerIndex] == 5) {
|
||||
gIsPlayerTripleBButtonCombo[playerIndex] = TRUE;
|
||||
gIsPlayerTripleBButtonCombo[playerIndex] = true;
|
||||
gTimerBoostTripleBCombo[playerIndex] = 120;
|
||||
gCountBChangement[playerIndex] = 0;
|
||||
gFrameSinceLastBCombo[playerIndex] = 0;
|
||||
@@ -3484,7 +3484,7 @@ void detect_triple_b_combo_b_released(Player *player) {
|
||||
} else {
|
||||
gTimerBoostTripleBCombo[playerIndex]--;
|
||||
if (gTimerBoostTripleBCombo[playerIndex] <= 0) {
|
||||
gIsPlayerTripleBButtonCombo[playerIndex] = FALSE;
|
||||
gIsPlayerTripleBButtonCombo[playerIndex] = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -3517,15 +3517,15 @@ void detect_triple_b_combo_b_pressed(Player *player) {
|
||||
playerIndex = 7;
|
||||
}
|
||||
|
||||
if (gIsPlayerTripleBButtonCombo[playerIndex] == FALSE) {
|
||||
if (gPlayerIsBrakeActive[playerIndex] == FALSE) {
|
||||
if (gIsPlayerTripleBButtonCombo[playerIndex] == false) {
|
||||
if (gPlayerIsBrakeActive[playerIndex] == false) {
|
||||
if ((gFrameSinceLastBCombo[playerIndex] < 2) || (gFrameSinceLastBCombo[playerIndex] >= 9)) {
|
||||
gCountBChangement[playerIndex] = 0;
|
||||
}
|
||||
gFrameSinceLastBCombo[playerIndex] = 0;
|
||||
D_801654C0[playerIndex] = 0;
|
||||
}
|
||||
gPlayerIsBrakeActive[playerIndex] = TRUE;
|
||||
gPlayerIsBrakeActive[playerIndex] = true;
|
||||
gFrameSinceLastBCombo[playerIndex]++;
|
||||
if (gFrameSinceLastBCombo[playerIndex] >= 9) {
|
||||
gFrameSinceLastBCombo[playerIndex] = 9;
|
||||
@@ -3537,7 +3537,7 @@ void detect_triple_b_combo_b_pressed(Player *player) {
|
||||
D_801654C0[playerIndex] = 1;
|
||||
}
|
||||
if (gCountBChangement[playerIndex] == 5) {
|
||||
gIsPlayerTripleBButtonCombo[playerIndex] = TRUE;
|
||||
gIsPlayerTripleBButtonCombo[playerIndex] = true;
|
||||
gTimerBoostTripleBCombo[playerIndex] = 120;
|
||||
gCountBChangement[playerIndex] = 0;
|
||||
gFrameSinceLastBCombo[playerIndex] = 0;
|
||||
@@ -3545,7 +3545,7 @@ void detect_triple_b_combo_b_pressed(Player *player) {
|
||||
} else {
|
||||
gTimerBoostTripleBCombo[playerIndex]--;
|
||||
if (gTimerBoostTripleBCombo[playerIndex] <= 0) {
|
||||
gIsPlayerTripleBButtonCombo[playerIndex] = FALSE;
|
||||
gIsPlayerTripleBButtonCombo[playerIndex] = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -3601,7 +3601,7 @@ void func_800323E4(Player *player) {
|
||||
player->unk_20C = 2.0f;
|
||||
}
|
||||
}
|
||||
if (gIsPlayerTripleBButtonCombo[var_v1] == TRUE) {
|
||||
if (gIsPlayerTripleBButtonCombo[var_v1] == true) {
|
||||
if (player->unk_20C >= 2.0f) {
|
||||
decelerate_ai_player(player, (1.0f - var_f2) * 5.0f);
|
||||
} else {
|
||||
|
||||
+23
-23
@@ -1555,9 +1555,9 @@ bool collision_mario_sign(Player *player, struct Actor *marioRacewaySign) {
|
||||
func_800C9060(player - gPlayerOne, SOUND_ARG_LOAD(0x19, 0x00, 0x70, 0x1A));
|
||||
}
|
||||
}
|
||||
return TRUE;
|
||||
return true;
|
||||
}
|
||||
return FALSE;
|
||||
return false;
|
||||
}
|
||||
|
||||
bool collision_piranha_plant(Player *player, struct PiranhaPlant *plant) {
|
||||
@@ -1571,9 +1571,9 @@ bool collision_piranha_plant(Player *player, struct PiranhaPlant *plant) {
|
||||
func_800C9060(player - gPlayerOne, SOUND_ARG_LOAD(0x19, 0x00, 0xA0, 0x52));
|
||||
}
|
||||
}
|
||||
return TRUE;
|
||||
return true;
|
||||
}
|
||||
return FALSE;
|
||||
return false;
|
||||
}
|
||||
|
||||
bool collision_yoshi_egg(Player *player, struct YoshiValleyEgg *egg) {
|
||||
@@ -1588,34 +1588,34 @@ bool collision_yoshi_egg(Player *player, struct YoshiValleyEgg *egg) {
|
||||
|
||||
x_dist = egg->pos[0] - player->pos[0];
|
||||
if ((x_dist < minDist) && (x_dist < -maxDist)) {
|
||||
return FALSE;
|
||||
return false;
|
||||
}
|
||||
if (x_dist > maxDist) {
|
||||
return FALSE;
|
||||
return false;
|
||||
}
|
||||
|
||||
z_dist = egg->pos[2] - player->pos[2];
|
||||
if ((z_dist < minDist) && (z_dist < -maxDist)) {
|
||||
return FALSE;
|
||||
return false;
|
||||
}
|
||||
if (z_dist > maxDist) {
|
||||
return FALSE;
|
||||
return false;
|
||||
}
|
||||
|
||||
xz_dist = sqrtf((x_dist * x_dist) + (z_dist * z_dist));
|
||||
if (xz_dist > maxDist) {
|
||||
return FALSE;
|
||||
return false;
|
||||
}
|
||||
func_802977B0(player);
|
||||
|
||||
y_dist = player->pos[1] - egg->pos[1];
|
||||
if (y_dist < minDist) {
|
||||
return FALSE;
|
||||
return false;
|
||||
}
|
||||
|
||||
totalBox = player->boundingBoxSize + egg->boundingBoxSize;
|
||||
if (totalBox < xz_dist) {
|
||||
return FALSE;
|
||||
return false;
|
||||
}
|
||||
|
||||
if ((player->type & PLAYER_HUMAN) != 0) {
|
||||
@@ -1634,7 +1634,7 @@ bool collision_yoshi_egg(Player *player, struct YoshiValleyEgg *egg) {
|
||||
apply_hit_sound_effect(player, player - gPlayerOne);
|
||||
}
|
||||
|
||||
return TRUE;
|
||||
return true;
|
||||
}
|
||||
|
||||
bool collision_tree(Player *player, struct Actor *actor) {
|
||||
@@ -1654,33 +1654,33 @@ bool collision_tree(Player *player, struct Actor *actor) {
|
||||
var_f16 = actor->unk_08;
|
||||
x_dist = actor->pos[0] - player->pos[0];
|
||||
if ((x_dist < 0.0f) && (x_dist < -var_f16)) {
|
||||
return FALSE;
|
||||
return false;
|
||||
}
|
||||
if (var_f16 < x_dist) {
|
||||
return FALSE;
|
||||
return false;
|
||||
}
|
||||
z_dist = actor->pos[2] - player->pos[2];
|
||||
if ((z_dist < 0.0f) && (z_dist < -var_f16)) {
|
||||
return FALSE;
|
||||
return false;
|
||||
}
|
||||
if (var_f16 < z_dist) {
|
||||
return FALSE;
|
||||
return false;
|
||||
}
|
||||
y_dist = player->pos[1] - actor->pos[1];
|
||||
if (y_dist < 0.0f) {
|
||||
return FALSE;
|
||||
return false;
|
||||
}
|
||||
if ((f32) actor->state < y_dist) {
|
||||
return FALSE;
|
||||
return false;
|
||||
}
|
||||
xz_dist = sqrtf((x_dist * x_dist) + (z_dist * z_dist));
|
||||
if (var_f16 < xz_dist) {
|
||||
return FALSE;
|
||||
return false;
|
||||
}
|
||||
func_802977B0(player);
|
||||
var_f16 = player->boundingBoxSize + actor->boundingBoxSize;
|
||||
if (var_f16 < xz_dist) {
|
||||
return FALSE;
|
||||
return false;
|
||||
}
|
||||
sp48 = player->velocity[0];
|
||||
sp44 = player->velocity[2];
|
||||
@@ -1689,7 +1689,7 @@ bool collision_tree(Player *player, struct Actor *actor) {
|
||||
actor->flags |= 0x400;
|
||||
func_800C98B8(player->pos, player->velocity, SOUND_ARG_LOAD(0x19, 0x01, 0x80, 0x10));
|
||||
func_800C90F4(player - gPlayerOne, (player->characterId * 0x10) + SOUND_ARG_LOAD(0x29, 0x00, 0x80, 0x0D));
|
||||
return TRUE;
|
||||
return true;
|
||||
}
|
||||
if (!(player->type & PLAYER_INVISIBLE_OR_BOMB)) {
|
||||
func_800C9060(player - gPlayerOne, SOUND_ARG_LOAD(0x19, 0x00, 0x70, 0x18));
|
||||
@@ -1720,7 +1720,7 @@ bool collision_tree(Player *player, struct Actor *actor) {
|
||||
player->pos[2] = actorPos[2] - (z_dist * var_f16 * 1.2f);
|
||||
player->velocity[0] = 0;
|
||||
player->velocity[2] = 0;
|
||||
return TRUE;
|
||||
return true;
|
||||
}
|
||||
temp_f12 = ((x_dist * sp48) + (z_dist * sp44)) / temp_f0_4;
|
||||
temp_f12 = temp_f0_4 * temp_f12 * 1.5f;
|
||||
@@ -1730,7 +1730,7 @@ bool collision_tree(Player *player, struct Actor *actor) {
|
||||
player->pos[0] += x_dist * temp_f2 * 0.5f;
|
||||
player->pos[2] += z_dist * temp_f2 * 0.5f;
|
||||
}
|
||||
return TRUE;
|
||||
return true;
|
||||
}
|
||||
|
||||
bool query_collision_player_vs_actor_item(Player *arg0, struct Actor *arg1) {
|
||||
|
||||
@@ -315,19 +315,19 @@ void update_actor_banana_bunch(struct BananaBunchParent *banana_bunch) {
|
||||
bool is_shell_exist(s16 arg0) {
|
||||
struct ShellActor *actor;
|
||||
if (arg0 < 0) {
|
||||
return FALSE;
|
||||
return false;
|
||||
}
|
||||
actor = (struct ShellActor*) &gActorList[arg0];
|
||||
if (actor->type == ACTOR_GREEN_SHELL) {
|
||||
if (actor->state == TRIPLE_GREEN_SHELL) {
|
||||
return TRUE;
|
||||
return true;
|
||||
}
|
||||
return FALSE;
|
||||
return false;
|
||||
}
|
||||
if (actor->state == TRIPLE_RED_SHELL) {
|
||||
return TRUE;
|
||||
return true;
|
||||
}
|
||||
return FALSE;
|
||||
return false;
|
||||
}
|
||||
|
||||
void update_actor_triple_shell(TripleShellParent *parent, s16 shellType) {
|
||||
@@ -932,7 +932,7 @@ void check_player_use_item(void) {
|
||||
|
||||
for (player = &gPlayers[0], loopController = &gControllers[0], target = &gControllers[4]; loopController != target; player++, loopController++) {
|
||||
controller = loopController;
|
||||
if (prevent_item_use(player) == FALSE) {
|
||||
if (prevent_item_use(player) == false) {
|
||||
if((player->type & PLAYER_INVISIBLE_OR_BOMB) != 0){
|
||||
if ((player - gPlayerTwo) == 0) {
|
||||
controller = gControllerSix;
|
||||
|
||||
+44
-44
@@ -128,7 +128,7 @@ s32 check_collision_zx(Collision *collision, f32 boundingBoxSize, f32 posX, f32
|
||||
f32 crossProductZX_1;
|
||||
f32 crossProductZX_2;
|
||||
f32 crossProductZX_3;
|
||||
s32 bool = TRUE;
|
||||
s32 b = true;
|
||||
|
||||
if (triangle->normalY < -0.9f)
|
||||
return 0;
|
||||
@@ -161,7 +161,7 @@ s32 check_collision_zx(Collision *collision, f32 boundingBoxSize, f32 posX, f32
|
||||
crossProductZX_3 = (z3 - posZ) * (x1 - posX) - (x3 - posX) * (z1 - posZ);
|
||||
|
||||
if ((crossProductZX_2 * crossProductZX_3) < 0.0f) {
|
||||
bool = FALSE;
|
||||
b = false;
|
||||
}
|
||||
} else {
|
||||
|
||||
@@ -171,22 +171,22 @@ s32 check_collision_zx(Collision *collision, f32 boundingBoxSize, f32 posX, f32
|
||||
crossProductZX_3 = (z3 - posZ) * (x1 - posX) - (x3 - posX) * (z1 - posZ);
|
||||
|
||||
if ((crossProductZX_1 * crossProductZX_3) < 0.0f) {
|
||||
bool = FALSE;
|
||||
b = false;
|
||||
}
|
||||
} else {
|
||||
if ((crossProductZX_1 * crossProductZX_2) < 0.0f) {
|
||||
bool = FALSE;
|
||||
b = false;
|
||||
} else {
|
||||
crossProductZX_3 = (z3 - posZ) * (x1 - posX) - (x3 - posX) * (z1 - posZ);
|
||||
if (crossProductZX_3 != 0) {
|
||||
if ((crossProductZX_2 * crossProductZX_3) < 0.0f) {
|
||||
bool = FALSE;
|
||||
b = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
if (!bool) {
|
||||
if (!b) {
|
||||
return 0;
|
||||
}
|
||||
distanceToSurface = ((triangle->normalX * posX) + (triangle->normalY * posY) + (triangle->normalZ * posZ)
|
||||
@@ -232,7 +232,7 @@ s32 check_collision_yx(Collision *collision, f32 boundingBoxSize, f32 posX, f32
|
||||
f32 crossProductYX_1;
|
||||
f32 crossProductYX_2;
|
||||
f32 crossProductYX_3;
|
||||
s32 bool = TRUE;
|
||||
s32 b = true;
|
||||
|
||||
if (triangle->minX > posX) {
|
||||
return 0;
|
||||
@@ -272,29 +272,29 @@ s32 check_collision_yx(Collision *collision, f32 boundingBoxSize, f32 posX, f32
|
||||
crossProductYX_3 = (y3 - posY) * (x1 - posX) - (x3 - posX) * (y1 - posY);
|
||||
|
||||
if ((crossProductYX_2 * crossProductYX_3) < 0.0f) {
|
||||
bool = FALSE;
|
||||
b = false;
|
||||
}
|
||||
} else {
|
||||
crossProductYX_2 = (y2 - posY) * (x3 - posX) - (x2 - posX) * (y3 - posY);
|
||||
if (!crossProductYX_2) {
|
||||
crossProductYX_3 = (y3 - posY) * (x1 - posX) - (x3 - posX) * (y1 - posY);
|
||||
if (crossProductYX_1 * crossProductYX_3 < 0.0f) {
|
||||
bool = FALSE;
|
||||
b = false;
|
||||
}
|
||||
} else {
|
||||
if ((crossProductYX_1 * crossProductYX_2) < 0.0f) {
|
||||
bool = FALSE;
|
||||
b = false;
|
||||
} else {
|
||||
crossProductYX_3 = ((y3 - posY) * (x1 - posX)) - ((x3 - posX) * (y1 - posY));
|
||||
if (crossProductYX_3 != 0) {
|
||||
if ((crossProductYX_2 * crossProductYX_3) < 0.0f) {
|
||||
bool = FALSE;
|
||||
b = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
if (!bool) {
|
||||
if (!b) {
|
||||
return 0;
|
||||
}
|
||||
distanceToSurface = ((triangle->normalX * posX) + (triangle->normalY * posY) + (triangle->normalZ * posZ) + triangle->distance) - boundingBoxSize;
|
||||
@@ -324,7 +324,7 @@ s32 check_collision_yx(Collision *collision, f32 boundingBoxSize, f32 posX, f32
|
||||
|
||||
s32 check_collision_zy(Collision *collision, f32 boundingBoxSize, f32 posX, f32 posY, f32 posZ, u16 index) {
|
||||
CollisionTriangle *triangle = &gCollisionMesh[index];
|
||||
s32 bool = TRUE;
|
||||
s32 b = true;
|
||||
UNUSED f32 pad[7];
|
||||
f32 y3;
|
||||
f32 z3;
|
||||
@@ -374,7 +374,7 @@ s32 check_collision_zy(Collision *collision, f32 boundingBoxSize, f32 posX, f32
|
||||
crossProductYZ_3 = ((y3 - posY) * (z1 - posZ)) - ((z3 - posZ) * (y1 - posY));
|
||||
|
||||
if ((crossProductYZ_2 * crossProductYZ_3) < 0.0f) {
|
||||
bool = FALSE;
|
||||
b = false;
|
||||
}
|
||||
} else {
|
||||
|
||||
@@ -384,23 +384,23 @@ s32 check_collision_zy(Collision *collision, f32 boundingBoxSize, f32 posX, f32
|
||||
crossProductYZ_3 = ((y3 - posY) * (z1 - posZ)) - ((z3 - posZ) * (y1 - posY));
|
||||
|
||||
if ((crossProductYZ_1 * crossProductYZ_3) < 0.0f) {
|
||||
bool = FALSE;
|
||||
b = false;
|
||||
}
|
||||
} else {
|
||||
|
||||
if ((crossProductYZ_1 * crossProductYZ_2) < 0.0f) {
|
||||
bool = FALSE;
|
||||
b = false;
|
||||
} else {
|
||||
crossProductYZ_3 = ((y3 - posY) * (z1 - posZ)) - ((z3 - posZ) * (y1 - posY));
|
||||
if (crossProductYZ_3 != 0) {
|
||||
if ((crossProductYZ_2 * crossProductYZ_3) < 0.0f) {
|
||||
bool = FALSE;
|
||||
b = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
if (!bool) {
|
||||
if (!b) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -446,7 +446,7 @@ s32 check_horizontally_colliding_with_triangle(f32 posX, f32 posZ, u16 index) {
|
||||
f32 crossProductZX_1;
|
||||
f32 crossProductZX_3;
|
||||
f32 crossProductZX_2;
|
||||
s32 bool = TRUE;
|
||||
s32 b = true;
|
||||
|
||||
x1 = triangle->vtx1->v.ob[0];
|
||||
z1 = triangle->vtx1->v.ob[2];
|
||||
@@ -466,29 +466,29 @@ s32 check_horizontally_colliding_with_triangle(f32 posX, f32 posZ, u16 index) {
|
||||
crossProductZX_3 = (z3 - posZ) * (x1 - posX) - (x3 - posX) * (z1 - posZ);
|
||||
|
||||
if ((crossProductZX_2 * crossProductZX_3) < 0.0f) {
|
||||
bool = FALSE;
|
||||
b = false;
|
||||
}
|
||||
} else {
|
||||
crossProductZX_2 = (z2 - posZ) * (x3 - posX) - (x2 - posX) * (z3 - posZ);
|
||||
if (!crossProductZX_2) {
|
||||
crossProductZX_3 = (z3 - posZ) * (x1 - posX) - (x3 - posX) * (z1 - posZ);
|
||||
if (crossProductZX_1 * crossProductZX_3 < 0.0f) {
|
||||
bool = FALSE;
|
||||
b = false;
|
||||
}
|
||||
} else {
|
||||
if ((crossProductZX_1 * crossProductZX_2) < 0.0f) {
|
||||
bool = FALSE;
|
||||
b = false;
|
||||
} else {
|
||||
crossProductZX_3 = ((z3 - posZ) * (x1 - posX)) - ((x3 - posX) * (z1 - posZ));
|
||||
if (crossProductZX_3 != 0) {
|
||||
if ((crossProductZX_2 * crossProductZX_3) < 0.0f) {
|
||||
bool = FALSE;
|
||||
b = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return bool;
|
||||
return b;
|
||||
}
|
||||
|
||||
s8 get_surface_type(u16 index) {
|
||||
@@ -766,7 +766,7 @@ s32 is_colliding_with_drivable_surface(Collision *collision, f32 boundingBoxSize
|
||||
f32 area;
|
||||
f32 area2;
|
||||
f32 area3;
|
||||
s32 bool = 1;
|
||||
s32 b = 1;
|
||||
|
||||
if (triangle->minX > x1) {
|
||||
return 0;
|
||||
@@ -799,7 +799,7 @@ s32 is_colliding_with_drivable_surface(Collision *collision, f32 boundingBoxSize
|
||||
area2 = (z3 - z1) * (x4 - x1) - (x3 - x1) * (z4 - z1);
|
||||
area3 = (z4 - z1) * (x2 - x1) - (x4 - x1) * (z2 - z1);
|
||||
if (area2 * area3 < 0.0f) {
|
||||
bool = 0;
|
||||
b = 0;
|
||||
}
|
||||
} else {
|
||||
|
||||
@@ -811,22 +811,22 @@ s32 is_colliding_with_drivable_surface(Collision *collision, f32 boundingBoxSize
|
||||
area3 = (z4 - z1) * (x2 - x1) - (x4 - x1) * (z2 - z1);
|
||||
|
||||
if (area * area3 < 0.0f) {
|
||||
bool = 0;
|
||||
b = 0;
|
||||
}
|
||||
} else {
|
||||
if ((area * area2) < 0.0f) {
|
||||
bool = 0;
|
||||
b = 0;
|
||||
} else {
|
||||
area3 = (z4- z1) * (x2 - x1) - (x4 - x1) * (z2 - z1);
|
||||
if (area3 != 0) {
|
||||
if (area2 * area3 < 0.0f) {
|
||||
bool = 0;
|
||||
b = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
if (bool == 0) {
|
||||
if (b == 0) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -877,7 +877,7 @@ s32 is_colliding_with_wall2(Collision *arg, f32 boundingBoxSize, f32 x1, f32 y1,
|
||||
f32 area;
|
||||
f32 area2;
|
||||
f32 area3;
|
||||
s32 bool = TRUE;
|
||||
s32 b = true;
|
||||
if (triangle->minX > x1) {
|
||||
return 0;
|
||||
}
|
||||
@@ -914,7 +914,7 @@ s32 is_colliding_with_wall2(Collision *arg, f32 boundingBoxSize, f32 x1, f32 y1,
|
||||
|
||||
|
||||
if (area2 * area3 < 0.0f) {
|
||||
bool = FALSE;
|
||||
b = false;
|
||||
}
|
||||
} else {
|
||||
|
||||
@@ -925,23 +925,23 @@ s32 is_colliding_with_wall2(Collision *arg, f32 boundingBoxSize, f32 x1, f32 y1,
|
||||
|
||||
|
||||
if ((area * area3) < 0.0f) {
|
||||
bool = FALSE;
|
||||
b = false;
|
||||
}
|
||||
} else {
|
||||
if ((area * area2) < 0.0f) {
|
||||
bool = FALSE;
|
||||
b = false;
|
||||
} else {
|
||||
area3 = (y4 - y1) * (x2 - x1) - (x4 - x1) * (y2 - y1);
|
||||
|
||||
if (area3 != 0) {
|
||||
if ((area2 * area3) < 0.0f) {
|
||||
bool = FALSE;
|
||||
b = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
if (!bool) {
|
||||
if (!b) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -1042,7 +1042,7 @@ s32 is_colliding_with_wall2(Collision *arg, f32 boundingBoxSize, f32 x1, f32 y1,
|
||||
*/
|
||||
s32 is_colliding_with_wall1(Collision *arg, f32 boundingBoxSize, f32 x1, f32 y1, f32 z1, u16 arg5, f32 arg6, f32 arg7, f32 arg8) {
|
||||
CollisionTriangle *triangle = &gCollisionMesh[arg5];
|
||||
s32 bool = 1;
|
||||
s32 b = 1;
|
||||
UNUSED s32 pad[7];
|
||||
f32 y4;
|
||||
f32 z4;
|
||||
@@ -1094,7 +1094,7 @@ s32 is_colliding_with_wall1(Collision *arg, f32 boundingBoxSize, f32 x1, f32 y1,
|
||||
|
||||
|
||||
if (area2 * area3 < 0.0f) {
|
||||
bool = 0;
|
||||
b = 0;
|
||||
}
|
||||
} else {
|
||||
|
||||
@@ -1105,23 +1105,23 @@ s32 is_colliding_with_wall1(Collision *arg, f32 boundingBoxSize, f32 x1, f32 y1,
|
||||
|
||||
|
||||
if ((area * area3) < 0.0f) {
|
||||
bool = 0;
|
||||
b = 0;
|
||||
}
|
||||
} else {
|
||||
if ((area * area2) < 0.0f) {
|
||||
bool = 0;
|
||||
b = 0;
|
||||
} else {
|
||||
area3 = (y4 - y1) * (z2 - z1) - (z4 - z1) * (y2 - y1);
|
||||
|
||||
if (area3 != 0) {
|
||||
if ((area2 * area3) < 0.0f) {
|
||||
bool = 0;
|
||||
b = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
if (bool == 0) {
|
||||
if (b == 0) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -2042,7 +2042,7 @@ void find_and_set_tile_size(uintptr_t addr, s32 uls, s32 ult) {
|
||||
uls = (uls << 12) & 0xFFF000;
|
||||
ult &= 0xFFF;
|
||||
|
||||
while(TRUE) {
|
||||
while(true) {
|
||||
|
||||
opcode = GFX_GET_OPCODE(gfx->words.w0);
|
||||
|
||||
@@ -2085,7 +2085,7 @@ void find_vtx_and_set_colours(uintptr_t displayList, s8 alpha, u8 red, u8 green,
|
||||
uintptr_t hi;
|
||||
s32 opcode;
|
||||
|
||||
while(TRUE) {
|
||||
while(true) {
|
||||
lo = gfx->words.w0;
|
||||
hi = gfx->words.w1;
|
||||
opcode = GFX_GET_OPCODE(lo);
|
||||
|
||||
+3
-3
@@ -977,7 +977,7 @@ void displaylist_unpack(uintptr_t *data, uintptr_t finalDisplaylistOffset, u32 a
|
||||
sGfxSeekPosition = 0;
|
||||
sPackedSeekPosition = 0;
|
||||
|
||||
while(TRUE) {
|
||||
while(true) {
|
||||
|
||||
// Seek to the next byte
|
||||
opcode = packed_dl[sPackedSeekPosition++];
|
||||
@@ -1275,7 +1275,7 @@ void decompress_textures(u32 *arg0) {
|
||||
|
||||
phi_v0 = 0;
|
||||
temp_s0 = phi_s0;
|
||||
while (TRUE) {
|
||||
while (true) {
|
||||
temp_a0 = phi_s0->unk0;
|
||||
if ((temp_a0) == 0) {
|
||||
break;
|
||||
@@ -1287,7 +1287,7 @@ void decompress_textures(u32 *arg0) {
|
||||
gHeapEndPtr -= phi_v0;
|
||||
sp20 = gHeapEndPtr;
|
||||
|
||||
while (TRUE) {
|
||||
while (true) {
|
||||
temp_a0 = phi_s0->unk0;
|
||||
if ((temp_a0) == 0) {
|
||||
break;
|
||||
|
||||
@@ -3270,7 +3270,7 @@ void render_ice_block(s32 arg0) {
|
||||
for (playerId = 0; playerId < gPlayerCountSelection1; playerId++) {
|
||||
objectIndex = gIndexLakituList[playerId];
|
||||
if (objectIndex) {}
|
||||
if (func_80072320(objectIndex, 4) != FALSE) {
|
||||
if (func_80072320(objectIndex, 4) != false) {
|
||||
func_8005285C(playerId);
|
||||
}
|
||||
func_80072320(objectIndex, 0x00000010);
|
||||
|
||||
+11
-11
@@ -106,7 +106,7 @@ u16 check_player_camera_collision(Player *player, Camera *camera, f32 arg2, f32
|
||||
s16 var_v0;
|
||||
u16 ret;
|
||||
|
||||
ret = FALSE;
|
||||
ret = false;
|
||||
switch (gActiveScreenMode) { /* irregular */
|
||||
case SCREEN_MODE_1P:
|
||||
var_v0 = 0x293C;
|
||||
@@ -135,7 +135,7 @@ u16 check_player_camera_collision(Player *player, Camera *camera, f32 arg2, f32
|
||||
sp5C = ((sp44 - player->pos[2]) * (sp58 - player->pos[0])) - ((sp4C - player->pos[2]) * (sp50 - player->pos[0]));
|
||||
|
||||
if (((sp64 >= 0) && (sp60 >= 0) && (sp5C >= 0)) || (((sp64) <= 0) && (sp60 <= 0) && (sp5C <= 0))) {
|
||||
ret = TRUE;
|
||||
ret = true;
|
||||
}
|
||||
return ret;
|
||||
}
|
||||
@@ -152,7 +152,7 @@ u16 func_8001FD78(Player *player, f32 posX, UNUSED f32 arg2, f32 posZ) {
|
||||
f32 thing1;
|
||||
u16 ret;
|
||||
|
||||
ret = FALSE;
|
||||
ret = false;
|
||||
|
||||
sp58 = (70.0f * coss(((player->unk_0C0 - player->rotation[1]) - 0x71C))) + player->pos[2];
|
||||
sp64 = (70.0f * sins(((player->unk_0C0 - player->rotation[1]) - 0x71C))) + player->pos[0];
|
||||
@@ -165,7 +165,7 @@ u16 func_8001FD78(Player *player, f32 posX, UNUSED f32 arg2, f32 posZ) {
|
||||
thing0 = ((sp54 - posZ) * (sp5c - posX)) - ((sp50 - posZ) * (sp60 - posX));
|
||||
thing1 = ((sp50 - posZ) * (sp64 - posX)) - ((sp58 - posZ) * (sp5c - posX));
|
||||
if (((temp_f14 >= 0) && (thing0 >= 0) && (thing1 >= 0)) || ((temp_f14 <= 0) && (thing0 <= 0) && (thing1 <= 0))) {
|
||||
ret = TRUE;
|
||||
ret = true;
|
||||
}
|
||||
return ret;
|
||||
}
|
||||
@@ -793,9 +793,9 @@ bool adjust_angle(s16 *angle, s16 targetAngle, s16 step) {
|
||||
}
|
||||
}
|
||||
if (targetAngle == *angle) {
|
||||
return FALSE;
|
||||
return false;
|
||||
}
|
||||
return TRUE;
|
||||
return true;
|
||||
}
|
||||
|
||||
void move_s32_towards(s32 *startingValue, s32 targetValue, f32 somePercent) {
|
||||
@@ -1063,12 +1063,12 @@ bool is_player_under_light_luigi_raceway(Player *player, s8 arg1) {
|
||||
change_player_color_effect_rgb(player, arg1, COLOR_LIGHT, 0.3f);
|
||||
change_player_color_effect_cmy(player, arg1, 0xE0, 0.3f);
|
||||
D_80164B80[arg1] = 0;
|
||||
return TRUE;
|
||||
return true;
|
||||
}
|
||||
return FALSE;
|
||||
return false;
|
||||
|
||||
default:
|
||||
return FALSE;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1214,7 +1214,7 @@ void func_800235AC(Player *player, s8 arg1) {
|
||||
return;
|
||||
}
|
||||
}
|
||||
if (is_player_under_light_luigi_raceway(player, arg1) != TRUE) {
|
||||
if (is_player_under_light_luigi_raceway(player, arg1) != true) {
|
||||
if (((player->tyres[BACK_RIGHT].unk_14 & 1) == 1)
|
||||
|| ((player->tyres[BACK_RIGHT].unk_14 & 2) == 2)
|
||||
|| ((player->tyres[FRONT_LEFT].unk_14 & 3) == 3)) {
|
||||
@@ -1705,7 +1705,7 @@ void func_80026A48(Player *player, s8 arg1) {
|
||||
}
|
||||
|
||||
temp_f0 = ((player->unk_094 * (1.0f + player->unk_104)) / 18.0f) * 216.0f;
|
||||
if ((temp_f0 <= 1.0f) || (gIsPlayerTripleBButtonCombo[arg1] == TRUE)) {
|
||||
if ((temp_f0 <= 1.0f) || (gIsPlayerTripleBButtonCombo[arg1] == true)) {
|
||||
player->unk_240 = 0;
|
||||
} else {
|
||||
player->unk_240 += D_800DDE74[(s32)(temp_f0 / 12.0f)];
|
||||
|
||||
+1
-1
@@ -999,7 +999,7 @@ s32 func_800B69BC(s32 arg0) {
|
||||
s32 i;
|
||||
struct_8018EE10_entry *plz = &D_8018EE10[arg0];
|
||||
|
||||
plz->ghostDataSaved = FALSE;
|
||||
plz->ghostDataSaved = false;
|
||||
plz->courseIndex = 0;
|
||||
plz->characterId = 0;
|
||||
for (i = 0; i < sizeof(plz->unk_07); i++) {
|
||||
|
||||
+2
-2
@@ -269,11 +269,11 @@ void spawn_player(Player *player, s8 playerIndex, f32 startingRow, f32 startingC
|
||||
|
||||
gFrameSinceLastACombo[idx] = 0;
|
||||
gCountASwitch[idx] = 0;
|
||||
gIsPlayerTripleAButtonCombo[idx] = FALSE;
|
||||
gIsPlayerTripleAButtonCombo[idx] = false;
|
||||
gTimerBoostTripleACombo[idx] = 0;
|
||||
gFrameSinceLastBCombo[idx] = 0;
|
||||
gCountBChangement[idx] = 0;
|
||||
gIsPlayerTripleBButtonCombo[idx] = FALSE;
|
||||
gIsPlayerTripleBButtonCombo[idx] = false;
|
||||
gTimerBoostTripleBCombo[playerIndex] = 0;
|
||||
D_8018D900[0] = 0;
|
||||
|
||||
|
||||
+26
-26
@@ -211,9 +211,9 @@ UNUSED void func_80072214(s32 objectIndex, s32 arg1) {
|
||||
}
|
||||
|
||||
bool is_obj_flag_status_active(s32 objectIndex, s32 arg1) {
|
||||
s32 phi_v1 = FALSE;
|
||||
s32 phi_v1 = false;
|
||||
if ((gObjectList[objectIndex].status & arg1) != 0) {
|
||||
phi_v1 = TRUE;
|
||||
phi_v1 = true;
|
||||
}
|
||||
return phi_v1;
|
||||
}
|
||||
@@ -239,17 +239,17 @@ UNUSED void func_800722F8(s32 objectIndex, s32 arg1) {
|
||||
}
|
||||
|
||||
bool func_80072320(s32 objectIndex, s32 arg1) {
|
||||
s32 b = FALSE;
|
||||
s32 b = false;
|
||||
if ((gObjectList[objectIndex].unk_058 & arg1) != 0) {
|
||||
b = TRUE;
|
||||
b = true;
|
||||
}
|
||||
return b;
|
||||
}
|
||||
|
||||
bool func_80072354(s32 objectIndex, s32 arg1) {
|
||||
s32 b = FALSE;
|
||||
s32 b = false;
|
||||
if ((gObjectList[objectIndex].unk_058 & arg1) == 0) {
|
||||
b = TRUE;
|
||||
b = true;
|
||||
}
|
||||
return b;
|
||||
}
|
||||
@@ -600,7 +600,7 @@ s32 func_80072E54(s32 objectIndex, s32 arg1, s32 arg2, s32 arg3, s32 arg4, s32 a
|
||||
bool func_80072F88(s32 objectIndex, s32 arg1, s32 arg2, s32 arg3, s32 arg4, s32 arg5) {
|
||||
s32 sp24;
|
||||
|
||||
sp24 = FALSE;
|
||||
sp24 = false;
|
||||
if (is_obj_index_flag_status_inactive(objectIndex, 0x2000) != 0) {
|
||||
gObjectList[objectIndex].itemDisplay = arg1;
|
||||
gObjectList[objectIndex].unk_050 = arg4;
|
||||
@@ -621,7 +621,7 @@ bool func_80072F88(s32 objectIndex, s32 arg1, s32 arg2, s32 arg3, s32 arg4, s32
|
||||
set_object_flag_status_false(objectIndex, 0x2000);
|
||||
set_object_unk_0CB(objectIndex, 0);
|
||||
func_80072488(objectIndex);
|
||||
sp24 = TRUE;
|
||||
sp24 = true;
|
||||
} else {
|
||||
gObjectList[objectIndex].itemDisplay = arg1;
|
||||
}
|
||||
@@ -634,7 +634,7 @@ bool func_80072F88(s32 objectIndex, s32 arg1, s32 arg2, s32 arg3, s32 arg4, s32
|
||||
bool func_800730BC(s32 objectIndex, s32 arg1, s32 arg2, s32 arg3, s32 arg4, s32 arg5) {
|
||||
s32 sp24;
|
||||
|
||||
sp24 = FALSE;
|
||||
sp24 = false;
|
||||
if (is_obj_index_flag_status_inactive(objectIndex ,0x2000) != 0) {
|
||||
gObjectList[objectIndex].itemDisplay = arg1;
|
||||
gObjectList[objectIndex].unk_050 = arg4;
|
||||
@@ -665,7 +665,7 @@ bool func_800730BC(s32 objectIndex, s32 arg1, s32 arg2, s32 arg3, s32 arg4, s32
|
||||
set_object_flag_status_false(objectIndex, 0x2000);
|
||||
set_object_unk_0CB(objectIndex, 0);
|
||||
func_80072488(objectIndex);
|
||||
sp24 = TRUE;
|
||||
sp24 = true;
|
||||
} else {
|
||||
set_object_flag_status_false(objectIndex, 0x4000);
|
||||
set_object_flag_status_true(objectIndex, 0x80);
|
||||
@@ -814,7 +814,7 @@ void func_80073720(s32 objectIndex) {
|
||||
bool func_8007375C(s32 objectIndex, s32 arg1) {
|
||||
s32 sp24;
|
||||
|
||||
sp24 = FALSE;
|
||||
sp24 = false;
|
||||
if (is_obj_index_flag_status_inactive(objectIndex, 0x00008000) != 0) {
|
||||
gObjectList[objectIndex].unk_04C = arg1;
|
||||
set_object_flag_status_true(objectIndex, 0x00008000);
|
||||
@@ -823,7 +823,7 @@ bool func_8007375C(s32 objectIndex, s32 arg1) {
|
||||
if (gObjectList[objectIndex].unk_04C < 0) {
|
||||
set_object_flag_status_false(objectIndex, 0x00008000);
|
||||
func_80073654(objectIndex);
|
||||
sp24 = TRUE;
|
||||
sp24 = true;
|
||||
}
|
||||
return sp24;
|
||||
}
|
||||
@@ -893,7 +893,7 @@ UNUSED void func_800739CC(s32 arg0, s16* arg1, s32 arg2, s32 arg3, s32 arg4, s32
|
||||
bool func_80073A10(s32 objectIndex, s16* arg1, s32 arg2, s32 arg3, s32 arg4, s32 arg5, s32 arg6) {
|
||||
bool phi_t0;
|
||||
|
||||
phi_t0 = FALSE;
|
||||
phi_t0 = false;
|
||||
if (gObjectList[objectIndex].unk_0CF == 0) {
|
||||
*arg1 = arg2;
|
||||
gObjectList[objectIndex].unk_0AC = arg5;
|
||||
@@ -913,7 +913,7 @@ bool func_80073A10(s32 objectIndex, s16* arg1, s32 arg2, s32 arg3, s32 arg4, s32
|
||||
*arg1 = arg3;
|
||||
func_80073800(objectIndex, 0);
|
||||
func_8007381C(objectIndex);
|
||||
phi_t0 = TRUE;
|
||||
phi_t0 = true;
|
||||
} else {
|
||||
*arg1 = arg2;
|
||||
}
|
||||
@@ -937,7 +937,7 @@ s32 func_80073B34(s32 arg0, s16* arg1, s32 arg2, s32 arg3, s32 arg4, s32 arg5, s
|
||||
bool func_80073B78(s32 arg0, s32 objectIndex, s16* arg2, s32 arg3, s32 arg4, s32 arg5, s32 arg6, s32 arg7) {
|
||||
s32 phi_t0;
|
||||
|
||||
phi_t0 = FALSE;
|
||||
phi_t0 = false;
|
||||
if (gObjectList[objectIndex].unk_0CF == 0) {
|
||||
gObjectList[objectIndex].unk_0AC = arg6;
|
||||
if (arg0 != 0) {
|
||||
@@ -965,7 +965,7 @@ bool func_80073B78(s32 arg0, s32 objectIndex, s16* arg2, s32 arg3, s32 arg4, s32
|
||||
if (gObjectList[objectIndex].unk_0D0 == 0) {
|
||||
func_80073800(objectIndex, 0);
|
||||
func_8007381C(objectIndex);
|
||||
phi_t0 = TRUE;
|
||||
phi_t0 = true;
|
||||
} else {
|
||||
gObjectList[objectIndex].unk_0CF = 1;
|
||||
}
|
||||
@@ -1007,7 +1007,7 @@ bool func_80073E18(s32 objectIndex, u16* arg1, u16 arg2, s32 arg3) {
|
||||
bool phi_t0;
|
||||
s32 temp_v1;
|
||||
|
||||
phi_t0 = FALSE;
|
||||
phi_t0 = false;
|
||||
if (gObjectList[objectIndex].unk_0CF == 0) {
|
||||
func_80073800(objectIndex, 1);
|
||||
gObjectList[objectIndex].unk_048 = arg3;
|
||||
@@ -1017,7 +1017,7 @@ bool func_80073E18(s32 objectIndex, u16* arg1, u16 arg2, s32 arg3) {
|
||||
if (temp_v1 <= 0) {
|
||||
*arg1 += gObjectList[objectIndex].unk_048;
|
||||
func_80073800(objectIndex, 0);
|
||||
phi_t0 = TRUE;
|
||||
phi_t0 = true;
|
||||
} else {
|
||||
*arg1 += arg2;
|
||||
gObjectList[objectIndex].unk_048 = temp_v1;
|
||||
@@ -1030,7 +1030,7 @@ UNUSED bool func_80073ED4(s32 objectIndex, u16* arg1, u16 arg2, s32 arg3) {
|
||||
bool phi_t0;
|
||||
s32 temp_v1;
|
||||
|
||||
phi_t0 = FALSE;
|
||||
phi_t0 = false;
|
||||
if (gObjectList[objectIndex].unk_0CF == 0) {
|
||||
func_80073800(objectIndex, 1);
|
||||
gObjectList[objectIndex].unk_048 = arg3;
|
||||
@@ -1040,7 +1040,7 @@ UNUSED bool func_80073ED4(s32 objectIndex, u16* arg1, u16 arg2, s32 arg3) {
|
||||
if (temp_v1 <= 0) {
|
||||
*arg1 += gObjectList[objectIndex].unk_048;
|
||||
func_80073800(objectIndex, 0);
|
||||
phi_t0 = TRUE;
|
||||
phi_t0 = true;
|
||||
} else {
|
||||
*arg1 -= arg2;
|
||||
gObjectList[objectIndex].unk_048 = temp_v1;
|
||||
@@ -1068,7 +1068,7 @@ UNUSED void func_80074014(void) {
|
||||
bool func_8007401C(s32 objectIndex, f32* arg1, f32 arg2, f32 arg3, f32 arg4, s32 arg5, s32 arg6) {
|
||||
bool phi_a3;
|
||||
|
||||
phi_a3 = FALSE;
|
||||
phi_a3 = false;
|
||||
if (gObjectList[objectIndex].unk_0CD == 0) {
|
||||
*arg1 = arg2;
|
||||
gObjectList[objectIndex].unk_0AA = arg5;
|
||||
@@ -1087,7 +1087,7 @@ bool func_8007401C(s32 objectIndex, f32* arg1, f32 arg2, f32 arg3, f32 arg4, s32
|
||||
*arg1 = arg3;
|
||||
func_80073F90(objectIndex, 0);
|
||||
func_80073FAC(objectIndex);
|
||||
phi_a3 = TRUE;
|
||||
phi_a3 = true;
|
||||
} else {
|
||||
*arg1 = arg2;
|
||||
}
|
||||
@@ -3565,7 +3565,7 @@ void func_8007AA44(s32 playerId) {
|
||||
void func_8007ABFC(s32 playerId, bool arg1) {
|
||||
s32 itemWindow;
|
||||
|
||||
if (playerHUD[playerId].raceCompleteBool == FALSE) {
|
||||
if (playerHUD[playerId].raceCompleteBool == false) {
|
||||
itemWindow = gItemWindowObjectByPlayerId[playerId];
|
||||
if (func_80072354(itemWindow, 4) != 0) {
|
||||
init_object(itemWindow, 0);
|
||||
@@ -3646,11 +3646,11 @@ u8 gen_random_item(s16 rank, s16 isCpu)
|
||||
}
|
||||
|
||||
u8 gen_random_item_human(UNUSED s16 arg0, s16 rank) {
|
||||
return gen_random_item(rank, FALSE);
|
||||
return gen_random_item(rank, false);
|
||||
}
|
||||
|
||||
u8 kart_ai_gen_random_item(UNUSED s32 arg0, s16 rank) {
|
||||
return gen_random_item(rank, TRUE);
|
||||
return gen_random_item(rank, true);
|
||||
}
|
||||
|
||||
s16 func_8007AFB0(s32 objectIndex, s32 arg1) {
|
||||
@@ -5856,7 +5856,7 @@ void func_80080A4C(s32 objectIndex, s32 cameraPlayerId) {
|
||||
Player *player = &gPlayerOne[cameraPlayerId];
|
||||
|
||||
if (gScreenModeSelection != SCREEN_MODE_3P_4P_SPLITSCREEN) {
|
||||
if ((func_80072320(objectIndex, 0x00000010) != 0) && (is_within_horizontal_distance_of_player(objectIndex, player, 500.0f) != FALSE)) {
|
||||
if ((func_80072320(objectIndex, 0x00000010) != 0) && (is_within_horizontal_distance_of_player(objectIndex, player, 500.0f) != false)) {
|
||||
func_8001CA10(camera);
|
||||
func_800C98B8(gObjectList[objectIndex].pos, gObjectList[objectIndex].velocity, SOUND_ARG_LOAD(0x19, 0x00, 0x80, 0x0F));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user