Gamebit/src/gamebit.ads

29 lines
704 B
Ada

with HAL.Bitmap;
package Gamebit is
type Point is record
X : Natural;
Y : Natural;
end record;
type Rectangle is record
Origin : Point;
Width : Positive;
Height : Positive;
end record;
type Sprite is interface;
function Height (S : in Sprite) return Positive is abstract;
function Width (S : in Sprite) return Positive is abstract;
function Position (S : in Sprite) return Point is abstract;
procedure Tick (S : in out Sprite) is abstract;
-- Perform the Sprite's "work" during the runloop
procedure Set_Framebuffer (S : in out Sprite; Framebuffer : in HAL.Bitmap.Any_Bitmap_Buffer ) is abstract;
end Gamebit;