diff --git a/README.adoc b/README.adoc index 4e8c36f..b4bf3db 100644 --- a/README.adoc +++ b/README.adoc @@ -1,3 +1,5 @@ -= Flappybit += Gamebit -Flappybit for the micro.bit +Gamebit is a set of games and tools for building games using a +link:https://microbit.co.uk[micro:bit] and a +link:https://www.waveshare.com/wiki/1.8inch_LCD_for_micro:bit[Waveshare 1.8 LCD] diff --git a/flappybit.gpr b/gamebit.gpr similarity index 94% rename from flappybit.gpr rename to gamebit.gpr index 83fc024..06ff0e2 100644 --- a/flappybit.gpr +++ b/gamebit.gpr @@ -1,7 +1,6 @@ with "contrib/Ada_Drivers_Library/boards/MicroBit/microbit_zfp.gpr"; -project Flappybit is - +project Gamebit is for Runtime ("ada") use "zfp-microbit"; for Target use "arm-eabi"; for Main use ("main.adb"); @@ -23,4 +22,4 @@ project Flappybit is for Connection_Tool use "pyocd"; end Ide; -end Flappybit; +end Gamebit; diff --git a/src/flappybit-lcd.adb b/src/gamebit-lcd.adb similarity index 98% rename from src/flappybit-lcd.adb rename to src/gamebit-lcd.adb index 222505b..2b83c8a 100644 --- a/src/flappybit-lcd.adb +++ b/src/gamebit-lcd.adb @@ -2,7 +2,7 @@ with HAL.GPIO; with MicroBit.IOs; -package body Flappybit.LCD is +package body Gamebit.LCD is procedure Initialize is begin @@ -104,4 +104,4 @@ package body Flappybit.LCD is end Update; -end Flappybit.LCD; +end Gamebit.LCD; diff --git a/src/flappybit-lcd.ads b/src/gamebit-lcd.ads similarity index 95% rename from src/flappybit-lcd.ads rename to src/gamebit-lcd.ads index c82c403..2ea7798 100644 --- a/src/flappybit-lcd.ads +++ b/src/gamebit-lcd.ads @@ -7,7 +7,7 @@ with ST7735R; use ST7735R; with HAL.Bitmap; -package Flappybit.LCD is +package Gamebit.LCD is Height : constant Positive := 160; Width : constant Positive := 128; @@ -33,4 +33,4 @@ package Flappybit.LCD is procedure Update with Pre => Initialized; -end Flappybit.LCD; +end Gamebit.LCD; diff --git a/src/flappybit-sprites.adb b/src/gamebit-sprites.adb similarity index 97% rename from src/flappybit-sprites.adb rename to src/gamebit-sprites.adb index 2a746b0..6ca83e3 100644 --- a/src/flappybit-sprites.adb +++ b/src/gamebit-sprites.adb @@ -1,6 +1,6 @@ with HAL.Bitmap; use HAL.Bitmap; -package body Flappybit.Sprites is +package body Gamebit.Sprites is function Height (B : in Bird) return Positive is pragma Unreferenced (B); @@ -68,4 +68,4 @@ package body Flappybit.Sprites is B.Buffer := Buffer; end Set_Framebuffer; -end Flappybit.Sprites; +end Gamebit.Sprites; diff --git a/src/flappybit-sprites.ads b/src/gamebit-sprites.ads similarity index 79% rename from src/flappybit-sprites.ads rename to src/gamebit-sprites.ads index f68e482..647b9d4 100644 --- a/src/flappybit-sprites.ads +++ b/src/gamebit-sprites.ads @@ -1,13 +1,13 @@ with HAL.Bitmap; -with Flappybit; +with Gamebit; -package Flappybit.Sprites is +package Gamebit.Sprites is type Direction is (Left, Right, Up, Down); - type Bird is new Flappybit.Sprite with private; + type Bird is new Gamebit.Sprite with private; function Height (B : in Bird) return Positive; function Width (B : in Bird) return Positive; function Position (B : in Bird) return Point; @@ -18,7 +18,7 @@ package Flappybit.Sprites is private - type Bird is new Flappybit.Sprite with record + type Bird is new Gamebit.Sprite with record Buffer : HAL.Bitmap.Any_Bitmap_Buffer; Alive : Boolean := True; Trajectory : Direction := Left; @@ -27,4 +27,4 @@ private Y : Natural; end record; -end Flappybit.Sprites; +end Gamebit.Sprites; diff --git a/src/flappybit.ads b/src/gamebit.ads similarity index 94% rename from src/flappybit.ads rename to src/gamebit.ads index a5f6f04..d34cc1f 100644 --- a/src/flappybit.ads +++ b/src/gamebit.ads @@ -1,7 +1,7 @@ with HAL.Bitmap; -package Flappybit is +package Gamebit is type Point is record X : Natural; @@ -25,4 +25,4 @@ package Flappybit is procedure Set_Framebuffer (S : in out Sprite; Framebuffer : in HAL.Bitmap.Any_Bitmap_Buffer ) is abstract; -end Flappybit; +end Gamebit; diff --git a/src/main.adb b/src/main.adb index 86d613c..b60bfe9 100644 --- a/src/main.adb +++ b/src/main.adb @@ -1,13 +1,13 @@ -with Flappybit.LCD; use Flappybit.LCD; -with HAL.Bitmap; use HAL.Bitmap; +with Gamebit.LCD; use Gamebit.LCD; +with HAL.Bitmap; -with Flappybit.Sprites; +with Gamebit.Sprites; procedure Main is - Bird : Flappybit.Sprites.Bird; - Background : constant Bitmap_Color := Black; + Bird : Gamebit.Sprites.Bird; + Background : constant HAL.Bitmap.Bitmap_Color := HAL.Bitmap.Black; begin Initialize;