xhads/source/magic.ads

145 lines
7.3 KiB
Ada

with core, effect;
package magic is
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
type school is (
neutral, air, dark, earth, fire, light,
prime, water
);
type codex is (
-- Neutral
magic_arrow, chain_magic_arrow,
-- Air
blow_away, chain_lightning, grounded, lightning, storm_arrows, storm_winds,
summon_air_elemental, thunderclap,
-- Dark
agony_mass, agony, despair_mass, despair, life_drain_mass, life_drain,
purge, summon_dark_elemental, terror, weakness_mass, weakness,
-- Earth
earthquake, erosion, petrification, poison_cloud, regeneration_mass, regeneration,
rockwalls, stone_skin_mass, stone_skin, summon_earth_elemental,
-- Fire
determination_mass, determination, fireball, fire_bolt, fire_shield, fire_storm,
frenzy, immolation, inner_fire_mass, inner_fire, summon_fire_elemental,
-- Light
blindness, celestial_armor_mass, celestial_armor, heal_mass, heal, purify,
retribution_heal, retribution_mana, retribution_shot, summon_light_elemental, sunburst,
-- Prime
dispel_magic_mass, dispel_magic, disruption, haste_mass, haste, implosion,
mana_drain, slow_mass, slow, teleport, time_statis,
-- Water
blizzard, eternal_winter, frozen_ground, ice_armor_mass, ice_armor, ice_bolt,
ice_breaker, ice_wall, summon_water_elemental, winter_circle
);
------------------------------------------------------------------------------------------
subtype level_limit is natural range 0 .. 6;
type information is
record
name : core.short_string;
kind : school;
level : level_limit;
evoke : effect.codex;
end record;
type trait_array is array (codex) of information;
------------------------------------------------------------------------------------------
count : constant natural := codex'pos (codex'last) + 1;
trait : constant trait_array := (
("Magic Arrow ", neutral, 0, effect.none),
("Chain Magic Arrow ", neutral, 0, effect.none),
("Blow Away ", air, 0, effect.none),
("Chain Lightning ", air, 0, effect.none),
("Grounded ", air, 0, effect.none),
("Lightning ", air, 0, effect.none),
("Storm Arrows ", air, 0, effect.none),
("Storm Winds ", air, 0, effect.none),
("Summon Air Elemental ", air, 0, effect.none),
("Thunderclap ", air, 0, effect.none),
("Agony Mass ", dark, 0, effect.none),
("Agony ", dark, 0, effect.none),
("Despair Mass ", dark, 0, effect.none),
("Despair ", dark, 0, effect.none),
("Life Drain Mass ", dark, 0, effect.none),
("Life Drain ", dark, 0, effect.none),
("Purge ", dark, 0, effect.none),
("Summon Dark Elemental ", dark, 0, effect.none),
("Terror ", dark, 0, effect.none),
("Weakness Mass ", dark, 0, effect.none),
("Weakness ", dark, 0, effect.none),
("Earthquake ", earth, 0, effect.none),
("Erosion ", earth, 0, effect.none),
("Petrification ", earth, 0, effect.none),
("Poison Cloud ", earth, 0, effect.none),
("Regeneration Mass ", earth, 0, effect.none),
("Regeneration ", earth, 0, effect.none),
("Rockwalls ", earth, 0, effect.none),
("Stone Skin Mass ", earth, 0, effect.none),
("Stone Skin ", earth, 0, effect.none),
("Summon Earth Elemental ", earth, 0, effect.none),
("Determination Mass ", fire, 0, effect.none),
("Determination ", fire, 0, effect.none),
("Fireball ", fire, 0, effect.none),
("Fire Bolt ", fire, 0, effect.none),
("Fire Shield ", fire, 0, effect.none),
("Fire Storm ", fire, 0, effect.none),
("Frenzy ", fire, 0, effect.none),
("Immolation ", fire, 0, effect.none),
("Inner Fire Mass ", fire, 0, effect.none),
("Inner Fire ", fire, 0, effect.none),
("Summon Fire Elemental ", fire, 0, effect.none),
("Blindness ", light, 0, effect.none),
("Celestial Armor Mass ", light, 0, effect.none),
("Celestial Armor ", light, 0, effect.none),
("Heal Mass ", light, 0, effect.none),
("Heal ", light, 0, effect.none),
("Purify ", light, 0, effect.none),
("Retribution Heal ", light, 0, effect.none),
("Retribution Mana ", light, 0, effect.none),
("Retribution Shot ", light, 0, effect.none),
("Summon Light Elemental ", light, 0, effect.none),
("Sunburst ", light, 0, effect.none),
("Dispel Magic Mass ", prime, 0, effect.none),
("Dispel Magic ", prime, 0, effect.none),
("Disruption ", prime, 0, effect.none),
("Haste Mass ", prime, 0, effect.none),
("Haste ", prime, 0, effect.none),
("Implosion ", prime, 0, effect.none),
("Mana Drain ", prime, 0, effect.none),
("Slow Mass ", prime, 0, effect.none),
("Slow ", prime, 0, effect.none),
("Teleport ", prime, 0, effect.none),
("Time Statis ", prime, 0, effect.none),
("Blizzard ", water, 0, effect.none),
("Eternal Winter ", water, 0, effect.none),
("Frozen Ground ", water, 0, effect.none),
("Ice Armor Mass ", water, 0, effect.none),
("Ice Armor ", water, 0, effect.none),
("Ice Bolt ", water, 0, effect.none),
("Ice Breaker ", water, 0, effect.none),
("Ice Wall ", water, 0, effect.none),
("Summon Water Elemental ", water, 0, effect.none),
("Winter Circle ", water, 0, effect.none)
);
------------------------------------------------------------------------------------------
procedure configure;
procedure icon (index : in codex; x, y : in integer);
procedure view (index : in codex; x, y : in integer);
procedure menu (x, y : in integer; center : in boolean);
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
end magic;