mirror of
https://github.com/italicsjenga/agb.git
synced 2024-12-24 08:41:34 +11:00
Remove pointless casts
This commit is contained in:
parent
faed7b456f
commit
fe2e480f28
|
@ -40,7 +40,7 @@ trait TiledMapPrivate: TiledMapTypes {
|
||||||
unsafe { MemoryMapped::new(0x0400_0008 + 2 * self.background_id()) }
|
unsafe { MemoryMapped::new(0x0400_0008 + 2 * self.background_id()) }
|
||||||
}
|
}
|
||||||
fn screenblock_memory(&self) -> *mut u16 {
|
fn screenblock_memory(&self) -> *mut u16 {
|
||||||
(0x0600_0000 + 0x1000 * self.screenblock() as usize / 2) as *mut u16
|
(0x0600_0000 + 0x1000 * self.screenblock() / 2) as *mut u16
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -333,7 +333,7 @@ impl VRamManager {
|
||||||
|
|
||||||
pub(crate) fn gc(&mut self) {
|
pub(crate) fn gc(&mut self) {
|
||||||
for tile_index in self.indices_to_gc.drain(..) {
|
for tile_index in self.indices_to_gc.drain(..) {
|
||||||
let key = tile_index.refcount_key() as usize;
|
let key = tile_index.refcount_key();
|
||||||
if self.reference_counts[key].current_count() > 0 {
|
if self.reference_counts[key].current_count() > 0 {
|
||||||
continue; // it has since been added back
|
continue; // it has since been added back
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue