diff --git a/src/processor/memory/mmio/gpu.rs b/src/processor/memory/mmio/gpu.rs index a4e656a..52033e7 100644 --- a/src/processor/memory/mmio/gpu.rs +++ b/src/processor/memory/mmio/gpu.rs @@ -266,6 +266,9 @@ impl Gpu { }, oam_location: (i - 0xFE00) as u8, }); + if objs.len() >= 10 { + break; + } } } objs.sort_by_key(|o| { @@ -275,7 +278,6 @@ impl Gpu { v }); objs.reverse(); - objs.truncate(11); objs }