Clean up some float literals (#972)

* floats are fun

* more cleanup

* one more bit

* format

* merge kankyo

* Update src/overlays/actors/ovl_En_Horse/z_en_horse.c

Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com>

* Update src/overlays/actors/ovl_En_Mm/z_en_mm.c

Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com>

Co-authored-by: petrie911 <pmontag@DESKTOP-LG8A167.localdomain>
Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com>
This commit is contained in:
petrie911
2021-11-01 18:29:47 -05:00
committed by GitHub
parent 8e57f3bca3
commit cb43f256f3
19 changed files with 352 additions and 347 deletions
+3 -3
View File
@@ -79,7 +79,7 @@ void Audio_InitNoteSub(Note* note, NoteSubEu* sub, NoteSubAttributes* attrs) {
} else if (gAudioContext.soundMode == 3) {
sub->bitField0.s.stereoHeadsetEffects = false;
sub->bitField0.s.usesHeadsetPanEffects = false;
volLeft = 0.707f;
volLeft = 0.707f; // approx 1/sqrt(2)
volRight = 0.707f;
} else {
sub->bitField0.s.stereoStrongRight = sp24.strongRight;
@@ -91,8 +91,8 @@ void Audio_InitNoteSub(Note* note, NoteSubEu* sub, NoteSubAttributes* attrs) {
vel = 0.0f > vel ? 0.0f : vel;
vel = 1.0f < vel ? 1.0f : vel;
sub->targetVolLeft = (s32)((vel * volLeft) * 4095.999f);
sub->targetVolRight = (s32)((vel * volRight) * 4095.999f);
sub->targetVolLeft = (s32)((vel * volLeft) * (0x1000 - 0.001f));
sub->targetVolRight = (s32)((vel * volRight) * (0x1000 - 0.001f));
sub->unk_2 = attrs->unk_1;
sub->filter = attrs->filter;