From 6bafa3ebab300b3aae5360150f15387ca3e736cc Mon Sep 17 00:00:00 2001 From: Corwin Date: Tue, 22 Feb 2022 20:16:51 +0000 Subject: [PATCH] use public api --- agb/examples/chicken.rs | 60 ++++++++++++++++++++--------------------- 1 file changed, 30 insertions(+), 30 deletions(-) diff --git a/agb/examples/chicken.rs b/agb/examples/chicken.rs index 9113ea56..1e5882b4 100644 --- a/agb/examples/chicken.rs +++ b/agb/examples/chicken.rs @@ -248,60 +248,60 @@ static ChickenPalette: Palette16 = Palette16::new([0x7C1E, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]); static ChickenSprites: &[Sprite] = &[ - Sprite { - palette: &ChickenPalette, - data: &[ + Sprite::new( + &ChickenPalette, + &[ 0x00, 0x00, 0x10, 0x01, 0x00, 0x00, 0x10, 0x11, 0x10, 0x00, 0x10, 0x01, 0x10, 0x11, 0x11, 0x01, 0x10, 0x11, 0x11, 0x01, 0x00, 0x10, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x10, 0x01, 0x00, ], - size: Size::S8x8, - }, - Sprite { - palette: &ChickenPalette, - data: &[ + Size::S8x8, + ), + Sprite::new( + &ChickenPalette, + &[ 0x00, 0x00, 0x10, 0x01, 0x00, 0x00, 0x10, 0x11, 0x10, 0x00, 0x10, 0x01, 0x10, 0x11, 0x11, 0x01, 0x10, 0x11, 0x11, 0x01, 0x00, 0x01, 0x01, 0x00, 0x00, 0x01, 0x10, 0x00, 0x10, 0x00, 0x00, 0x00, ], - size: Size::S8x8, - }, - Sprite { - palette: &ChickenPalette, - data: &[ + Size::S8x8, + ), + Sprite::new( + &ChickenPalette, + &[ 0x00, 0x00, 0x10, 0x01, 0x00, 0x00, 0x10, 0x11, 0x10, 0x00, 0x10, 0x01, 0x10, 0x11, 0x11, 0x01, 0x10, 0x11, 0x11, 0x01, 0x00, 0x10, 0x01, 0x00, 0x10, 0x01, 0x10, 0x00, 0x00, 0x00, 0x10, 0x00, ], - size: Size::S8x8, - }, - Sprite { - palette: &ChickenPalette, - data: &[ + Size::S8x8, + ), + Sprite::new( + &ChickenPalette, + &[ 0x00, 0x00, 0x10, 0x01, 0x00, 0x00, 0x10, 0x11, 0x10, 0x00, 0x10, 0x01, 0x10, 0x11, 0x11, 0x01, 0x10, 0x11, 0x11, 0x01, 0x00, 0x10, 0x01, 0x00, 0x00, 0x11, 0x01, 0x00, 0x00, 0x10, 0x00, 0x00, ], - size: Size::S8x8, - }, - Sprite { - palette: &ChickenPalette, - data: &[ + Size::S8x8, + ), + Sprite::new( + &ChickenPalette, + &[ 0x00, 0x00, 0x10, 0x01, 0x00, 0x11, 0x11, 0x11, 0x10, 0x10, 0x11, 0x01, 0x10, 0x11, 0x11, 0x01, 0x10, 0x11, 0x11, 0x01, 0x00, 0x10, 0x01, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, ], - size: Size::S8x8, - }, - Sprite { - palette: &ChickenPalette, - data: &[ + Size::S8x8, + ), + Sprite::new( + &ChickenPalette, + &[ 0x00, 0x00, 0x10, 0x01, 0x00, 0x00, 0x10, 0x11, 0x10, 0x11, 0x11, 0x01, 0x10, 0x11, 0x11, 0x01, 0x10, 0x11, 0x11, 0x01, 0x00, 0x10, 0x01, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, ], - size: Size::S8x8, - }, + Size::S8x8, + ), ]; static MAP_TILES: [u32; 8 * 17] = [