xabina/item.ads
2023-10-15 15:08:24 -04:00

111 lines
7.7 KiB
Ada

------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
-- Copyright (c) 2023 - Ognjen 'xolatile' Milan Robovic
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
-- Xabina is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either
-- version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the
-- implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
with core, map;
package item is
------------------------------------------------------------------------------------------
type list is (
wood, bark, flax, plank, stick, braces, nails, linen,
chamomile, mint, wax, salt, sugar, pepper, cinnamon, yeast,
skull, bone, intestines, fur, leather, fat, horn, tusk,
copper_ore, iron_ore, silver_ore, gold_ore, coal_ore, tin_ore, zinc_ore, lead_ore,
copper, iron, silver, gold, coal, tin, zinc, lead,
bronze, brass, steel, mercury, oil, ink, venom, silk,
papers, paperweight
);
type mark is mod 72;
------------------------------------------------------------------------------------------
type constant_type is new core.constant_type with
record
value : natural := 0;
weight : natural := 0;
end record;
type variable_type is new core.variable_type with
record
owner : natural := 0;
end record;
type constant_list is array (list) of constant_type;
type variable_list is array (mark) of variable_type;
------------------------------------------------------------------------------------------
constant_data : constant constant_list := (
(core.item, "Wood ", '+', core.colour.yellow, core.effect.normal, 2, 2),
(core.item, "Bark ", '+', core.colour.yellow, core.effect.normal, 1, 2),
(core.item, "Flax ", '+', core.colour.yellow, core.effect.normal, 3, 1),
(core.item, "Plank ", '+', core.colour.yellow, core.effect.normal, 2, 2),
(core.item, "Stick ", '+', core.colour.yellow, core.effect.normal, 2, 2),
(core.item, "Braces ", '+', core.colour.yellow, core.effect.normal, 2, 1),
(core.item, "Nails ", '+', core.colour.yellow, core.effect.normal, 1, 1),
(core.item, "Linen ", '+', core.colour.yellow, core.effect.normal, 23, 1),
(core.item, "Chamomile ", '+', core.colour.yellow, core.effect.normal, 3, 1),
(core.item, "Mint ", '+', core.colour.yellow, core.effect.normal, 5, 1),
(core.item, "Wax ", '+', core.colour.yellow, core.effect.normal, 7, 1),
(core.item, "Salt ", '+', core.colour.yellow, core.effect.normal, 13, 1),
(core.item, "Sugar ", '+', core.colour.yellow, core.effect.normal, 17, 1),
(core.item, "Pepper ", '+', core.colour.yellow, core.effect.normal, 11, 1),
(core.item, "Cinnamon ", '+', core.colour.yellow, core.effect.normal, 23, 1),
(core.item, "Yeast ", '+', core.colour.yellow, core.effect.normal, 5, 1),
(core.item, "Skull ", '+', core.colour.yellow, core.effect.normal, 2, 1),
(core.item, "Bone ", '+', core.colour.yellow, core.effect.normal, 1, 1),
(core.item, "Intestines ", '+', core.colour.yellow, core.effect.normal, 1, 1),
(core.item, "Fur ", '+', core.colour.yellow, core.effect.normal, 7, 2),
(core.item, "Leather ", '+', core.colour.yellow, core.effect.normal, 3, 1),
(core.item, "Fat ", '+', core.colour.yellow, core.effect.normal, 1, 1),
(core.item, "Horn ", '+', core.colour.yellow, core.effect.normal, 2, 1),
(core.item, "Tusk ", '+', core.colour.yellow, core.effect.normal, 3, 5),
(core.item, "Copper Ore ", '+', core.colour.yellow, core.effect.normal, 5, 7),
(core.item, "Iron Ore ", '+', core.colour.yellow, core.effect.normal, 7, 11),
(core.item, "Silver Ore ", '+', core.colour.yellow, core.effect.normal, 17, 7),
(core.item, "Gold Ore ", '+', core.colour.yellow, core.effect.normal, 23, 7),
(core.item, "Coal Ore ", '+', core.colour.yellow, core.effect.normal, 2, 7),
(core.item, "Tin Ore ", '+', core.colour.yellow, core.effect.normal, 13, 7),
(core.item, "Zinc Ore ", '+', core.colour.yellow, core.effect.normal, 13, 7),
(core.item, "Lead Ore ", '+', core.colour.yellow, core.effect.normal, 11, 13),
(core.item, "Copper ", '+', core.colour.yellow, core.effect.normal, 17, 5),
(core.item, "Iron ", '+', core.colour.yellow, core.effect.normal, 19, 7),
(core.item, "Silver ", '+', core.colour.yellow, core.effect.normal, 23, 5),
(core.item, "Gold ", '+', core.colour.yellow, core.effect.normal, 29, 5),
(core.item, "Coal ", '+', core.colour.yellow, core.effect.normal, 19, 5),
(core.item, "Tin ", '+', core.colour.yellow, core.effect.normal, 11, 5),
(core.item, "Zinc ", '+', core.colour.yellow, core.effect.normal, 13, 5),
(core.item, "Lead ", '+', core.colour.yellow, core.effect.normal, 47, 7),
(core.item, "Bronze ", '+', core.colour.yellow, core.effect.normal, 61, 5),
(core.item, "Brass ", '+', core.colour.yellow, core.effect.normal, 67, 5),
(core.item, "Steel ", '+', core.colour.yellow, core.effect.normal, 71, 7),
(core.item, "Mercury ", '+', core.colour.yellow, core.effect.normal, 97, 11),
(core.item, "Oil ", '+', core.colour.yellow, core.effect.normal, 5, 1),
(core.item, "Ink ", '+', core.colour.yellow, core.effect.normal, 13, 1),
(core.item, "Venom ", '+', core.colour.yellow, core.effect.normal, 11, 1),
(core.item, "Silk ", '+', core.colour.yellow, core.effect.normal, 13, 1),
(core.item, "Papers ", '+', core.colour.yellow, core.effect.normal, 1, 1),
(core.item, "Paperweight ", '+', core.colour.yellow, core.effect.normal, 2, 1)
);
variable_data : variable_list;
------------------------------------------------------------------------------------------
procedure create (this : list;
y : map.height;
x : map.width);
procedure render;
------------------------------------------------------------------------------------------
end item;