summaryrefslogtreecommitdiff
path: root/test.adb
diff options
context:
space:
mode:
authorrexim <reximkut@gmail.com>2024-03-16 00:54:30 +0700
committerrexim <reximkut@gmail.com>2024-03-16 00:54:30 +0700
commit3b300217a153227beb69dcc2c8bbaa8048da6fc0 (patch)
tree9b8f2c8dbf1971ef200a8adb441f580e07afd1ed /test.adb
parent7c1dfaa1f57c26d59d86538ab84ea52bb866b3ce (diff)
Recompute_Shrek_Path -> Recompute_Path_For_Body
Deshrek the Path Finding function. Now it should be usable for more bosses.
Diffstat (limited to 'test.adb')
-rw-r--r--test.adb19
1 files changed, 14 insertions, 5 deletions
diff --git a/test.adb b/test.adb
index 490bb22..115d24e 100644
--- a/test.adb
+++ b/test.adb
@@ -6,10 +6,19 @@ with Ada.Containers.Vectors;
with Ada.Strings.Unbounded; use Ada.Strings.Unbounded;
procedure Test is
- Map: array (1..10, 1..20) of Integer := [others => [others => 0]];
- Index: array (1..2) of Integer;
+ type State is record
+ X: Integer;
+ Y: Integer;
+ end record;
+
+ procedure Foo(S: in State; V: out Integer) is
+ begin
+ V := S.X*2;
+ end;
+
+ S: State := (X => 69, Y => 420);
begin
- if Index in Map then
- Map() := 1;
- end if;
+ Put_Line(S'Image);
+ Foo(S, S.Y);
+ Put_Line(S'Image);
end;