Angband
Macros | Variables
unit-test-data.h File Reference
#include "angband.h"
#include "init.h"
#include "mon-lore.h"
#include "monster.h"
#include "obj-tval.h"
#include "player.h"
#include "player-calcs.h"
#include "project.h"

Go to the source code of this file.

Macros

#define TEST_DATA
 

Variables

static s16b TEST_DATA test_timed [30]
 
static struct object_base TEST_DATA sword_base
 
static struct object_base TEST_DATA light_base
 
static struct object_base TEST_DATA flask_base
 
static struct object_base TEST_DATA rod_base
 
static struct artifact TEST_DATA test_artifact_sword
 
static struct object_kind TEST_DATA test_longsword
 
static struct object_kind TEST_DATA test_torch
 
static struct object_kind TEST_DATA test_lantern
 
static struct object_kind TEST_DATA test_flask
 
static struct object_kind TEST_DATA test_rod_treasure_location
 
static struct object_kind TEST_DATA test_gold
 
static struct player_race TEST_DATA test_race
 
static struct start_item TEST_DATA start_torch
 
static struct start_item TEST_DATA start_longsword
 
static struct class_book TEST_DATA test_book
 
static struct magic_realm TEST_DATA test_realm
 
static struct player_class
TEST_DATA 
test_class
 
static struct monster_base
TEST_DATA 
test_rb_info
 
static struct blow_method TEST_DATA test_blow_method
 
static struct blow_effect TEST_DATA test_blow_effect_hurt
 
static struct blow_effect TEST_DATA test_blow_effect_poison
 
static struct blow_effect TEST_DATA test_blow_effect_acid
 
static struct blow_effect TEST_DATA test_blow_effect_elec
 
static struct blow_effect TEST_DATA test_blow_effect_fire
 
static struct blow_effect TEST_DATA test_blow_effect_cold
 
static struct blow_effect TEST_DATA test_blow_effect_blind
 
static struct monster_blow
TEST_DATA 
test_blow [4]
 
static bool TEST_DATA test_blows_known [4]
 
static struct monster_race
TEST_DATA 
test_r_human
 
static monster_lore TEST_DATA test_lore
 
static struct
angband_constants TEST_DATA 
test_z_info
 
static struct equip_slot TEST_DATA test_slot_light
 
static struct quest TEST_DATA test_quest
 
static struct player_body TEST_DATA test_player_body
 
static struct player_upkeep
TEST_DATA 
test_player_upkeep
 
static struct object TEST_DATA test_player_knowledge
 
static struct player TEST_DATA test_player
 
static struct chunk TEST_DATA test_cave
 
static struct projection TEST_DATA test_projections [4]
 

Macro Definition Documentation

#define TEST_DATA

Variable Documentation

struct object_base TEST_DATA flask_base
static
Initial value:
= {
.name = "Test Flask~",
.tval = TV_FLASK,
.next = NULL,
.break_perc = 100,
}
NULL
Definition: list-summon-types.h:18
struct object_base TEST_DATA light_base
static
Initial value:
= {
.name = "Test Light~",
.tval = TV_LIGHT,
.next = NULL,
.break_perc = 50,
}
NULL
Definition: list-summon-types.h:18
struct object_base TEST_DATA rod_base
static
Initial value:
= {
.name = "Test Rod~",
.tval = TV_ROD,
.next = NULL,
}
NULL
Definition: list-summon-types.h:18
struct start_item TEST_DATA start_longsword
static
Initial value:
= {
.kind = &test_longsword,
.min = 1,
.max = 1,
}
static struct object_kind TEST_DATA test_longsword
Definition: unit-test-data.h:73
struct object_kind * next
Definition: object.h:163
static struct start_item TEST_DATA start_torch
Definition: unit-test-data.h:635
struct start_item TEST_DATA start_torch
static
Initial value:
= {
.kind = &test_torch,
.min = 3,
.max = 5,
.next = NULL,
}
struct object_kind * next
Definition: object.h:163
static struct object_kind TEST_DATA test_torch
Definition: unit-test-data.h:141
NULL
Definition: list-summon-types.h:18
struct object_base TEST_DATA sword_base
static
Initial value:
= {
.name = "Test Sword",
.tval = TV_SWORD,
.next = NULL,
.break_perc = 50,
}
NULL
Definition: list-summon-types.h:18
struct artifact TEST_DATA test_artifact_sword
static
Initial value:
= {
.name = "Test Artifact",
.text = "A test artifact.",
.aidx = 0,
.next = NULL,
.tval = TV_SWORD,
.sval = 8,
.to_a = 1,
.to_h = 2,
.to_d = 3,
.ac = 5,
.dd = 2,
.ds = 5,
.weight = 16,
.cost = 40,
}
NULL
Definition: list-summon-types.h:18

Referenced by test_breakage_chance().

struct monster_blow TEST_DATA test_blow[4]
static
struct blow_effect TEST_DATA test_blow_effect_acid
static
Initial value:
= {
.name = "ACID",
.power = 20,
.eval = 20,
.desc = "shoot acid",
.next = NULL
}
NULL
Definition: list-summon-types.h:18

Referenced by test_effects().

struct blow_effect TEST_DATA test_blow_effect_blind
static
Initial value:
= {
.name = "BLIND",
.power = 0,
.eval = 20,
.desc = "blind",
.next = NULL
}
NULL
Definition: list-summon-types.h:18
struct blow_effect TEST_DATA test_blow_effect_cold
static
Initial value:
= {
.name = "COLD",
.power = 40,
.eval = 10,
.desc = "freeze",
.next = NULL
}
NULL
Definition: list-summon-types.h:18

Referenced by test_effects().

struct blow_effect TEST_DATA test_blow_effect_elec
static
Initial value:
= {
.name = "ELEC",
.power = 40,
.eval = 10,
.desc = "electrify",
.next = NULL
}
NULL
Definition: list-summon-types.h:18

Referenced by test_effects().

struct blow_effect TEST_DATA test_blow_effect_fire
static
Initial value:
= {
.name = "FIRE",
.power = 40,
.eval = 10,
.desc = "burn",
.next = NULL
}
NULL
Definition: list-summon-types.h:18

Referenced by test_effects().

struct blow_effect TEST_DATA test_blow_effect_hurt
static
Initial value:
= {
.name = "HURT",
.power = 40,
.eval = 0,
.desc = "attack",
.next = NULL
}
NULL
Definition: list-summon-types.h:18

Referenced by test_blows().

struct blow_effect TEST_DATA test_blow_effect_poison
static
Initial value:
= {
.name = "POISON",
.power = 20,
.eval = 10,
.desc = "poison",
.next = NULL
}
NULL
Definition: list-summon-types.h:18
struct blow_method TEST_DATA test_blow_method
static
Initial value:
= {
.name = "HIT",
.cut = true,
.stun = true,
.miss = false,
.phys = false,
.msgt = 34,
.act_msg = "hits you",
.desc = "hit",
.next = NULL
}
NULL
Definition: list-summon-types.h:18

Referenced by test_blows(), and test_effects().

bool TEST_DATA test_blows_known[4]
static
Initial value:
= {
true,
false,
false,
false,
}
struct class_book TEST_DATA test_book
static
Initial value:
= {
.tval = 10,
.sval = 4,
.realm = 1,
.num_spells = 8,
.spells = NULL,
}
NULL
Definition: list-summon-types.h:18
struct chunk TEST_DATA test_cave
static
Initial value:
= {
.name = "Test",
.created_at = 1,
.depth = 1,
.feeling = 0,
.obj_rating = 0,
.mon_rating = 0,
.good_item = false,
.height = 2,
.width = 2,
.feeling_squares = 0,
.feat_count = NULL,
.squares = NULL,
.monsters = NULL,
.mon_max = 1,
.mon_cnt = 0,
.mon_current = -1,
}
NULL
Definition: list-summon-types.h:18

Referenced by take1().

struct player_class TEST_DATA test_class
static

Referenced by test_generate0().

struct object_kind TEST_DATA test_flask
static

Referenced by test_obj_can_refill().

struct object_kind TEST_DATA test_gold
static
struct object_kind TEST_DATA test_lantern
static

Referenced by test_obj_can_refill().

struct object_kind TEST_DATA test_longsword
static

Referenced by test_breakage_chance().

monster_lore TEST_DATA test_lore
static
Initial value:
= {
.ridx = 0,
.sights = 1,
.deaths = 0,
.pkills = 0,
.tkills = 5,
.wake = 1,
.ignore = 4,
.drop_gold = 0,
.drop_item = 0,
.cast_innate = 0,
.cast_spell = 0,
.blows = &test_blow[0],
.flags = "\0\0\0\0\0\0\0\0\0\0",
.spell_flags = "\0\0\0\0\0\0\0\0\0\0\0",
.drops = NULL,
.friends = NULL,
.friends_base = NULL,
.mimic_kinds = NULL,
.all_known = false,
.blow_known = &test_blows_known[0],
.armour_known = false,
.drop_known = false,
.sleep_known = false,
.spell_freq_known = false
}
static bool TEST_DATA test_blows_known[4]
Definition: unit-test-data.h:859
static struct monster_blow TEST_DATA test_blow[4]
Definition: unit-test-data.h:812
NULL
Definition: list-summon-types.h:18
struct player TEST_DATA test_player
static
struct player_body TEST_DATA test_player_body
static
Initial value:
= {
.next = NULL,
.name = "Humanoid",
.count = 12,
}
NULL
Definition: list-summon-types.h:18

Referenced by setup_tests().

struct object TEST_DATA test_player_knowledge
static
struct player_upkeep TEST_DATA test_player_upkeep
static

Referenced by test_blows(), and test_effects().

struct projection TEST_DATA test_projections[4]
static

Referenced by setup_tests().

struct quest TEST_DATA test_quest
static
Initial value:
= {
.next = NULL,
.index = 0,
.name = "Test",
.level = 1,
.race = &test_r_human,
.cur_num = 0,
.max_num = 4,
}
static struct monster_race TEST_DATA test_r_human
Definition: unit-test-data.h:866
int cur_num
Definition: monster.h:303
NULL
Definition: list-summon-types.h:18

Referenced by setup_tests().

struct monster_race TEST_DATA test_r_human
static

Referenced by setup_tests().

struct player_race TEST_DATA test_race
static

Referenced by test_generate0().

struct monster_base TEST_DATA test_rb_info
static
Initial value:
= {
.next = NULL,
.name = "townsfolk",
.text = "Townsfolk",
.flags = "\0\0\0\0\0\0\0\0\0\0",
.spell_flags = "\0\0\0\0\0\0\0\0\0\0\0",
.d_char = 116,
.pain = NULL,
}
NULL
Definition: list-summon-types.h:18

Referenced by test_base0().

struct magic_realm TEST_DATA test_realm
static
Initial value:
= {
.next = NULL,
.name = "realm",
.stat = 1,
.verb = "spell_verb",
.spell_noun = "spell_noun",
.book_noun = "book_noun",
}
NULL
Definition: list-summon-types.h:18
struct object_kind TEST_DATA test_rod_treasure_location
static

Referenced by test_obj_can_refill().

struct equip_slot TEST_DATA test_slot_light
static
Initial value:
= {
.type = 5,
.name = "light",
.obj = NULL,
}
NULL
Definition: list-summon-types.h:18

Referenced by setup_tests().

s16b TEST_DATA test_timed[30]
static
Initial value:
= { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
}
struct object_kind TEST_DATA test_torch
static

Referenced by setup_tests(), and test_obj_can_refill().

struct angband_constants TEST_DATA test_z_info
static
Initial value:
= {
.f_max = 2,
.trap_max = 2,
.k_max = 2,
.a_max = 2,
.e_max = 2,
.r_max = 2,
.mp_max = 2,
.s_max = 2,
.pit_max = 2,
.act_max = 2,
.level_monster_max = 2,
}