From 3b300217a153227beb69dcc2c8bbaa8048da6fc0 Mon Sep 17 00:00:00 2001 From: rexim Date: Sat, 16 Mar 2024 00:54:30 +0700 Subject: Recompute_Shrek_Path -> Recompute_Path_For_Body Deshrek the Path Finding function. Now it should be usable for more bosses. --- test.adb | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) (limited to 'test.adb') 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; -- cgit v1.2.3