diff --git a/examples/the-hat-chooses-the-wizard/src/main.rs b/examples/the-hat-chooses-the-wizard/src/main.rs index de8f3ea9..57ab5ec2 100644 --- a/examples/the-hat-chooses-the-wizard/src/main.rs +++ b/examples/the-hat-chooses-the-wizard/src/main.rs @@ -7,7 +7,8 @@ use agb::{ display::{ object::{Graphics, Object, ObjectController, Tag, TagMap}, tiled::{ - InfiniteScrolledMap, PartialUpdateStatus, TileFormat, TileSet, TileSetting, VRamManager, + InfiniteScrolledMap, PartialUpdateStatus, RegularBackgroundSize, TileFormat, TileSet, + TileSetting, VRamManager, }, Priority, HEIGHT, WIDTH, }, @@ -777,8 +778,8 @@ impl<'a, 'b, 'c> PlayingLevel<'a, 'b> { fn main(mut agb: agb::Gba) -> ! { let (tiled, mut vram) = agb.display.video.tiled0(); vram.set_background_palettes(tile_sheet::background.palettes); - let mut splash_screen = tiled.background(Priority::P0); - let mut world_display = tiled.background(Priority::P0); + let mut splash_screen = tiled.background(Priority::P0, RegularBackgroundSize::Background32x32); + let mut world_display = tiled.background(Priority::P0, RegularBackgroundSize::Background32x32); let tileset = TileSet::new(tile_sheet::background.tiles, TileFormat::FourBpp); @@ -845,7 +846,7 @@ fn main(mut agb: agb::Gba) -> ! { let map_current_level = current_level; let mut background = InfiniteScrolledMap::new( - tiled.background(Priority::P2), + tiled.background(Priority::P2, RegularBackgroundSize::Background32x32), Box::new(|pos: Vector2D| { let level = &map_tiles::LEVELS[map_current_level as usize]; ( @@ -860,7 +861,7 @@ fn main(mut agb: agb::Gba) -> ! { }), ); let mut foreground = InfiniteScrolledMap::new( - tiled.background(Priority::P0), + tiled.background(Priority::P0, RegularBackgroundSize::Background32x32), Box::new(|pos: Vector2D| { let level = &map_tiles::LEVELS[map_current_level as usize]; ( diff --git a/examples/the-purple-night/src/main.rs b/examples/the-purple-night/src/main.rs index 930f7cd9..6bb170ab 100644 --- a/examples/the-purple-night/src/main.rs +++ b/examples/the-purple-night/src/main.rs @@ -12,7 +12,10 @@ use alloc::{boxed::Box, vec::Vec}; use agb::{ display::{ object::{Graphics, Object, ObjectController, Sprite, Tag, TagMap}, - tiled::{InfiniteScrolledMap, TileFormat, TileSet, TileSetting, VRamManager}, + tiled::{ + InfiniteScrolledMap, RegularBackgroundSize, TileFormat, TileSet, TileSetting, + VRamManager, + }, Priority, HEIGHT, WIDTH, }, fixnum::{FixedNum, Rect, Vector2D}, @@ -2221,7 +2224,7 @@ fn game_with_level(gba: &mut agb::Gba) { let object = gba.display.object.get(); let backdrop = InfiniteScrolledMap::new( - background.background(Priority::P2), + background.background(Priority::P2, RegularBackgroundSize::Background32x32), Box::new(|pos| { ( &tileset, @@ -2235,7 +2238,7 @@ fn game_with_level(gba: &mut agb::Gba) { ); let foreground = InfiniteScrolledMap::new( - background.background(Priority::P0), + background.background(Priority::P0, RegularBackgroundSize::Background32x32), Box::new(|pos| { ( &tileset, @@ -2249,7 +2252,7 @@ fn game_with_level(gba: &mut agb::Gba) { ); let clouds = InfiniteScrolledMap::new( - background.background(Priority::P3), + background.background(Priority::P3, RegularBackgroundSize::Background32x32), Box::new(|pos| { ( &tileset,