107 lines
8.5 KiB
Ada
107 lines
8.5 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.
|
|
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
|
|
-- Experimental minimal terminal rogue-like game in Ada programming language. I used to write a lot of Ada programs some time ago, then went in full C and assembly mode, and came
|
|
-- back to Ada, but realized that I keep my folders messy... Since it's bothersome to find my old Ada projects and share them here, I decided that the most easy thing to do is to
|
|
-- write a new program in Ada, a tiny game. Work in progress, it's messy and ugly for now...
|
|
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
|
|
|
|
with core;
|
|
|
|
package item is
|
|
|
|
------------------------------------------------------------------------------------------
|
|
|
|
type item_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 item_mark is mod 72;
|
|
|
|
------------------------------------------------------------------------------------------
|
|
|
|
type item_constant_type is new core.entity_constant_type with
|
|
record
|
|
value : natural := 0;
|
|
weight : natural := 0;
|
|
end record;
|
|
|
|
type item_variable_type is new core.entity_variable_type with
|
|
record
|
|
owner : natural := 0;
|
|
end record;
|
|
|
|
type item_constant_list is array (item_list) of item_constant_type;
|
|
type item_variable_list is array (item_mark) of item_variable_type;
|
|
|
|
------------------------------------------------------------------------------------------
|
|
|
|
item_constant_data : constant item_constant_list := (
|
|
(core.entity_item, "Wood ", '+', core.colour.yellow, core.effect.normal, 2, 2),
|
|
(core.entity_item, "Bark ", '+', core.colour.yellow, core.effect.normal, 1, 2),
|
|
(core.entity_item, "Flax ", '+', core.colour.yellow, core.effect.normal, 3, 1),
|
|
(core.entity_item, "Plank ", '+', core.colour.yellow, core.effect.normal, 2, 2),
|
|
(core.entity_item, "Stick ", '+', core.colour.yellow, core.effect.normal, 2, 2),
|
|
(core.entity_item, "Braces ", '+', core.colour.yellow, core.effect.normal, 2, 1),
|
|
(core.entity_item, "Nails ", '+', core.colour.yellow, core.effect.normal, 1, 1),
|
|
(core.entity_item, "Linen ", '+', core.colour.yellow, core.effect.normal, 23, 1),
|
|
(core.entity_item, "Chamomile ", '+', core.colour.yellow, core.effect.normal, 3, 1),
|
|
(core.entity_item, "Mint ", '+', core.colour.yellow, core.effect.normal, 5, 1),
|
|
(core.entity_item, "Wax ", '+', core.colour.yellow, core.effect.normal, 7, 1),
|
|
(core.entity_item, "Salt ", '+', core.colour.yellow, core.effect.normal, 13, 1),
|
|
(core.entity_item, "Sugar ", '+', core.colour.yellow, core.effect.normal, 17, 1),
|
|
(core.entity_item, "Pepper ", '+', core.colour.yellow, core.effect.normal, 11, 1),
|
|
(core.entity_item, "Cinnamon ", '+', core.colour.yellow, core.effect.normal, 23, 1),
|
|
(core.entity_item, "Yeast ", '+', core.colour.yellow, core.effect.normal, 5, 1),
|
|
(core.entity_item, "Skull ", '+', core.colour.yellow, core.effect.normal, 2, 1),
|
|
(core.entity_item, "Bone ", '+', core.colour.yellow, core.effect.normal, 1, 1),
|
|
(core.entity_item, "Intestines ", '+', core.colour.yellow, core.effect.normal, 1, 1),
|
|
(core.entity_item, "Fur ", '+', core.colour.yellow, core.effect.normal, 7, 2),
|
|
(core.entity_item, "Leather ", '+', core.colour.yellow, core.effect.normal, 3, 1),
|
|
(core.entity_item, "Fat ", '+', core.colour.yellow, core.effect.normal, 1, 1),
|
|
(core.entity_item, "Horn ", '+', core.colour.yellow, core.effect.normal, 2, 1),
|
|
(core.entity_item, "Tusk ", '+', core.colour.yellow, core.effect.normal, 3, 5),
|
|
(core.entity_item, "Copper Ore ", '+', core.colour.yellow, core.effect.normal, 5, 7),
|
|
(core.entity_item, "Iron Ore ", '+', core.colour.yellow, core.effect.normal, 7, 11),
|
|
(core.entity_item, "Silver Ore ", '+', core.colour.yellow, core.effect.normal, 17, 7),
|
|
(core.entity_item, "Gold Ore ", '+', core.colour.yellow, core.effect.normal, 23, 7),
|
|
(core.entity_item, "Coal Ore ", '+', core.colour.yellow, core.effect.normal, 2, 7),
|
|
(core.entity_item, "Tin Ore ", '+', core.colour.yellow, core.effect.normal, 13, 7),
|
|
(core.entity_item, "Zinc Ore ", '+', core.colour.yellow, core.effect.normal, 13, 7),
|
|
(core.entity_item, "Lead Ore ", '+', core.colour.yellow, core.effect.normal, 11, 13),
|
|
(core.entity_item, "Copper ", '+', core.colour.yellow, core.effect.normal, 17, 5),
|
|
(core.entity_item, "Iron ", '+', core.colour.yellow, core.effect.normal, 19, 7),
|
|
(core.entity_item, "Silver ", '+', core.colour.yellow, core.effect.normal, 23, 5),
|
|
(core.entity_item, "Gold ", '+', core.colour.yellow, core.effect.normal, 29, 5),
|
|
(core.entity_item, "Coal ", '+', core.colour.yellow, core.effect.normal, 19, 5),
|
|
(core.entity_item, "Tin ", '+', core.colour.yellow, core.effect.normal, 11, 5),
|
|
(core.entity_item, "Zinc ", '+', core.colour.yellow, core.effect.normal, 13, 5),
|
|
(core.entity_item, "Lead ", '+', core.colour.yellow, core.effect.normal, 47, 7),
|
|
(core.entity_item, "Bronze ", '+', core.colour.yellow, core.effect.normal, 61, 5),
|
|
(core.entity_item, "Brass ", '+', core.colour.yellow, core.effect.normal, 67, 5),
|
|
(core.entity_item, "Steel ", '+', core.colour.yellow, core.effect.normal, 71, 7),
|
|
(core.entity_item, "Mercury ", '+', core.colour.yellow, core.effect.normal, 97, 11),
|
|
(core.entity_item, "Oil ", '+', core.colour.yellow, core.effect.normal, 5, 1),
|
|
(core.entity_item, "Ink ", '+', core.colour.yellow, core.effect.normal, 13, 1),
|
|
(core.entity_item, "Venom ", '+', core.colour.yellow, core.effect.normal, 11, 1),
|
|
(core.entity_item, "Silk ", '+', core.colour.yellow, core.effect.normal, 13, 1),
|
|
(core.entity_item, "Papers ", '+', core.colour.yellow, core.effect.normal, 1, 1),
|
|
(core.entity_item, "Paperweight ", '+', core.colour.yellow, core.effect.normal, 2, 1)
|
|
);
|
|
|
|
item_variable_data : item_variable_list;
|
|
|
|
------------------------------------------------------------------------------------------
|
|
|
|
end item;
|