summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorrexim <reximkut@gmail.com>2024-03-16 01:59:08 +0700
committerrexim <reximkut@gmail.com>2024-03-16 01:59:08 +0700
commite3c746f58c1bb604f174ef76442385918ea5904b (patch)
tree952da451678fcfa81e05ef13b089d6f15dc05424
parentdcfd9a20ccd9fcabd02f78ced02657e54a693756 (diff)
Introduce Urmom color to the Palette
-rw-r--r--colors.txt1
-rw-r--r--game.adb8
-rw-r--r--map.txt2
3 files changed, 8 insertions, 3 deletions
diff --git a/colors.txt b/colors.txt
index f192938..208410d 100644
--- a/colors.txt
+++ b/colors.txt
@@ -8,6 +8,7 @@ Key 25 255 255
Bomb 0 255 255
Label 0 0 255
Shrek 60 255 255
+Urmom 242 196 212
Checkpoint 213 255 255
Explosion 213 255 255
Healthbar 0 255 255
diff --git a/game.adb b/game.adb
index 5919f39..70a56fc 100644
--- a/game.adb
+++ b/game.adb
@@ -26,6 +26,7 @@ procedure Game is
COLOR_BOMB,
COLOR_LABEL,
COLOR_SHREK,
+ COLOR_URMOM,
COLOR_CHECKPOINT,
COLOR_EXPLOSION,
COLOR_HEALTHBAR);
@@ -41,6 +42,7 @@ procedure Game is
COLOR_BOMB => To_Unbounded_String("Bomb"),
COLOR_LABEL => To_Unbounded_String("Label"),
COLOR_SHREK => To_Unbounded_String("Shrek"),
+ COLOR_URMOM => To_Unbounded_String("Urmom"),
COLOR_CHECKPOINT => To_Unbounded_String("Checkpoint"),
COLOR_EXPLOSION => To_Unbounded_String("Explosion"),
COLOR_HEALTHBAR => To_Unbounded_String("Healthbar")
@@ -231,7 +233,7 @@ procedure Game is
Dead: Boolean := True;
Prev_Position: IVector2;
Position: IVector2;
- Background: Color;
+ Background: Palette;
Size: IVector2 := (3, 3);
Health: Float := 1.0;
Attack_Cooldown: Integer := SHREK_ATTACK_COOLDOWN;
@@ -477,6 +479,7 @@ procedure Game is
for Boss of Game.Bosses loop
if Boss.Dead then
Boss.Dead := False;
+ Boss.Background := COLOR_URMOM;
Boss.Position := (Column, Row);
Boss.Prev_Position := (Column, Row);
Boss.Health := 1.0;
@@ -488,6 +491,7 @@ procedure Game is
when 'B' =>
for Boss of Game.Bosses loop
if Boss.Dead then
+ Boss.Background := COLOR_SHREK;
Boss.Dead := False;
Boss.Position := (Column, Row);
Boss.Prev_Position := (Column, Row);
@@ -896,7 +900,7 @@ procedure Game is
Size: constant Vector2 := To_Vector2(Boss.Size)*Cell_Size;
begin
if not Boss.Dead then
- Draw_Rectangle_V(Position, Cell_Size*To_Vector2(Boss.Size), Palette_RGB(COLOR_SHREK));
+ Draw_Rectangle_V(Position, Cell_Size*To_Vector2(Boss.Size), Palette_RGB(Boss.Background));
Health_Bar(Position, Size, C_Float(Boss.Health));
Draw_Number(Position, Size, Boss.Attack_Cooldown, (A => 255, others => 0));
end if;
diff --git a/map.txt b/map.txt
index cc8a04f..72e47ad 100644
--- a/map.txt
+++ b/map.txt
@@ -34,7 +34,7 @@
#...#
####################################### #...#
#.....................................# #...#
- #.....................................# #...#
+ #...@.................................# #...#
#...#####.....................#####...# #...#
#...#####.....................#####...# #...#
#...#####.....................#####...# #...#