mirror of
https://github.com/italicsjenga/agb.git
synced 2024-12-23 08:11:33 +11:00
Fix build errors
This commit is contained in:
parent
25ee876932
commit
df75d1ce8c
|
@ -25,7 +25,7 @@ fn main(mut gba: Gba) -> ! {
|
||||||
|
|
||||||
{
|
{
|
||||||
if let Some(channel) = mixer.channel(&channel_id) {
|
if let Some(channel) = mixer.channel(&channel_id) {
|
||||||
let half: Num<i16, 4> = num!(0.5);
|
let half: Num<i16, 8> = num!(0.5);
|
||||||
let half_usize: Num<u32, 8> = num!(0.5);
|
let half_usize: Num<u32, 8> = num!(0.5);
|
||||||
match input.x_tri() {
|
match input.x_tri() {
|
||||||
Tri::Negative => channel.panning(-half),
|
Tri::Negative => channel.panning(-half),
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
use agb::fixnum::Num;
|
use agb::fixnum::num;
|
||||||
use agb::rng;
|
use agb::rng;
|
||||||
use agb::sound::mixer::{ChannelId, Mixer, SoundChannel};
|
use agb::sound::mixer::{ChannelId, Mixer, SoundChannel};
|
||||||
|
|
||||||
|
@ -98,8 +98,7 @@ impl<'a> Sfx<'a> {
|
||||||
|
|
||||||
pub fn slime_boing(&mut self) {
|
pub fn slime_boing(&mut self) {
|
||||||
let mut channel = SoundChannel::new(SLIME_BOING);
|
let mut channel = SoundChannel::new(SLIME_BOING);
|
||||||
let one: Num<i16, 4> = 1.into();
|
channel.volume(num!(0.25));
|
||||||
channel.volume(one / 4);
|
|
||||||
self.mixer.play_sound(channel);
|
self.mixer.play_sound(channel);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue