Reality check and bit hacking...

This commit is contained in:
Ognjen Milan Robovic 2024-03-24 07:46:56 -04:00
parent 4dfb96e3ad
commit c6ba77627d
3 changed files with 40 additions and 6 deletions

View File

@ -13,6 +13,13 @@ package body ai is
------------------------------------------------------------------------------------------
procedure synchronize is
begin
core.echo (core.failure, "No AI yet folk!");
end synchronize;
------------------------------------------------------------------------------------------
procedure action_none is begin null; end action_none;
procedure action_walk is begin null; end action_walk;
procedure action_talk is begin null; end action_talk;

View File

@ -8,10 +8,31 @@ package ai is
none, walk, talk, find
);
type mind_limit is (
thirst, hunger, fatigue, solitude,
);
subtype string_16 is string (1 .. 16);
envy : constant natural := 2#00000001#;
gluttony : constant natural := 2#00000010#;
greed : constant natural := 2#00000100#;
lust : constant natural := 2#00001000#;
pride : constant natural := 2#00010000#;
sloth : constant natural := 2#00100000#;
wrath : constant natural := 2#01000000#;
thirst : constant natural := 2#00000001#;
hunger : constant natural := 2#00000010#;
fatigue : constant natural := 2#00000100#;
solitude : constant natural := 2#00001000#;
health : constant natural := 2#00010000#;
mana : constant natural := 2#00100000#;
boredom : constant natural := 2#01000000#;
agent_digit : constant natural := 4;
agent_state : constant natural := 8;
agent_state : constant natural := 4;
agent_count : constant natural := 4;
type name_limit is mod 400;
type clan_limit is mod 120;
@ -29,6 +50,11 @@ package ai is
name : name_limit;
clan : clan_limit;
data : data_limit;
soul : soul_limit;
mind : mind_limit;
work : action;
x : natural;
y : natural;
end record;
------------------------------------------------------------------------------------------
@ -39,10 +65,10 @@ package ai is
procedure action_find;
action_array : constant array (action) of action_data := (
(4#00000000#, action_none'access, "standing "),
(4#00000000#, action_walk'access, "walking "),
(4#00000000#, action_talk'access, "talking "),
(4#00000000#, action_find'access, "finding ")
(4#3000#, action_none'access, "standing "),
(4#3000#, action_walk'access, "walking "),
(4#3000#, action_talk'access, "talking "),
(4#3000#, action_find'access, "finding ")
);
male_name_array : constant array (name_limit) of string_16 := (
@ -174,6 +200,7 @@ package ai is
------------------------------------------------------------------------------------------
procedure configure;
procedure synchronize;
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

View File

@ -499,7 +499,7 @@ package body core is
function window_height return integer is begin return get_screen_height; end window_height;
------------------------------------------------------------------------------------------
--~base ::= A|B|C|D|E|F|G|H|I|J|K|L|M|N|O|P|Q|R|S|T|U|V|W|X|Y|Z;
procedure initialize is
begin
core.echo (core.comment, "Initializing core components...");