@@ -23,7 +23,7 @@ procedure Eepers is
23
23
24
24
type Footsteps_Range is mod 4 ;
25
25
Footsteps_Sounds: array (Footsteps_Range) of Sound;
26
- Footsteps_Pitches: constant array (Footsteps_Range) of C_Float := [ 1.7 , 1.6 , 1.5 , 1.4 ] ;
26
+ Footsteps_Pitches: constant array (Footsteps_Range) of C_Float := ( 1.7 , 1.6 , 1.5 , 1.4 ) ;
27
27
package Random_Footsteps is
28
28
new Ada.Numerics.Discrete_Random(Result_Subtype => Footsteps_Range);
29
29
Footsteps_Gen: Random_Footsteps.Generator;
@@ -67,8 +67,8 @@ procedure Eepers is
67
67
return Color_From_HSV(H, S, V);
68
68
end ;
69
69
70
- Palette_RGB: array (Palette) of Color := [ others => (A => 255 , others => 0 )] ;
71
- Palette_HSV: array (Palette) of HSV := [ others => [ others => 0 ]] ;
70
+ Palette_RGB: array (Palette) of Color := ( others => (A => 255 , others => 0 )) ;
71
+ Palette_HSV: array (Palette) of HSV := ( others => ( others => 0 )) ;
72
72
73
73
package Double_IO is new Ada.Text_IO.Float_IO(Double);
74
74
@@ -228,34 +228,34 @@ procedure Eepers is
228
228
type Eye_Mesh is new Vector2_Array(1 ..4 );
229
229
type Eye is (Left_Eye, Right_Eye);
230
230
type Eyes_Mesh is array (Eye) of Eye_Mesh;
231
- Eyes_Meshes: constant array (Eyes_Kind) of Eyes_Mesh := [
232
- Eyes_Open => [
231
+ Eyes_Meshes: constant array (Eyes_Kind) of Eyes_Mesh := (
232
+ Eyes_Open => (
233
233
-- 1-3
234
234
-- |/|
235
235
-- 2-4
236
- Left_Eye => [ (0.0 , 0.0 ), (0.0 , 1.0 ), (1.0 , 0.0 ), (1.0 , 1.0 ) ] ,
236
+ Left_Eye => ( (0.0 , 0.0 ), (0.0 , 1.0 ), (1.0 , 0.0 ), (1.0 , 1.0 ) ) ,
237
237
-- 3-4
238
238
-- |\|
239
239
-- 1-2
240
- Right_Eye => [ (0.0 , 1.0 ), (1.0 , 1.0 ), (0.0 , 0.0 ), (1.0 , 0.0 ) ]
241
- ] ,
242
- Eyes_Closed => [
243
- Left_Eye => [ (0.0 , 0.8 ), (0.0 , 1.0 ), (1.0 , 0.8 ), (1.0 , 1.0 ) ] ,
244
- Right_Eye => [ (0.0 , 1.0 ), (1.0 , 1.0 ), (0.0 , 0.8 ), (1.0 , 0.8 ) ]
245
- ] ,
246
- Eyes_Angry => [
247
- Left_Eye => [ (0.0 , 0.0 ), (0.0 , 1.0 ), (1.0 , 0.3 ), (1.0 , 1.0 ) ] ,
248
- Right_Eye => [ (0.0 , 1.0 ), (1.0 , 1.0 ), (0.0 , 0.3 ), (1.0 , 0.0 ) ]
249
- ] ,
250
- Eyes_Cringe => [
251
- Left_Eye => [ (0.0 , 0.5 ), (0.25 , 0.75 ), (1.3 , 0.75 ), (0.0 , 1.0 ) ] ,
252
- Right_Eye => [ (1.0 , 1.0 ), (0.75 , 0.75 ), (-0.3 , 0.75 ), (1.0 , 0.5 ) ]
253
- ] ,
254
- Eyes_Surprised => [
255
- Left_Eye => [ (0.0 , 0.3 ), (0.0 , 1.0 ), (1.0 , 0.3 ), (1.0 , 1.0 ) ] ,
256
- Right_Eye => [ (0.0 , 1.0 ), (1.0 , 1.0 ), (0.0 , 0.0 ), (1.0 , 0.0 ) ]
257
- ]
258
- ] ;
240
+ Right_Eye => ( (0.0 , 1.0 ), (1.0 , 1.0 ), (0.0 , 0.0 ), (1.0 , 0.0 ) )
241
+ ) ,
242
+ Eyes_Closed => (
243
+ Left_Eye => ( (0.0 , 0.8 ), (0.0 , 1.0 ), (1.0 , 0.8 ), (1.0 , 1.0 ) ) ,
244
+ Right_Eye => ( (0.0 , 1.0 ), (1.0 , 1.0 ), (0.0 , 0.8 ), (1.0 , 0.8 ) )
245
+ ) ,
246
+ Eyes_Angry => (
247
+ Left_Eye => ( (0.0 , 0.0 ), (0.0 , 1.0 ), (1.0 , 0.3 ), (1.0 , 1.0 ) ) ,
248
+ Right_Eye => ( (0.0 , 1.0 ), (1.0 , 1.0 ), (0.0 , 0.3 ), (1.0 , 0.0 ) )
249
+ ) ,
250
+ Eyes_Cringe => (
251
+ Left_Eye => ( (0.0 , 0.5 ), (0.25 , 0.75 ), (1.3 , 0.75 ), (0.0 , 1.0 ) ) ,
252
+ Right_Eye => ( (1.0 , 1.0 ), (0.75 , 0.75 ), (-0.3 , 0.75 ), (1.0 , 0.5 ) )
253
+ ) ,
254
+ Eyes_Surprised => (
255
+ Left_Eye => ( (0.0 , 0.3 ), (0.0 , 1.0 ), (1.0 , 0.3 ), (1.0 , 1.0 ) ) ,
256
+ Right_Eye => ( (0.0 , 1.0 ), (1.0 , 1.0 ), (0.0 , 0.0 ), (1.0 , 0.0 ) )
257
+ )
258
+ ) ;
259
259
260
260
type Player_State is record
261
261
Prev_Position: IVector2;
@@ -341,11 +341,11 @@ procedure Eepers is
341
341
342
342
type Direction is (Left, Right, Up, Down);
343
343
344
- Direction_Vector: constant array (Direction) of IVector2 := [
344
+ Direction_Vector: constant array (Direction) of IVector2 := (
345
345
Left => (X => -1 , Y => 0 ),
346
346
Right => (X => 1 , Y => 0 ),
347
347
Up => (X => 0 , Y => -1 ),
348
- Down => (X => 0 , Y => 1 )] ;
348
+ Down => (X => 0 , Y => 1 )) ;
349
349
350
350
function Inside_Of_Rect (Start, Size, Point: in IVector2) return Boolean is
351
351
begin
@@ -578,7 +578,7 @@ procedure Eepers is
578
578
Level_Key,
579
579
Level_Player,
580
580
Level_Father);
581
- Level_Cell_Color: constant array (Level_Cell) of Color := [
581
+ Level_Cell_Color: constant array (Level_Cell) of Color := (
582
582
Level_None => Get_Color(16#00000000# ),
583
583
Level_Gnome => Get_Color(16#FF9600FF# ),
584
584
Level_Mother => Get_Color(16#96FF00FF# ),
@@ -591,7 +591,7 @@ procedure Eepers is
591
591
Level_Barricade => Get_Color(16#FF0096FF# ),
592
592
Level_Key => Get_Color(16#FFFF00FF# ),
593
593
Level_Player => Get_Color(16#0000FFFF# ),
594
- Level_Father => Get_Color(16#265FDAFF# )] ;
594
+ Level_Father => Get_Color(16#265FDAFF# )) ;
595
595
596
596
function Cell_By_Color (Col: Color; Out_Cel: out Level_Cell) return Boolean is
597
597
begin
@@ -897,12 +897,12 @@ procedure Eepers is
897
897
end loop ;
898
898
end ;
899
899
900
- Keys: constant array (Direction) of int := [
900
+ Keys: constant array (Direction) of int := (
901
901
Left => KEY_A,
902
902
Right => KEY_D,
903
903
Up => KEY_W,
904
904
Down => KEY_S
905
- ] ;
905
+ ) ;
906
906
907
907
procedure Game_Update_Camera (Game: in out Game_State) is
908
908
Camera_Target: constant Vector2 :=
@@ -1209,10 +1209,10 @@ procedure Eepers is
1209
1209
Eyes_Size: constant Vector2 := Eyes_Ratio*Size;
1210
1210
Center: constant Vector2 := Start + Size*0.5 ;
1211
1211
Position: constant Vector2 := Center + Dir*Eyes_Size.X*0.6 ;
1212
- Positions: constant array (Eye) of Vector2 := [
1212
+ Positions: constant array (Eye) of Vector2 := (
1213
1213
Left_Eye => Position - Eyes_Size*(0.5 , 0.0 ) - Eyes_Size*(1.0 , 0.5 ),
1214
1214
Right_Eye => Position + Eyes_Size*(0.5 , 0.0 ) - Eyes_Size*(0.0 , 0.5 )
1215
- ] ;
1215
+ ) ;
1216
1216
Mesh: Eye_Mesh;
1217
1217
begin
1218
1218
for Eye_Index in Eye loop
@@ -1502,7 +1502,7 @@ begin
1502
1502
TURN_DURATION_SECS := BASE_TURN_DURATION_SECS;
1503
1503
end if ;
1504
1504
end if ;
1505
-
1505
+
1506
1506
Any_Key_Pressed := False;
1507
1507
while not Any_Key_Pressed and then Get_Key_Pressed /= KEY_NULL loop
1508
1508
Any_Key_Pressed := True;
@@ -1659,8 +1659,8 @@ end;
1659
1659
-- TODO: Visual Clue that the Eeper is about to kill the Player when Completely outside of the Screen
1660
1660
-- - Cooldown ball is shaking
1661
1661
-- TODO: Cool animation for New Game
1662
- -- TODO: Tutorial
1663
- -- - Sign that says "WASD" to move when you start the game for the first time.
1662
+ -- TODO: Tutorial
1663
+ -- - Sign that says "WASD" to move when you start the game for the first time.
1664
1664
-- - And how to place the bomb on picking it up.
1665
1665
-- - How to sprint after you blow up firt Barricade.
1666
1666
-- TODO: Count the player's turns towards the final score of the game
0 commit comments