- Added simpletypes.h header to hold the enums and typedefs related to the main class headers
- Made boom drawing take from the new boom gworld rather than from the field gworld - Added enum for monster abilities (will be used for both of a monster's abilities, but isn't used yet) - Added supporting member functions for the new abilities (not used yet): get ability name and has ability - Added SDF pointer storage to the party structure together with supporting member functions (not used yet) - Deleted the "reserved" fields res1, res2, res3 in the monster struct git-svn-id: http://openexile.googlecode.com/svn/trunk@87 4ebdad44-0ea0-11de-aab3-ff745001d230
This commit is contained in:
@@ -365,6 +365,7 @@
|
|||||||
9122832D0FCF6C7200B21642 /* busywork.exs */ = {isa = PBXFileReference; lastKnownFileType = file; path = busywork.exs; sourceTree = "<group>"; };
|
9122832D0FCF6C7200B21642 /* busywork.exs */ = {isa = PBXFileReference; lastKnownFileType = file; path = busywork.exs; sourceTree = "<group>"; };
|
||||||
912283C70FD0E16B00B21642 /* undo.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = undo.h; path = tools/undo.h; sourceTree = "<group>"; };
|
912283C70FD0E16B00B21642 /* undo.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = undo.h; path = tools/undo.h; sourceTree = "<group>"; };
|
||||||
912283C80FD0E16C00B21642 /* undo.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = undo.cpp; path = tools/undo.cpp; sourceTree = "<group>"; };
|
912283C80FD0E16C00B21642 /* undo.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = undo.cpp; path = tools/undo.cpp; sourceTree = "<group>"; };
|
||||||
|
912287850FD41A2300B21642 /* simpletypes.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = simpletypes.h; path = classes/simpletypes.h; sourceTree = "<group>"; };
|
||||||
912793480F9C0FE6007B0D52 /* ViewDlog.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = ViewDlog.app; sourceTree = BUILT_PRODUCTS_DIR; };
|
912793480F9C0FE6007B0D52 /* ViewDlog.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = ViewDlog.app; sourceTree = BUILT_PRODUCTS_DIR; };
|
||||||
912798AE0F9CA636007B0D52 /* dlgbtns.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = dlgbtns.cpp; path = tools/dlgbtns.cpp; sourceTree = "<group>"; };
|
912798AE0F9CA636007B0D52 /* dlgbtns.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = dlgbtns.cpp; path = tools/dlgbtns.cpp; sourceTree = "<group>"; };
|
||||||
91279BAD0F9CFCBA007B0D52 /* boescenario.icns */ = {isa = PBXFileReference; lastKnownFileType = image.icns; path = boescenario.icns; sourceTree = "<group>"; };
|
91279BAD0F9CFCBA007B0D52 /* boescenario.icns */ = {isa = PBXFileReference; lastKnownFileType = image.icns; path = boescenario.icns; sourceTree = "<group>"; };
|
||||||
@@ -671,6 +672,7 @@
|
|||||||
91AC60A60FA26C1B00EEAE67 /* tmpltown.h */,
|
91AC60A60FA26C1B00EEAE67 /* tmpltown.h */,
|
||||||
91AC61C40FA2729900EEAE67 /* universe.h */,
|
91AC61C40FA2729900EEAE67 /* universe.h */,
|
||||||
91AC62090FA2853700EEAE67 /* creatlist.h */,
|
91AC62090FA2853700EEAE67 /* creatlist.h */,
|
||||||
|
912287850FD41A2300B21642 /* simpletypes.h */,
|
||||||
);
|
);
|
||||||
name = headers;
|
name = headers;
|
||||||
sourceTree = "<group>";
|
sourceTree = "<group>";
|
||||||
|
Binary file not shown.
Before Width: | Height: | Size: 6.6 MiB After Width: | Height: | Size: 6.5 MiB |
@@ -713,9 +713,6 @@ cMonster return_monster_template(m_num_t store) {
|
|||||||
monst.default_attitude = 0;
|
monst.default_attitude = 0;
|
||||||
monst.summon_type = 0;
|
monst.summon_type = 0;
|
||||||
monst.default_facial_pic = 0;
|
monst.default_facial_pic = 0;
|
||||||
monst.res1 = 0;
|
|
||||||
monst.res2 = 0;
|
|
||||||
monst.res3 = 0;
|
|
||||||
|
|
||||||
monst.immunities = 0;
|
monst.immunities = 0;
|
||||||
if (m_magic_r[m_num] == 1)
|
if (m_magic_r[m_num] == 1)
|
||||||
|
@@ -86,18 +86,6 @@ enum eGameMode {
|
|||||||
MODE_RESTING = 50,
|
MODE_RESTING = 50,
|
||||||
};
|
};
|
||||||
|
|
||||||
///* adven[i].main_status */ //complete
|
|
||||||
//#define MAIN_STATUS_ABSENT 0 // absent, empty slot
|
|
||||||
//#define MAIN_STATUS_ALIVE 1
|
|
||||||
//#define MAIN_STATUS_DEAD 2
|
|
||||||
//#define MAIN_STATUS_DUST 3
|
|
||||||
//#define MAIN_STATUS_STONE 4
|
|
||||||
//#define MAIN_STATUS_FLED 5
|
|
||||||
//#define MAIN_STATUS_SURFACE 6 // fled to surface?
|
|
||||||
//#define MAIN_STATUS_WON 7
|
|
||||||
///* main status modifiers */
|
|
||||||
//#define MAIN_STATUS_SPLIT 10 // split from party
|
|
||||||
|
|
||||||
// Directions!
|
// Directions!
|
||||||
enum eDirection {
|
enum eDirection {
|
||||||
DIR_N = 0,
|
DIR_N = 0,
|
||||||
@@ -119,49 +107,6 @@ inline eDirection& operator++ (eDirection& me,int){
|
|||||||
else return me = (eDirection) (1 + (int) me);
|
else return me = (eDirection) (1 + (int) me);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* damage type*/
|
|
||||||
/* used as parameter to some functions */
|
|
||||||
enum eDamageType {
|
|
||||||
DAMAGE_WEAPON = 0,
|
|
||||||
DAMAGE_FIRE = 1,
|
|
||||||
DAMAGE_POISON = 2,
|
|
||||||
DAMAGE_MAGIC = 3,
|
|
||||||
DAMAGE_UNBLOCKABLE = 4, //from the source files - the display is the same as the magic one (damage_monst in SPECIALS.cpp)
|
|
||||||
DAMAGE_COLD = 5,
|
|
||||||
DAMAGE_UNDEAD = 6, //from the source files - the display is the same as the weapon one
|
|
||||||
DAMAGE_DEMON = 7, //from the source files - the display is the same as the weapon one
|
|
||||||
// 8 and 9 aren't defined : doesn't print any damage. According to the source files the 9 is DAMAGE_MARKED though. Wrong ?
|
|
||||||
DAMAGE_MARKED = 10, // usage: DAMAGE_MARKED + damage_type
|
|
||||||
DAMAGE_WEAPON_MARKED = 10,
|
|
||||||
DAMAGE_FIRE_MARKED = 11,
|
|
||||||
DAMAGE_POISON_MARKED = 12,
|
|
||||||
DAMAGE_MAGIC_MARKED = 13,
|
|
||||||
DAMAGE_UNBLOCKABLE_MARKED = 14,
|
|
||||||
DAMAGE_COLD_MARKED = 15,
|
|
||||||
DAMAGE_UNDEAD_MARKED = 16,
|
|
||||||
DAMAGE_DEMON_MARKED = 17,
|
|
||||||
DAMAGE_NO_PRINT = 30, // usage: DAMAGE_NO_PRINT + damage_type
|
|
||||||
DAMAGE_WEAPON_NO_PRINT = 30,
|
|
||||||
DAMAGE_FIRE_NO_PRINT = 31,
|
|
||||||
DAMAGE_POISON_NO_PRINT = 32,
|
|
||||||
DAMAGE_MAGIC_NO_PRINT = 33,
|
|
||||||
DAMAGE_UNBLOCKABLE_NO_PRINT = 34,
|
|
||||||
DAMAGE_COLD_NO_PRINT = 35,
|
|
||||||
DAMAGE_UNDEAD_NO_PRINT = 36,
|
|
||||||
DAMAGE_DEMON_NO_PRINT = 37,
|
|
||||||
// What about both NO_PRINT and MARKED?
|
|
||||||
};
|
|
||||||
|
|
||||||
inline void operator -= (eDamageType& cur, eDamageType othr){
|
|
||||||
if((othr == DAMAGE_MARKED && cur >= DAMAGE_MARKED && cur < DAMAGE_NO_PRINT) ||
|
|
||||||
(othr == DAMAGE_NO_PRINT && cur >= DAMAGE_NO_PRINT))
|
|
||||||
cur = (eDamageType) ((int)cur - (int)othr);
|
|
||||||
}
|
|
||||||
|
|
||||||
inline void operator += (eDamageType& cur, eDamageType othr){
|
|
||||||
if((othr == DAMAGE_MARKED || othr == DAMAGE_NO_PRINT) && cur < DAMAGE_MARKED)
|
|
||||||
cur = (eDamageType) ((int)cur + (int)othr);
|
|
||||||
}
|
|
||||||
//inline eDamageType operator + (eDamageType lhs, eDamageType rhs){
|
//inline eDamageType operator + (eDamageType lhs, eDamageType rhs){
|
||||||
// if(lhs == DAMAGE_MARKED || lhs == DAMAGE_NO_PRINT){
|
// if(lhs == DAMAGE_MARKED || lhs == DAMAGE_NO_PRINT){
|
||||||
// if(rhs != DAMAGE_MARKED && rhs != DAMAGE_NO_PRINT)
|
// if(rhs != DAMAGE_MARKED && rhs != DAMAGE_NO_PRINT)
|
||||||
|
@@ -141,6 +141,7 @@ GWorldPtr party_template_gworld;
|
|||||||
GWorldPtr items_gworld;
|
GWorldPtr items_gworld;
|
||||||
GWorldPtr tiny_obj_gworld;
|
GWorldPtr tiny_obj_gworld;
|
||||||
GWorldPtr fields_gworld;
|
GWorldPtr fields_gworld;
|
||||||
|
GWorldPtr boom_gworld;
|
||||||
GWorldPtr roads_gworld;
|
GWorldPtr roads_gworld;
|
||||||
GWorldPtr map_gworld;
|
GWorldPtr map_gworld;
|
||||||
GWorldPtr tiny_map_graphics;
|
GWorldPtr tiny_map_graphics;
|
||||||
@@ -835,6 +836,7 @@ void Set_up_win ()
|
|||||||
tiny_obj_gworld = load_pict(900);
|
tiny_obj_gworld = load_pict(900);
|
||||||
fields_gworld = load_pict(821);
|
fields_gworld = load_pict(821);
|
||||||
roads_gworld = load_pict(822);
|
roads_gworld = load_pict(822);
|
||||||
|
boom_gworld = load_pict(823);
|
||||||
missiles_gworld = load_pict(880);
|
missiles_gworld = load_pict(880);
|
||||||
dlogpics_gworld = load_pict(850);
|
dlogpics_gworld = load_pict(850);
|
||||||
|
|
||||||
@@ -2583,7 +2585,7 @@ void boom_space(location where,short mode,short type,short damage,short sound)
|
|||||||
else OffsetRect(&dest_rect,store_anim_ul.h,store_anim_ul.v);
|
else OffsetRect(&dest_rect,store_anim_ul.h,store_anim_ul.v);
|
||||||
|
|
||||||
OffsetRect(&source_rect,-1 * store_rect.left + 28 * type,-1 * store_rect.top);
|
OffsetRect(&source_rect,-1 * store_rect.left + 28 * type,-1 * store_rect.top);
|
||||||
rect_draw_some_item(fields_gworld,source_rect,terrain_screen_gworld,dest_rect,1,1);
|
rect_draw_some_item(boom_gworld,source_rect,terrain_screen_gworld,dest_rect,1,1);
|
||||||
|
|
||||||
if ((cartoon_happening == false) && (dest_rect.right - dest_rect.left >= 28)
|
if ((cartoon_happening == false) && (dest_rect.right - dest_rect.left >= 28)
|
||||||
&& (dest_rect.bottom - dest_rect.top >= 36)) {
|
&& (dest_rect.bottom - dest_rect.top >= 36)) {
|
||||||
|
@@ -50,7 +50,7 @@ extern WindowPtr mainPtr;
|
|||||||
extern short dungeon_font_num,geneva_font_num,town_type,which_combat_type;
|
extern short dungeon_font_num,geneva_font_num,town_type,which_combat_type;
|
||||||
extern eGameMode overall_mode;
|
extern eGameMode overall_mode;
|
||||||
extern bool play_sounds,boom_anim_active,cartoon_happening,in_startup_mode;
|
extern bool play_sounds,boom_anim_active,cartoon_happening,in_startup_mode;
|
||||||
extern GWorldPtr fields_gworld,mixed_gworld,dlg_buttons_gworld[NUM_BUTTONS][2],terrain_screen_gworld,missiles_gworld;
|
extern GWorldPtr fields_gworld,boom_gworld,mixed_gworld,dlg_buttons_gworld[NUM_BUTTONS][2],terrain_screen_gworld,missiles_gworld;
|
||||||
//extern party_record_type party;
|
//extern party_record_type party;
|
||||||
extern Rect sbar_rect,item_sbar_rect,shop_sbar_rect;
|
extern Rect sbar_rect,item_sbar_rect,shop_sbar_rect;
|
||||||
extern ControlHandle text_sbar,item_sbar,shop_sbar;
|
extern ControlHandle text_sbar,item_sbar,shop_sbar;
|
||||||
@@ -703,8 +703,8 @@ void do_explosion_anim(short sound_num,short special_draw)
|
|||||||
if (store_booms[i].boom_type >= 0) {
|
if (store_booms[i].boom_type >= 0) {
|
||||||
if ((t + store_booms[i].offset >= 0) && (t + store_booms[i].offset <= 7)) {
|
if ((t + store_booms[i].offset >= 0) && (t + store_booms[i].offset <= 7)) {
|
||||||
from_rect = base_rect;
|
from_rect = base_rect;
|
||||||
OffsetRect(&from_rect,28 * (t + store_booms[i].offset),144 + 36 * (store_booms[i].boom_type));
|
OffsetRect(&from_rect,28 * (t + store_booms[i].offset),36 * (1 + store_booms[i].boom_type));
|
||||||
rect_draw_some_item(fields_gworld,from_rect,
|
rect_draw_some_item(boom_gworld,from_rect,
|
||||||
temp_gworld,explode_place_rect[i],1,0);
|
temp_gworld,explode_place_rect[i],1,0);
|
||||||
|
|
||||||
if (store_booms[i].val_to_place > 0) {
|
if (store_booms[i].val_to_place > 0) {
|
||||||
|
@@ -2640,7 +2640,7 @@ void townmode_spec(short which_mode,cSpecial cur_node,short cur_spec_type,
|
|||||||
set_terrain(l,scenario.ter_types[ter].flag1.u);
|
set_terrain(l,scenario.ter_types[ter].flag1.u);
|
||||||
*redraw = 1;
|
*redraw = 1;
|
||||||
break;
|
break;
|
||||||
case 179:
|
case 179: // TODO: Add a "random offset" mode
|
||||||
if (which_mode == 7)
|
if (which_mode == 7)
|
||||||
break;
|
break;
|
||||||
run_a_boom(l,spec.ex2a,0,0);
|
run_a_boom(l,spec.ex2a,0,0);
|
||||||
|
@@ -8,15 +8,7 @@
|
|||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
typedef unsigned short str_num_t;
|
#include "simpletypes.h"
|
||||||
|
|
||||||
//class sbyte {
|
|
||||||
// signed char c;
|
|
||||||
//public:
|
|
||||||
// operator int() {return c;}
|
|
||||||
// sbyte(signed char k) : c(k) {}
|
|
||||||
//}
|
|
||||||
|
|
||||||
#include "location.h"
|
#include "location.h"
|
||||||
#include "terrain.h"
|
#include "terrain.h"
|
||||||
#include "vehicle.h"
|
#include "vehicle.h"
|
||||||
|
@@ -15,180 +15,6 @@
|
|||||||
|
|
||||||
namespace legacy { struct item_record_type; };
|
namespace legacy { struct item_record_type; };
|
||||||
|
|
||||||
/* items[i].type a.k.a type of weapon */
|
|
||||||
enum eWeapType {
|
|
||||||
ITEM_NOT_MELEE = 0,
|
|
||||||
ITEM_EDGED = 1,
|
|
||||||
ITEM_BASHING = 2,
|
|
||||||
ITEM_POLE = 3,
|
|
||||||
};
|
|
||||||
|
|
||||||
/* items[i].variety a.k.a item type (in editor) */
|
|
||||||
enum eItemType {
|
|
||||||
ITEM_TYPE_NO_ITEM = 0,
|
|
||||||
ITEM_TYPE_ONE_HANDED = 1,
|
|
||||||
ITEM_TYPE_TWO_HANDED = 2,
|
|
||||||
ITEM_TYPE_GOLD = 3,
|
|
||||||
ITEM_TYPE_BOW = 4,
|
|
||||||
ITEM_TYPE_ARROW = 5,
|
|
||||||
ITEM_TYPE_THROWN_MISSILE = 6,
|
|
||||||
ITEM_TYPE_POTION = 7, // potion/magic item
|
|
||||||
ITEM_TYPE_SCROLL = 8, // scroll/magic item
|
|
||||||
ITEM_TYPE_WAND = 9,
|
|
||||||
ITEM_TYPE_TOOL = 10,
|
|
||||||
ITEM_TYPE_FOOD = 11,
|
|
||||||
ITEM_TYPE_SHIELD = 12,
|
|
||||||
ITEM_TYPE_ARMOR = 13,
|
|
||||||
ITEM_TYPE_HELM = 14,
|
|
||||||
ITEM_TYPE_GLOVES = 15,
|
|
||||||
ITEM_TYPE_SHIELD_2 = 16,
|
|
||||||
// don't know why a second type of shield is used ; it is actually checked
|
|
||||||
// in the armor code (item >= 12 and <= 17)
|
|
||||||
// and you can't equip another (12) shield while wearing it ... I didn't
|
|
||||||
// find a single item with this property in the bladbase.exs ...
|
|
||||||
ITEM_TYPE_BOOTS = 17,
|
|
||||||
ITEM_TYPE_RING = 18,
|
|
||||||
ITEM_TYPE_NECKLACE = 19,
|
|
||||||
ITEM_TYPE_WEAPON_POISON = 20,
|
|
||||||
ITEM_TYPE_NON_USE_OBJECT = 21,
|
|
||||||
ITEM_TYPE_PANTS = 22,
|
|
||||||
ITEM_TYPE_CROSSBOW = 23,
|
|
||||||
ITEM_TYPE_BOLTS = 24,
|
|
||||||
ITEM_TYPE_MISSILE_NO_AMMO = 25, //e.g slings
|
|
||||||
ITEM_TYPE_UNUSED1 = 26, // these are here solely because they are options in the editor
|
|
||||||
ITEM_TYPE_UNUSED2 = 27,
|
|
||||||
};
|
|
||||||
|
|
||||||
/* items[i].ability */
|
|
||||||
enum eItemAbil {
|
|
||||||
// Weapon abilities
|
|
||||||
ITEM_NO_ABILITY = 0,
|
|
||||||
ITEM_FLAMING_WEAPON = 1,
|
|
||||||
ITEM_DEMON_SLAYER = 2,
|
|
||||||
ITEM_UNDEAD_SLAYER = 3,
|
|
||||||
ITEM_LIZARD_SLAYER = 4,
|
|
||||||
ITEM_GIANT_SLAYER = 5,
|
|
||||||
ITEM_MAGE_SLAYER = 6,
|
|
||||||
ITEM_PRIEST_SLAYER = 7,
|
|
||||||
ITEM_BUG_SLAYER = 8,
|
|
||||||
ITEM_ACIDIC_WEAPON = 9,
|
|
||||||
ITEM_SOULSUCKER = 10,
|
|
||||||
ITEM_DRAIN_MISSILES = 11,
|
|
||||||
ITEM_WEAK_WEAPON = 12,
|
|
||||||
ITEM_CAUSES_FEAR = 13,
|
|
||||||
ITEM_POISONED_WEAPON = 14,
|
|
||||||
// General abilities
|
|
||||||
ITEM_PROTECTION = 30,
|
|
||||||
ITEM_FULL_PROTECTION = 31,
|
|
||||||
ITEM_FIRE_PROTECTION = 32,
|
|
||||||
ITEM_COLD_PROTECTION = 33,
|
|
||||||
ITEM_POISON_PROTECTION = 34,
|
|
||||||
ITEM_MAGIC_PROTECTION = 35,
|
|
||||||
ITEM_ACID_PROTECTION = 36,
|
|
||||||
ITEM_SKILL = 37,
|
|
||||||
ITEM_STRENGTH = 38,
|
|
||||||
ITEM_DEXTERITY = 39,
|
|
||||||
ITEM_INTELLIGENCE = 40,
|
|
||||||
ITEM_ACCURACY = 41,
|
|
||||||
ITEM_THIEVING = 42,
|
|
||||||
ITEM_GIANT_STRENGTH = 43,
|
|
||||||
ITEM_LIGHTER_OBJECT = 44,
|
|
||||||
ITEM_HEAVIER_OBJECT = 45,
|
|
||||||
ITEM_OCCASIONAL_BLESS = 46,
|
|
||||||
ITEM_OCCASIONAL_HASTE = 47,
|
|
||||||
ITEM_LIFE_SAVING = 48,
|
|
||||||
ITEM_PROTECT_FROM_PETRIFY = 49,
|
|
||||||
ITEM_REGENERATE = 50,
|
|
||||||
ITEM_POISON_AUGMENT = 51,
|
|
||||||
ITEM_DISEASE_PARTY = 52,
|
|
||||||
ITEM_WILL = 53,
|
|
||||||
ITEM_FREE_ACTION = 54,
|
|
||||||
ITEM_SPEED = 55,
|
|
||||||
ITEM_SLOW_WEARER = 56,
|
|
||||||
ITEM_PROTECT_FROM_UNDEAD = 57,
|
|
||||||
ITEM_PROTECT_FROM_DEMONS = 58,
|
|
||||||
ITEM_PROTECT_FROM_HUMANOIDS = 59,
|
|
||||||
ITEM_PROTECT_FROM_REPTILES = 60,
|
|
||||||
ITEM_PROTECT_FROM_GIANTS = 61,
|
|
||||||
ITEM_PROTECT_FROM_DISEASE = 62,
|
|
||||||
// Nonspell Usable
|
|
||||||
ITEM_POISON_WEAPON = 70, //put poison on weapon
|
|
||||||
ITEM_BLESS_CURSE = 71,
|
|
||||||
ITEM_AFFECT_POISON = 72,
|
|
||||||
ITEM_HASTE_SLOW = 73,
|
|
||||||
ITEM_AFFECT_INVULN = 74,
|
|
||||||
ITEM_AFFECT_MAGIC_RES = 75,
|
|
||||||
ITEM_AFFECT_WEB = 76,
|
|
||||||
ITEM_AFFECT_DISEASE = 77,
|
|
||||||
ITEM_AFFECT_SANCTUARY = 78,
|
|
||||||
ITEM_AFFECT_DUMBFOUND = 79,
|
|
||||||
ITEM_AFFECT_MARTYRS_SHIELD = 80,
|
|
||||||
ITEM_AFFECT_SLEEP = 81,
|
|
||||||
ITEM_AFFECT_PARALYSIS = 82,
|
|
||||||
ITEM_AFFECT_ACID = 83,
|
|
||||||
ITEM_BLISS = 84,
|
|
||||||
ITEM_AFFECT_EXPERIENCE = 85,
|
|
||||||
ITEM_AFFECT_SKILL_POINTS = 86,
|
|
||||||
ITEM_AFFECT_HEALTH = 87,
|
|
||||||
ITEM_AFFECT_SPELL_POINTS = 88,
|
|
||||||
ITEM_DOOM = 89,
|
|
||||||
ITEM_LIGHT = 90,
|
|
||||||
ITEM_STEALTH = 91,
|
|
||||||
ITEM_FIREWALK = 92,
|
|
||||||
ITEM_FLYING = 93,
|
|
||||||
ITEM_MAJOR_HEALING = 94,
|
|
||||||
// Spell Usable
|
|
||||||
ITEM_SPELL_FLAME = 110,
|
|
||||||
ITEM_SPELL_FIREBALL = 111,
|
|
||||||
ITEM_SPELL_FIRESTORM = 112,
|
|
||||||
ITEM_SPELL_KILL = 113,
|
|
||||||
ITEM_SPELL_ICE_BOLT = 114,
|
|
||||||
ITEM_SPELL_SLOW = 115,
|
|
||||||
ITEM_SPELL_SHOCKWAVE = 116,
|
|
||||||
ITEM_SPELL_DISPEL_UNDEAD = 117,
|
|
||||||
ITEM_SPELL_DISPEL_SPIRIT = 118,
|
|
||||||
ITEM_SPELL_SUMMONING = 119,
|
|
||||||
ITEM_SPELL_MASS_SUMMONING = 120,
|
|
||||||
ITEM_SPELL_ACID_SPRAY = 121,
|
|
||||||
ITEM_SPELL_STINKING_CLOUD = 122,
|
|
||||||
ITEM_SPELL_SLEEP_FIELD = 123,
|
|
||||||
ITEM_SPELL_VENOM = 124,
|
|
||||||
ITEM_SPELL_SHOCKSTORM = 125,
|
|
||||||
ITEM_SPELL_PARALYSIS = 126,
|
|
||||||
ITEM_SPELL_WEB_SPELL = 127,
|
|
||||||
ITEM_SPELL_STRENGTHEN_TARGET = 128, //wand of carrunos effect
|
|
||||||
ITEM_SPELL_QUICKFIRE = 129,
|
|
||||||
ITEM_SPELL_MASS_CHARM = 130,
|
|
||||||
ITEM_SPELL_MAGIC_MAP = 131,
|
|
||||||
ITEM_SPELL_DISPEL_BARRIER = 132,
|
|
||||||
ITEM_SPELL_MAKE_ICE_WALL = 133,
|
|
||||||
ITEM_SPELL_CHARM_SPELL = 134,
|
|
||||||
ITEM_SPELL_ANTIMAGIC_CLOUD = 135,
|
|
||||||
// Reagents
|
|
||||||
ITEM_HOLLY = 150, // Holly/Toadstool
|
|
||||||
ITEM_COMFREY_ROOT = 151,
|
|
||||||
ITEM_GLOWING_NETTLE = 152,
|
|
||||||
ITEM_WORMGRASS = 153, // Crypt Shroom/Wormgr.
|
|
||||||
ITEM_ASPTONGUE_MOLD = 154,
|
|
||||||
ITEM_EMBER_FLOWERS = 155,
|
|
||||||
ITEM_GRAYMOLD = 156,
|
|
||||||
ITEM_MANDRAKE = 157,
|
|
||||||
ITEM_SAPPHIRE = 158,
|
|
||||||
ITEM_SMOKY_CRYSTAL = 159,
|
|
||||||
ITEM_RESSURECTION_BALM = 160,
|
|
||||||
ITEM_LOCKPICKS = 161,
|
|
||||||
// Missile Abilities
|
|
||||||
ITEM_MISSILE_RETURNING = 170,
|
|
||||||
ITEM_MISSILE_LIGHTNING = 171,
|
|
||||||
ITEM_MISSILE_EXPLODING = 172,
|
|
||||||
ITEM_MISSILE_ACID = 173,
|
|
||||||
ITEM_MISSILE_SLAY_UNDEAD = 174,
|
|
||||||
ITEM_MISSILE_SLAY_DEMON = 175,
|
|
||||||
ITEM_MISSILE_HEAL_TARGET = 176,
|
|
||||||
};
|
|
||||||
|
|
||||||
typedef signed short item_num_t;
|
|
||||||
|
|
||||||
class cItemRec {
|
class cItemRec {
|
||||||
public:
|
public:
|
||||||
eItemType variety;
|
eItemType variety;
|
||||||
|
@@ -53,9 +53,6 @@ cMonster& cMonster::operator = (legacy::monster_record_type& old){
|
|||||||
default_attitude = old.default_attitude;
|
default_attitude = old.default_attitude;
|
||||||
summon_type = old.summon_type;
|
summon_type = old.summon_type;
|
||||||
default_facial_pic = old.default_facial_pic;
|
default_facial_pic = old.default_facial_pic;
|
||||||
res1 = old.res1;
|
|
||||||
res2 = old.res2;
|
|
||||||
res3 = old.res3;
|
|
||||||
picture_num = old.picture_num;
|
picture_num = old.picture_num;
|
||||||
if(picture_num == 122) picture_num = 119;
|
if(picture_num == 122) picture_num = 119;
|
||||||
return *this;
|
return *this;
|
||||||
@@ -197,3 +194,287 @@ cCreature& cCreature::operator = (const cCreature& other){ // replaces return_mo
|
|||||||
target = 6; // No target
|
target = 6; // No target
|
||||||
return *this;
|
return *this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
cMonster::cAbility::operator std::string(){
|
||||||
|
std::ostringstream sout;
|
||||||
|
short i = 0;
|
||||||
|
switch(abil){
|
||||||
|
case MONST_THROWS_DARTS:
|
||||||
|
sout << "Throws darts (" << extra1 << 'd' << extra2 << ')';
|
||||||
|
break;
|
||||||
|
case MONST_SHOOTS_ARROWS:
|
||||||
|
sout << "Shoots arrows (" << extra1 << 'd' << extra2 << ')';
|
||||||
|
break;
|
||||||
|
case MONST_THROWS_SPEARS:
|
||||||
|
sout << "Throws spears (" << extra1 << 'd' << extra2 << ')';
|
||||||
|
break;
|
||||||
|
case MONST_THROWS_ROCKS:
|
||||||
|
sout << "Throws rocks (" << extra1 << 'd' << extra2 << ')';
|
||||||
|
break;
|
||||||
|
case MONST_THROWS_RAZORDISKS:
|
||||||
|
sout << "Throws razordisks (" << extra1 << 'd' << extra2 << ')';
|
||||||
|
break;
|
||||||
|
case MONST_GOOD_ARCHER:
|
||||||
|
sout << "Good archer (" << extra1 << 'd' << extra2 << ')';
|
||||||
|
break;
|
||||||
|
case MONST_SHOOTS_SPINES:
|
||||||
|
sout << "Shoots spines (" << extra1 << 'd' << extra2 << ')';
|
||||||
|
break;
|
||||||
|
case MONST_THROWS_KNIVES:
|
||||||
|
sout << "Throws knives (" << extra1 << 'd' << extra2 << ')';
|
||||||
|
break;
|
||||||
|
case MONST_DAMAGE_RAY:
|
||||||
|
case MONST_DRAIN_XP_DAMAGE_RAY:
|
||||||
|
case MONST_DAMAGE_TOUCH:
|
||||||
|
case MONST_DRAIN_XP_DAMAGE_TOUCH:
|
||||||
|
switch(extra1){
|
||||||
|
case DAMAGE_WEAPON:
|
||||||
|
sout << "Health drain";
|
||||||
|
break;
|
||||||
|
case DAMAGE_FIRE:
|
||||||
|
sout << "Heat";
|
||||||
|
break;
|
||||||
|
case DAMAGE_POISON:
|
||||||
|
sout << "Pain";
|
||||||
|
break;
|
||||||
|
case DAMAGE_MAGIC:
|
||||||
|
sout << "Shock";
|
||||||
|
break;
|
||||||
|
case DAMAGE_UNBLOCKABLE:
|
||||||
|
sout << "Wounding";
|
||||||
|
break;
|
||||||
|
case DAMAGE_COLD:
|
||||||
|
sout << "Icy";
|
||||||
|
break;
|
||||||
|
case DAMAGE_UNDEAD:
|
||||||
|
case DAMAGE_DEMON:
|
||||||
|
sout << "Unholy";
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
sout << "*ERROR INVALID DAMAGE TYPE*";
|
||||||
|
}
|
||||||
|
if(abil == MONST_DRAIN_XP_DAMAGE_RAY || abil == MONST_DRAIN_XP_DAMAGE_TOUCH)
|
||||||
|
sout << ", draining";
|
||||||
|
if(abil == MONST_DAMAGE_RAY || abil == MONST_DRAIN_XP_DAMAGE_RAY)
|
||||||
|
sout << " ray";
|
||||||
|
else sout << " touch";
|
||||||
|
break;
|
||||||
|
case MONST_STATUS_RAY:
|
||||||
|
case MONST_STATUS_TOUCH:
|
||||||
|
switch(extra1){
|
||||||
|
case STATUS_BLESS_CURSE:
|
||||||
|
sout << "Curse";
|
||||||
|
break;
|
||||||
|
case STATUS_POISON:
|
||||||
|
sout << "Poison";
|
||||||
|
i = 1;
|
||||||
|
break;
|
||||||
|
case STATUS_HASTE_SLOW:
|
||||||
|
sout << "Slowing";
|
||||||
|
break;
|
||||||
|
case STATUS_WEBS:
|
||||||
|
sout << "Glue";
|
||||||
|
i = 1;
|
||||||
|
break;
|
||||||
|
case STATUS_DISEASE:
|
||||||
|
sout << "Infectious";
|
||||||
|
i = 1;
|
||||||
|
break;
|
||||||
|
case STATUS_DUMB:
|
||||||
|
sout << "Dumbfounding";
|
||||||
|
break;
|
||||||
|
case STATUS_ASLEEP:
|
||||||
|
sout << "Sleep";
|
||||||
|
break;
|
||||||
|
case STATUS_PARALYZED:
|
||||||
|
sout << "Paralysis";
|
||||||
|
break;
|
||||||
|
case STATUS_ACID:
|
||||||
|
sout << "Acid";
|
||||||
|
i = 1;
|
||||||
|
break;
|
||||||
|
default: // Poisoned weapon, invulnerable, magic resistance, sanctuary, martyr's shield, or invalid
|
||||||
|
sout << "*ERROR BAD OR INVALID STATUS TYPE*";
|
||||||
|
}
|
||||||
|
if(abil == MONST_STATUS_RAY)
|
||||||
|
if(i == 1) sout << " spit";
|
||||||
|
else sout << " ray";
|
||||||
|
else sout << " touch";
|
||||||
|
break;
|
||||||
|
case MONST_PETRIFY_RAY:
|
||||||
|
sout << "Petrification ray";
|
||||||
|
break;
|
||||||
|
case MONST_DRAIN_SP_RAY:
|
||||||
|
sout << "Spell point drain ray";
|
||||||
|
break;
|
||||||
|
case MONST_DRAIN_XP_RAY:
|
||||||
|
sout << "Experience draining ray";
|
||||||
|
break;
|
||||||
|
case MONST_KILL_RAY:
|
||||||
|
sout << "Death ray";
|
||||||
|
break;
|
||||||
|
case MONST_STEAL_FOOD_RAY:
|
||||||
|
sout << "Steals food from afar";
|
||||||
|
break;
|
||||||
|
case MONST_STEAL_GOLD_RAY:
|
||||||
|
sout << "Steals gold from afar";
|
||||||
|
break;
|
||||||
|
break;
|
||||||
|
case MONST_PETRIFY_TOUCH:
|
||||||
|
sout << "Petrification touch";
|
||||||
|
break;
|
||||||
|
case MONST_DRAIN_SP_TOUCH:
|
||||||
|
sout << "Spell point draining touch";
|
||||||
|
break;
|
||||||
|
case MONST_DRAIN_XP_TOUCH:
|
||||||
|
sout << "Experience draining touch";
|
||||||
|
break;
|
||||||
|
break;
|
||||||
|
case MONST_KILL_TOUCH:
|
||||||
|
sout << "Death touch";
|
||||||
|
break;
|
||||||
|
case MONST_STEAL_FOOD_TOUCH:
|
||||||
|
sout << "Steals food when hits";
|
||||||
|
break;
|
||||||
|
case MONST_STEAL_GOLD_TOUCH:
|
||||||
|
sout << "Steals gold when hits";
|
||||||
|
break;
|
||||||
|
case MONST_SUMMON_ONE:
|
||||||
|
sout << "Summons " << scenario.scen_monsters[extra1].m_name << "s (" << extra2 <<"% chance)";
|
||||||
|
break;
|
||||||
|
case MONST_SUMMON_TYPE:
|
||||||
|
sout << "Summons ";
|
||||||
|
switch(extra1){
|
||||||
|
case 0:
|
||||||
|
sout << "wildlife";
|
||||||
|
break;
|
||||||
|
case 1:
|
||||||
|
sout << "weak aid";
|
||||||
|
break;
|
||||||
|
case 2:
|
||||||
|
sout << "strong aid";
|
||||||
|
break;
|
||||||
|
case 3:
|
||||||
|
sout << "powerful aid";
|
||||||
|
break;
|
||||||
|
case 4:
|
||||||
|
sout << "friends";
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
sout << " (" << extra2 << "% chance)";
|
||||||
|
break;
|
||||||
|
case MONST_SUMMON_SPECIES:
|
||||||
|
sout << "Summons ";
|
||||||
|
switch(extra1){
|
||||||
|
case RACE_HUMAN:
|
||||||
|
sout << "Humans";
|
||||||
|
break;
|
||||||
|
case RACE_NEPHIL:
|
||||||
|
sout << "Nephilim";
|
||||||
|
break;
|
||||||
|
case RACE_SLITH:
|
||||||
|
sout << "Slithzerikai";
|
||||||
|
break;
|
||||||
|
case RACE_VAHNATAI:
|
||||||
|
sout << "Vahnatai";
|
||||||
|
break;
|
||||||
|
case RACE_REPTILE:
|
||||||
|
sout << "reptiles";
|
||||||
|
break;
|
||||||
|
case RACE_BEAST:
|
||||||
|
sout << "beasts";
|
||||||
|
break;
|
||||||
|
case RACE_HUMANOID:
|
||||||
|
sout << "humanoids";
|
||||||
|
break;
|
||||||
|
case RACE_DEMON:
|
||||||
|
sout << "demons";
|
||||||
|
break;
|
||||||
|
case RACE_UNDEAD:
|
||||||
|
sout << "undead";
|
||||||
|
break;
|
||||||
|
case RACE_GIANT:
|
||||||
|
sout << "giants";
|
||||||
|
break;
|
||||||
|
case RACE_SLIME:
|
||||||
|
sout << "slimes";
|
||||||
|
break;
|
||||||
|
case RACE_STONE:
|
||||||
|
sout << "golems";
|
||||||
|
break;
|
||||||
|
case RACE_BUG:
|
||||||
|
sout << "bugs";
|
||||||
|
break;
|
||||||
|
case RACE_DRAGON:
|
||||||
|
sout << "Dragons";
|
||||||
|
break;
|
||||||
|
case RACE_MAGICAL:
|
||||||
|
sout << "magical creatures";
|
||||||
|
break;
|
||||||
|
case RACE_PLANT:
|
||||||
|
sout << "plants";
|
||||||
|
break;
|
||||||
|
case RACE_BIRD:
|
||||||
|
sout << "birds";
|
||||||
|
break;
|
||||||
|
default: // Important, Mage, Priest, or invalid
|
||||||
|
sout << "*ERROR INVALID RACE*";
|
||||||
|
}
|
||||||
|
sout << " (" << extra2 << "% chance)";
|
||||||
|
break;
|
||||||
|
case MONST_SUMMON_RANDOM:
|
||||||
|
sout << "Summons aid" << " (" << extra2 << "% chance)";
|
||||||
|
break;
|
||||||
|
case MONST_MASS_SUMMON:
|
||||||
|
sout << "Summons aid" << " (" << extra2 << "% chance)";
|
||||||
|
break;
|
||||||
|
case MONST_SPLITS:
|
||||||
|
sout << "Splits when hit" << " (" << extra2 << "% chance)";
|
||||||
|
break;
|
||||||
|
case MONST_FIELD_MISSILE:
|
||||||
|
// TODO: Fill these in
|
||||||
|
sout << "MONST_FIELD_MISSILE";
|
||||||
|
break;
|
||||||
|
case MONST_MARTYRS_SHIELD:
|
||||||
|
sout << "Permanent Martyr's shield";
|
||||||
|
break;
|
||||||
|
case MONST_ABSORB_SPELLS:
|
||||||
|
sout << "Absorbs spells";
|
||||||
|
break;
|
||||||
|
case MONST_INVULNERABLE:
|
||||||
|
sout << "Invulnerable";
|
||||||
|
break;
|
||||||
|
case MONST_RADIATE:
|
||||||
|
sout << "Radiates ";
|
||||||
|
switch(extra1){ // TODO: Fill these in
|
||||||
|
}
|
||||||
|
sout << " (" << extra2 << "% chance)";
|
||||||
|
break;
|
||||||
|
case MONST_CALL_LOCAL_SPECIAL:
|
||||||
|
case MONST_CALL_GLOBAL_SPECIAL:
|
||||||
|
sout << "Unusual ability";
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
return "*ERROR INVALID ABILITY*";
|
||||||
|
}
|
||||||
|
|
||||||
|
std::string cMonster::getAbil1Name() {
|
||||||
|
return (std::string) abil1;
|
||||||
|
}
|
||||||
|
|
||||||
|
std::string cMonster::getAbil2Name() {
|
||||||
|
return (std::string) abil2;
|
||||||
|
}
|
||||||
|
|
||||||
|
bool cMonster::hasAbil(eMonstAbil what, unsigned char* x1, unsigned char* x2){
|
||||||
|
if(abil1.abil == what){
|
||||||
|
if(x1 != NULL) *x1 = abil1.extra1;
|
||||||
|
if(x2 != NULL) *x2 = abil1.extra2;
|
||||||
|
return true;
|
||||||
|
}else if(abil2.abil == what){
|
||||||
|
if(x1 != NULL) *x1 = abil2.extra1;
|
||||||
|
if(x2 != NULL) *x2 = abil2.extra2;
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
@@ -11,6 +11,7 @@
|
|||||||
|
|
||||||
#include <string>
|
#include <string>
|
||||||
#include <iosfwd>
|
#include <iosfwd>
|
||||||
|
#include "soundtool.h"
|
||||||
|
|
||||||
namespace legacy {
|
namespace legacy {
|
||||||
struct monster_record_type;
|
struct monster_record_type;
|
||||||
@@ -18,71 +19,6 @@ namespace legacy {
|
|||||||
struct creature_start_type;
|
struct creature_start_type;
|
||||||
};
|
};
|
||||||
|
|
||||||
typedef unsigned short m_num_t;
|
|
||||||
|
|
||||||
/* adven[i].race */ //complete
|
|
||||||
enum eRace {
|
|
||||||
RACE_UNKNOWN = -1, // for parameters to some functions; not valid in the class
|
|
||||||
RACE_HUMAN = 0,
|
|
||||||
RACE_NEPHIL = 1,
|
|
||||||
RACE_SLITH = 2,
|
|
||||||
RACE_VAHNATAI = 3,
|
|
||||||
RACE_REPTILE = 4,
|
|
||||||
RACE_BEAST = 5,
|
|
||||||
RACE_IMPORTANT = 6,
|
|
||||||
RACE_MAGE = 7,
|
|
||||||
RACE_PRIEST = 8,
|
|
||||||
RACE_HUMANOID = 9,
|
|
||||||
RACE_DEMON = 10,
|
|
||||||
RACE_UNDEAD = 11,
|
|
||||||
RACE_GIANT = 12,
|
|
||||||
RACE_SLIME = 13,
|
|
||||||
RACE_STONE = 14,
|
|
||||||
RACE_BUG = 15,
|
|
||||||
RACE_DRAGON = 16,
|
|
||||||
RACE_MAGICAL = 17,
|
|
||||||
RACE_PLANT = 18,
|
|
||||||
RACE_BIRD = 19,
|
|
||||||
}; // TODO: Expand and merge with eMonsterType
|
|
||||||
|
|
||||||
/* adven[i].status*/ //complete - assign a positive value for a help pc effect, a negative for harm pc
|
|
||||||
enum eStatus {
|
|
||||||
STATUS_POISONED_WEAPON = 0,
|
|
||||||
STATUS_BLESS_CURSE = 1,
|
|
||||||
STATUS_POISON = 2,
|
|
||||||
STATUS_HASTE_SLOW = 3,
|
|
||||||
STATUS_INVULNERABLE = 4,
|
|
||||||
STATUS_MAGIC_RESISTANCE = 5,
|
|
||||||
STATUS_WEBS = 6,
|
|
||||||
STATUS_DISEASE = 7,
|
|
||||||
STATUS_INVISIBLE = 8, //sanctuary
|
|
||||||
STATUS_DUMB = 9,
|
|
||||||
STATUS_MARTYRS_SHIELD = 10,
|
|
||||||
STATUS_ASLEEP = 11,
|
|
||||||
STATUS_PARALYZED = 12,
|
|
||||||
STATUS_ACID = 13,
|
|
||||||
};
|
|
||||||
|
|
||||||
/* Monster Type */
|
|
||||||
enum eMonsterType {
|
|
||||||
MONSTER_TYPE_UNKNOWN = -1, // for parameters to some functions; not valid in the class
|
|
||||||
MONSTER_TYPE_HUMAN = 0,
|
|
||||||
MONSTER_TYPE_REPTILE = 1,
|
|
||||||
MONSTER_TYPE_BEAST = 2,
|
|
||||||
MONSTER_TYPE_IMPORTANT = 3,
|
|
||||||
MONSTER_TYPE_MAGE = 4,
|
|
||||||
MONSTER_TYPE_PRIEST = 5,
|
|
||||||
MONSTER_TYPE_HUMANOID = 6,
|
|
||||||
MONSTER_TYPE_DEMON = 7,
|
|
||||||
MONSTER_TYPE_UNDEAD = 8,
|
|
||||||
MONSTER_TYPE_GIANT = 9,
|
|
||||||
MONSTER_TYPE_SLIME = 10,
|
|
||||||
MONSTER_TYPE_STONE = 11,
|
|
||||||
MONSTER_TYPE_BUG = 12,
|
|
||||||
MONSTER_TYPE_DRAGON = 13,
|
|
||||||
MONSTER_TYPE_MAGICAL = 14,
|
|
||||||
};
|
|
||||||
|
|
||||||
/* Attack Types */
|
/* Attack Types */
|
||||||
|
|
||||||
#define MONSTER_ATTACK_SWINGS 0
|
#define MONSTER_ATTACK_SWINGS 0
|
||||||
@@ -96,16 +32,15 @@ enum eMonsterType {
|
|||||||
#define MONSTER_ATTACK_HARMS 8
|
#define MONSTER_ATTACK_HARMS 8
|
||||||
#define MONSTER_ATTACK_STABS 9
|
#define MONSTER_ATTACK_STABS 9
|
||||||
|
|
||||||
/* Special Ability a.k.a spec_skill */
|
|
||||||
|
|
||||||
#define MONSTER_NO_SPECIAL_ABILITY 0
|
#define MONSTER_NO_SPECIAL_ABILITY 0
|
||||||
#define MONSTER_THROWS_DARTS 1
|
#define MONSTER_THROWS_DARTS 1 //1-6
|
||||||
#define MONSTER_SHOOTS_ARROWS 2
|
#define MONSTER_SHOOTS_ARROWS 2 //2-12
|
||||||
#define MONSTER_THROWS_SPEARS 3
|
#define MONSTER_THROWS_SPEARS 3 //3-18
|
||||||
#define MONSTER_THROWS_ROCKS1 4 //4-24 damages
|
#define MONSTER_THROWS_ROCKS1 4 //4-24 damages
|
||||||
#define MONSTER_THROWS_ROCKS2 5 //5-30 damages
|
#define MONSTER_THROWS_ROCKS2 5 //5-30 damages
|
||||||
#define MONSTER_THROWS_ROCKS3 6 //6-36 damages
|
#define MONSTER_THROWS_ROCKS3 6 //6-36 damages
|
||||||
#define MONSTER_THROWS_RAZORDISKS 7
|
#define MONSTER_THROWS_RAZORDISKS 7 //4-24
|
||||||
#define MONSTER_PETRIFICATION_RAY 8
|
#define MONSTER_PETRIFICATION_RAY 8
|
||||||
#define MONSTER_SP_DRAIN_RAY 9 //spell points drain ray
|
#define MONSTER_SP_DRAIN_RAY 9 //spell points drain ray
|
||||||
#define MONSTER_HEAT_RAY 10
|
#define MONSTER_HEAT_RAY 10
|
||||||
@@ -118,7 +53,7 @@ enum eMonsterType {
|
|||||||
#define MONSTER_ICY_AND_DRAINING_TOUCH 17
|
#define MONSTER_ICY_AND_DRAINING_TOUCH 17
|
||||||
#define MONSTER_SLOWING_TOUCH 18
|
#define MONSTER_SLOWING_TOUCH 18
|
||||||
#define MONSTER_SHOOTS_WEB 19
|
#define MONSTER_SHOOTS_WEB 19
|
||||||
#define MONSTER_GOOD_ARCHER 20
|
#define MONSTER_GOOD_ARCHER 20 //7-42
|
||||||
#define MONSTER_STEALS_FOOD 21
|
#define MONSTER_STEALS_FOOD 21
|
||||||
#define MONSTER_PERMANENT_MARTYRS_SHIELD 22
|
#define MONSTER_PERMANENT_MARTYRS_SHIELD 22
|
||||||
#define MONSTER_PARALYSIS_RAY 23
|
#define MONSTER_PARALYSIS_RAY 23
|
||||||
@@ -132,7 +67,7 @@ enum eMonsterType {
|
|||||||
#define MONSTER_ACID_TOUCH 31
|
#define MONSTER_ACID_TOUCH 31
|
||||||
#define MONSTER_BREATHES_SLEEP_CLOUDS 32
|
#define MONSTER_BREATHES_SLEEP_CLOUDS 32
|
||||||
#define MONSTER_ACID_SPIT 33
|
#define MONSTER_ACID_SPIT 33
|
||||||
#define MONSTER_SHOOTS_SPINES 34
|
#define MONSTER_SHOOTS_SPINES 34 //7-42
|
||||||
#define MONSTER_DEATH_TOUCH 35
|
#define MONSTER_DEATH_TOUCH 35
|
||||||
#define MONSTER_INVULNERABILITY 36
|
#define MONSTER_INVULNERABILITY 36
|
||||||
#define MONSTER_GUARD 37
|
#define MONSTER_GUARD 37
|
||||||
@@ -161,6 +96,11 @@ public:
|
|||||||
operator int();
|
operator int();
|
||||||
cAttack& operator=(int n);
|
cAttack& operator=(int n);
|
||||||
};
|
};
|
||||||
|
struct cAbility{
|
||||||
|
eMonstAbil abil;
|
||||||
|
unsigned char extra1, extra2;
|
||||||
|
operator std::string();
|
||||||
|
};
|
||||||
m_num_t m_num; // TODO: This probably shouldn't be necessary. Consider why it is, and determine if it can be removed
|
m_num_t m_num; // TODO: This probably shouldn't be necessary. Consider why it is, and determine if it can be removed
|
||||||
unsigned char level;
|
unsigned char level;
|
||||||
std::string m_name;
|
std::string m_name;
|
||||||
@@ -180,7 +120,7 @@ public:
|
|||||||
unsigned char breath;
|
unsigned char breath;
|
||||||
unsigned char breath_type;
|
unsigned char breath_type;
|
||||||
unsigned char treasure;
|
unsigned char treasure;
|
||||||
unsigned char spec_skill;
|
unsigned char spec_skill; // TODO: Delete in favour of cAbility
|
||||||
unsigned char poison;
|
unsigned char poison;
|
||||||
short morale,m_morale; // TODO: Move to cCreature (since these are calculated in-game based on the level)
|
short morale,m_morale; // TODO: Move to cCreature (since these are calculated in-game based on the level)
|
||||||
item_num_t corpse_item;
|
item_num_t corpse_item;
|
||||||
@@ -189,14 +129,22 @@ public:
|
|||||||
unsigned char direction; // TODO: Move direction to cCreature
|
unsigned char direction; // TODO: Move direction to cCreature
|
||||||
unsigned char immunities;
|
unsigned char immunities;
|
||||||
unsigned char x_width,y_width;
|
unsigned char x_width,y_width;
|
||||||
unsigned char radiate_1;
|
unsigned char radiate_1; // TODO: Delete in favour of cAbility
|
||||||
unsigned short radiate_2; // I THINK this is the extra field for the second ability
|
unsigned short radiate_2; // I THINK this is the extra field for the second ability TODO: Delete in favour of cAbility
|
||||||
unsigned char default_attitude,summon_type,default_facial_pic,res1,res2,res3;
|
unsigned char default_attitude;
|
||||||
|
unsigned char summon_type;
|
||||||
|
unsigned char default_facial_pic;
|
||||||
short picture_num;
|
short picture_num;
|
||||||
str_num_t see_str1, see_str2;
|
str_num_t see_str1, see_str2;
|
||||||
snd_num_t see_sound, ambient_sound; // ambient_sound has a
|
snd_num_t see_sound, ambient_sound; // ambient_sound has a chance of being played every move
|
||||||
spec_num_t see_spec;
|
spec_num_t see_spec;
|
||||||
|
private:
|
||||||
|
cAbility abil1, abil2;
|
||||||
|
public:
|
||||||
|
|
||||||
|
std::string getAbil1Name();
|
||||||
|
std::string getAbil2Name();
|
||||||
|
bool hasAbil(eMonstAbil what, unsigned char* x1 = NULL, unsigned char* x2 = NULL);
|
||||||
cMonster& operator = (legacy::monster_record_type& old);
|
cMonster& operator = (legacy::monster_record_type& old);
|
||||||
void writeTo(std::ostream& file, std::string prefix);
|
void writeTo(std::ostream& file, std::string prefix);
|
||||||
};
|
};
|
||||||
@@ -232,4 +180,6 @@ std::ostream& operator << (std::ostream& out, eStatus& e);
|
|||||||
std::istream& operator >> (std::istream& in, eStatus& e);
|
std::istream& operator >> (std::istream& in, eStatus& e);
|
||||||
std::ostream& operator << (std::ostream& out, eRace& e);
|
std::ostream& operator << (std::ostream& out, eRace& e);
|
||||||
std::istream& operator >> (std::istream& in, eRace& e);
|
std::istream& operator >> (std::istream& in, eRace& e);
|
||||||
|
std::ostream& operator << (std::ostream& out, eMonstAbil& e);
|
||||||
|
std::istream& operator >> (std::istream& in, eMonstAbil& e);
|
||||||
#endif
|
#endif
|
@@ -464,3 +464,22 @@ cPlayer& cParty::operator[](unsigned short n){
|
|||||||
if(n >= 6) throw std::out_of_range("Attempt to access a player that doesn't exist.");
|
if(n >= 6) throw std::out_of_range("Attempt to access a player that doesn't exist.");
|
||||||
return adven[n];
|
return adven[n];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void cParty::set_ptr(short p, unsigned short sdfx, unsigned short sdfy){ // This function is not used for setting the reserved pointers
|
||||||
|
if(p >= -199 && p <= -100){ // must be a mutable pointer
|
||||||
|
if(sdfx >= 300) throw std::range_error("SDF x-coordinate out of range (0..299)");
|
||||||
|
if(sdfy >= 50) throw std::range_error("SDF y-coordinate out of range (0..49)");
|
||||||
|
pointers[p] = std::make_pair(sdfx,sdfy);
|
||||||
|
}
|
||||||
|
else throw std::range_error("Pointer out of range (-199 to -100)");
|
||||||
|
}
|
||||||
|
|
||||||
|
void cParty::force_ptr(short p, unsigned short sdfx, unsigned short sdfy){
|
||||||
|
pointers[p] = std::make_pair(sdfx,sdfy);
|
||||||
|
}
|
||||||
|
|
||||||
|
unsigned char cParty::get_ptr(short p){
|
||||||
|
ptrIter iter = pointers.find(p);
|
||||||
|
if(iter == pointers.end()) return 0;
|
||||||
|
return stuff_done[iter->second.first][iter->second.second];
|
||||||
|
}
|
||||||
|
@@ -98,7 +98,12 @@ public:
|
|||||||
cMonster summons; // an array of monsters which can be summoned by the parties items yet don't originate from this scenario
|
cMonster summons; // an array of monsters which can be summoned by the parties items yet don't originate from this scenario
|
||||||
bool graphicUsed[250]; // whether each custom graphics slot on the party's sheet is actually used; needed to place new custom graphics on the sheet.
|
bool graphicUsed[250]; // whether each custom graphics slot on the party's sheet is actually used; needed to place new custom graphics on the sheet.
|
||||||
unsigned short scen_won, scen_played; // numbers of scenarios won and played respectively by this party
|
unsigned short scen_won, scen_played; // numbers of scenarios won and played respectively by this party
|
||||||
std::map<std::string,std::vector<int> > campaign_flags;
|
std::map<std::string,std::vector<signed short> > campaign_flags;
|
||||||
|
std::map<short,std::pair<unsigned short,unsigned char> > pointers;
|
||||||
|
|
||||||
|
void set_ptr(short p, unsigned short sdfx, unsigned short sdfy);
|
||||||
|
void force_ptr(short p, unsigned short sdfx, unsigned short sdfy);
|
||||||
|
unsigned char get_ptr(short p);
|
||||||
|
|
||||||
cParty& operator = (legacy::party_record_type& old);
|
cParty& operator = (legacy::party_record_type& old);
|
||||||
void append(legacy::big_tr_type& old);
|
void append(legacy::big_tr_type& old);
|
||||||
@@ -121,7 +126,8 @@ public:
|
|||||||
typedef std::vector<cJournal>::iterator journalIter;
|
typedef std::vector<cJournal>::iterator journalIter;
|
||||||
typedef std::vector<cConvers>::iterator talkIter;
|
typedef std::vector<cConvers>::iterator talkIter;
|
||||||
typedef std::vector<cTimer>::iterator timerIter;
|
typedef std::vector<cTimer>::iterator timerIter;
|
||||||
typedef std::map<std::string,std::vector<int> >::iterator campIter;
|
typedef std::map<std::string,std::vector<signed short> >::iterator campIter;
|
||||||
|
typedef std::map<short,std::pair<unsigned short,unsigned char> >::iterator ptrIter;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif
|
@@ -14,49 +14,6 @@
|
|||||||
|
|
||||||
namespace legacy { struct pc_record_type; };
|
namespace legacy { struct pc_record_type; };
|
||||||
|
|
||||||
/* adven[i].skills */ //complete
|
|
||||||
enum eSkill {
|
|
||||||
SKILL_STRENGTH = 0,
|
|
||||||
SKILL_DEXTERITY = 1,
|
|
||||||
SKILL_INTELLIGENCE = 2,
|
|
||||||
SKILL_EDGED_WEAPONS = 3,
|
|
||||||
SKILL_BASHING_WEAPONS = 4,
|
|
||||||
SKILL_POLE_WEAPONS = 5,
|
|
||||||
SKILL_THROWN_MISSILES = 6,
|
|
||||||
SKILL_ARCHERY = 7,
|
|
||||||
SKILL_DEFENSE = 8,
|
|
||||||
SKILL_MAGE_SPELLS = 9,
|
|
||||||
SKILL_PRIEST_SPELLS = 10,
|
|
||||||
SKILL_MAGE_LORE = 11,
|
|
||||||
SKILL_ALCHEMY = 12,
|
|
||||||
SKILL_ITEM_LORE = 13,
|
|
||||||
SKILL_DISARM_TRAPS = 14,
|
|
||||||
SKILL_LOCKPICKING = 15,
|
|
||||||
SKILL_ASSASSINATION = 16,
|
|
||||||
SKILL_POISON = 17,
|
|
||||||
SKILL_LUCK = 18,
|
|
||||||
};
|
|
||||||
|
|
||||||
/* adven[i].traits */ //complete
|
|
||||||
enum eTrait {
|
|
||||||
TRAIT_TOUGHNESS = 0,
|
|
||||||
TRAIT_MAGICALLY_APT = 1,
|
|
||||||
TRAIT_AMBIDEXTROUS = 2,
|
|
||||||
TRAIT_NIMBLE = 3,
|
|
||||||
TRAIT_CAVE_LORE = 4,
|
|
||||||
TRAIT_WOODSMAN = 5,
|
|
||||||
TRAIT_GOOD_CONST = 6,
|
|
||||||
TRAIT_HIGHLY_ALERT = 7,
|
|
||||||
TRAIT_STRENGTH = 8,
|
|
||||||
TRAIT_RECUPERATION = 9,
|
|
||||||
TRAIT_SLUGGISH = 10,
|
|
||||||
TRAIT_MAGICALLY_INEPT = 11,
|
|
||||||
TRAIT_FRAIL = 12,
|
|
||||||
TRAIT_CHRONIC_DISEASE = 13,
|
|
||||||
TRAIT_BAD_BACK = 14,
|
|
||||||
TRAIT_PACIFIST = 15,
|
|
||||||
};
|
|
||||||
|
|
||||||
enum eMainStatus {
|
enum eMainStatus {
|
||||||
MAIN_STATUS_ABSENT = 0, // absent, empty slot
|
MAIN_STATUS_ABSENT = 0, // absent, empty slot
|
||||||
MAIN_STATUS_ALIVE = 1,
|
MAIN_STATUS_ALIVE = 1,
|
||||||
|
486
osx/classes/simpletypes.h
Normal file
486
osx/classes/simpletypes.h
Normal file
@@ -0,0 +1,486 @@
|
|||||||
|
/*
|
||||||
|
* simpletypes.h
|
||||||
|
* BoE
|
||||||
|
*
|
||||||
|
* Created by Celtic Minstrel on 01/06/09.
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
typedef unsigned short m_num_t;
|
||||||
|
typedef unsigned short ter_num_t;
|
||||||
|
typedef signed short spec_num_t;
|
||||||
|
typedef signed short item_num_t;
|
||||||
|
typedef unsigned short str_num_t;
|
||||||
|
|
||||||
|
/* adven[i].race */ //complete
|
||||||
|
enum eRace {
|
||||||
|
RACE_UNKNOWN = -1, // for parameters to some functions; not valid in the class
|
||||||
|
RACE_HUMAN = 0,
|
||||||
|
RACE_NEPHIL = 1,
|
||||||
|
RACE_SLITH = 2,
|
||||||
|
RACE_VAHNATAI = 3,
|
||||||
|
RACE_REPTILE = 4,
|
||||||
|
RACE_BEAST = 5,
|
||||||
|
RACE_IMPORTANT = 6,
|
||||||
|
RACE_MAGE = 7,
|
||||||
|
RACE_PRIEST = 8,
|
||||||
|
RACE_HUMANOID = 9,
|
||||||
|
RACE_DEMON = 10,
|
||||||
|
RACE_UNDEAD = 11,
|
||||||
|
RACE_GIANT = 12,
|
||||||
|
RACE_SLIME = 13,
|
||||||
|
RACE_STONE = 14,
|
||||||
|
RACE_BUG = 15,
|
||||||
|
RACE_DRAGON = 16,
|
||||||
|
RACE_MAGICAL = 17,
|
||||||
|
RACE_PLANT = 18,
|
||||||
|
RACE_BIRD = 19,
|
||||||
|
}; // TODO: Expand and merge with eMonsterType
|
||||||
|
|
||||||
|
/* adven[i].status*/ //complete - assign a positive value for a help pc effect, a negative for harm pc
|
||||||
|
enum eStatus {
|
||||||
|
STATUS_POISONED_WEAPON = 0,
|
||||||
|
STATUS_BLESS_CURSE = 1,
|
||||||
|
STATUS_POISON = 2,
|
||||||
|
STATUS_HASTE_SLOW = 3,
|
||||||
|
STATUS_INVULNERABLE = 4,
|
||||||
|
STATUS_MAGIC_RESISTANCE = 5,
|
||||||
|
STATUS_WEBS = 6,
|
||||||
|
STATUS_DISEASE = 7,
|
||||||
|
STATUS_INVISIBLE = 8, //sanctuary
|
||||||
|
STATUS_DUMB = 9,
|
||||||
|
STATUS_MARTYRS_SHIELD = 10,
|
||||||
|
STATUS_ASLEEP = 11,
|
||||||
|
STATUS_PARALYZED = 12,
|
||||||
|
STATUS_ACID = 13,
|
||||||
|
};
|
||||||
|
|
||||||
|
/* Monster Type */
|
||||||
|
enum eMonsterType {
|
||||||
|
MONSTER_TYPE_UNKNOWN = -1, // for parameters to some functions; not valid in the class
|
||||||
|
MONSTER_TYPE_HUMAN = 0,
|
||||||
|
MONSTER_TYPE_REPTILE = 1,
|
||||||
|
MONSTER_TYPE_BEAST = 2,
|
||||||
|
MONSTER_TYPE_IMPORTANT = 3,
|
||||||
|
MONSTER_TYPE_MAGE = 4,
|
||||||
|
MONSTER_TYPE_PRIEST = 5,
|
||||||
|
MONSTER_TYPE_HUMANOID = 6,
|
||||||
|
MONSTER_TYPE_DEMON = 7,
|
||||||
|
MONSTER_TYPE_UNDEAD = 8,
|
||||||
|
MONSTER_TYPE_GIANT = 9,
|
||||||
|
MONSTER_TYPE_SLIME = 10,
|
||||||
|
MONSTER_TYPE_STONE = 11,
|
||||||
|
MONSTER_TYPE_BUG = 12,
|
||||||
|
MONSTER_TYPE_DRAGON = 13,
|
||||||
|
MONSTER_TYPE_MAGICAL = 14,
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
/* Special Ability a.k.a spec_skill */
|
||||||
|
|
||||||
|
enum eMonstAbil {
|
||||||
|
MONST_NO_ABIL = 0,
|
||||||
|
// Missile abilities (extra1 = number of sided dice; extra2 = number of sides)
|
||||||
|
MONST_THROWS_DARTS = 10,
|
||||||
|
MONST_SHOOTS_ARROWS,
|
||||||
|
MONST_THROWS_SPEARS,
|
||||||
|
MONST_THROWS_ROCKS,
|
||||||
|
MONST_THROWS_RAZORDISKS,
|
||||||
|
MONST_GOOD_ARCHER,
|
||||||
|
MONST_SHOOTS_SPINES,
|
||||||
|
MONST_THROWS_KNIVES,
|
||||||
|
// Ray abilities (extra1 = type of damage / status where applicable)
|
||||||
|
MONST_DAMAGE_RAY = 20,
|
||||||
|
MONST_STATUS_RAY,
|
||||||
|
MONST_PETRIFY_RAY,
|
||||||
|
MONST_DRAIN_SP_RAY,
|
||||||
|
MONST_DRAIN_XP_RAY,
|
||||||
|
MONST_DRAIN_XP_DAMAGE_RAY,
|
||||||
|
MONST_KILL_RAY,
|
||||||
|
MONST_STEAL_FOOD_RAY,
|
||||||
|
MONST_STEAL_GOLD_RAY,
|
||||||
|
// Touch abilities (extra1 = type of damage / status where applicable)
|
||||||
|
MONST_DAMAGE_TOUCH = 30,
|
||||||
|
MONST_STATUS_TOUCH,
|
||||||
|
MONST_PETRIFY_TOUCH,
|
||||||
|
MONST_DRAIN_SP_TOUCH,
|
||||||
|
MONST_DRAIN_XP_TOUCH,
|
||||||
|
MONST_DRAIN_XP_DAMAGE_TOUCH,
|
||||||
|
MONST_KILL_TOUCH,
|
||||||
|
MONST_STEAL_FOOD_TOUCH,
|
||||||
|
MONST_STEAL_GOLD_TOUCH,
|
||||||
|
// Summon abilities (extra1 = which monster / type / species; extra2 = % chance)
|
||||||
|
MONST_SUMMON_ONE = 40,
|
||||||
|
MONST_SUMMON_TYPE,
|
||||||
|
MONST_SUMMON_SPECIES,
|
||||||
|
MONST_SUMMON_RANDOM,
|
||||||
|
MONST_MASS_SUMMON,
|
||||||
|
// Misc abilities (extra1 = field / special #; extra2 = % chance for radiate only)
|
||||||
|
MONST_SPLITS = 50,
|
||||||
|
MONST_FIELD_MISSILE,
|
||||||
|
MONST_MARTYRS_SHIELD,
|
||||||
|
MONST_ABSORB_SPELLS,
|
||||||
|
MONST_INVULNERABLE,
|
||||||
|
MONST_RADIATE,
|
||||||
|
MONST_CALL_LOCAL_SPECIAL,
|
||||||
|
MONST_CALL_GLOBAL_SPECIAL,
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
/* Terrains Specials Properties : scenario.ter_types[i].special */ //complete
|
||||||
|
|
||||||
|
enum eTerSpec {
|
||||||
|
// TER_SPEC_NONE = 0,
|
||||||
|
// TER_SPEC_CHANGE_WHEN_STEP_ON = 1,
|
||||||
|
// TER_SPEC_DOES_FIRE_DAMAGE = 2,
|
||||||
|
// TER_SPEC_DOES_COLD_DAMAGE = 3,
|
||||||
|
// TER_SPEC_DOES_MAGIC_DAMAGE = 4,
|
||||||
|
// TER_SPEC_POISON_LAND = 5,
|
||||||
|
// TER_SPEC_DISEASED_LAND = 6,
|
||||||
|
// TER_SPEC_CRUMBLING_TERRAIN = 7,
|
||||||
|
// TER_SPEC_LOCKABLE_TERRAIN = 8,
|
||||||
|
// TER_SPEC_UNLOCKABLE_TERRAIN = 9,
|
||||||
|
// TER_SPEC_UNLOCKABLE_BASHABLE = 10,
|
||||||
|
// TER_SPEC_IS_A_SIGN = 11,
|
||||||
|
// TER_SPEC_CALL_LOCAL_SPECIAL = 12,
|
||||||
|
// TER_SPEC_CALL_SCENARIO_SPECIAL = 13,
|
||||||
|
// TER_SPEC_IS_A_CONTAINER = 14,
|
||||||
|
// TER_SPEC_WATERFALL = 15,
|
||||||
|
// TER_SPEC_CONVEYOR_NORTH = 16,
|
||||||
|
// TER_SPEC_CONVEYOR_EAST = 17,
|
||||||
|
// TER_SPEC_CONVEYOR_SOUTH = 18,
|
||||||
|
// TER_SPEC_CONVEYOR_WEST = 19,
|
||||||
|
// TER_SPEC_BLOCKED_TO_MONSTERS = 20,
|
||||||
|
// TER_SPEC_TOWN_ENTRANCE = 21,
|
||||||
|
// TER_SPEC_CHANGE_WHEN_USED = 22,
|
||||||
|
// TER_SPEC_CALL_SPECIAL_WHEN_USED = 23,
|
||||||
|
TER_SPEC_NONE = 0,
|
||||||
|
TER_SPEC_CHANGE_WHEN_STEP_ON = 1,
|
||||||
|
TER_SPEC_DAMAGING = 2,
|
||||||
|
TER_SPEC_BRIDGE = 3, // new
|
||||||
|
TER_SPEC_BED = 4, // new
|
||||||
|
TER_SPEC_DANGEROUS = 5,
|
||||||
|
TER_SPEC_UNUSED1 = 6,
|
||||||
|
TER_SPEC_CRUMBLING = 7,
|
||||||
|
TER_SPEC_LOCKABLE = 8,
|
||||||
|
TER_SPEC_UNLOCKABLE = 9,
|
||||||
|
TER_SPEC_UNUSED2 = 10,
|
||||||
|
TER_SPEC_IS_A_SIGN = 11,
|
||||||
|
TER_SPEC_CALL_SPECIAL = 12,
|
||||||
|
TER_SPEC_UNUSED3 = 13,
|
||||||
|
TER_SPEC_IS_A_CONTAINER = 14,
|
||||||
|
TER_SPEC_WATERFALL = 15,
|
||||||
|
TER_SPEC_CONVEYOR = 16,
|
||||||
|
TER_SPEC_UNUSED4 = 17,
|
||||||
|
TER_SPEC_UNUSED5 = 18,
|
||||||
|
TER_SPEC_UNUSED6 = 19,
|
||||||
|
TER_SPEC_BLOCKED_TO_MONSTERS = 20,
|
||||||
|
TER_SPEC_TOWN_ENTRANCE = 21,
|
||||||
|
TER_SPEC_CHANGE_WHEN_USED = 22,
|
||||||
|
TER_SPEC_CALL_SPECIAL_WHEN_USED = 23,
|
||||||
|
// 1. Change when step on (What to change to, number of sound, Unused)
|
||||||
|
// 2. Damaging terrain; can't rest here (Amount of damage done, multiplier, damage type)
|
||||||
|
// 3. Reserved
|
||||||
|
// 4. Reserved
|
||||||
|
// 5. Dangerous land; can't rest here; percentage chance may be 0 (Strength, Percentage chance, status type)
|
||||||
|
// 6. Reserved
|
||||||
|
// 7. Crumbling terrain (Terrain to change to, strength?, destroyed by what - quickfire, shatter/move mountains, or both)
|
||||||
|
// 8. Lockable terrain (Terrain to change to when locked, Unused, Unused)
|
||||||
|
// 9. Unlockable terrain (Terrain to change to when locked, Difficulty, can be bashed)
|
||||||
|
// 10. Reserved
|
||||||
|
// 11. Sign (Unused, Unused, Unused)
|
||||||
|
// 12. Call special (Special to call, local or scenario?, Unused)
|
||||||
|
// 13. Reserved
|
||||||
|
// 14. Container (Unused, Unused, Unused)
|
||||||
|
// 15. Waterfall (Direction, Unused, Unused)
|
||||||
|
// 16. Conveyor Belt (Direction, Unused, Unused)
|
||||||
|
// 17. Reserved
|
||||||
|
// 18. Reserved
|
||||||
|
// 19. Reserved
|
||||||
|
// 20. Blocked to Monsters (Unused, Unused, Unused)
|
||||||
|
// 21. Town entrance (Terrain type if hidden, Unused, Unused)
|
||||||
|
// 22. Change when Used (Terrain to change to when used, Number of sound, Unused)
|
||||||
|
// 23. Call special when used (Special to call, local or scenario?, Unused)
|
||||||
|
// 24. Bridge - if the party boats over it, they get the option to land. (Unused, Unused, Unused)
|
||||||
|
};
|
||||||
|
|
||||||
|
enum eTrimType {
|
||||||
|
TRIM_NONE = 0,
|
||||||
|
TRIM_WALL = 1, // not a trim, but trims will conform to it as if it's the same ground type (eg stone wall)
|
||||||
|
TRIM_S, TRIM_SE, TRIM_E, TRIM_NE, TRIM_N, TRIM_NW, TRIM_W, TRIM_SW,
|
||||||
|
TRIM_NE_INNER, TRIM_SE_INNER, TRIM_SW_INNER, TRIM_NW_INNER,
|
||||||
|
TRIM_FRILLS = 14, // like on lava and underground water; no trim_ter required
|
||||||
|
TRIM_ROAD = 15, // the game will treat it like a road space and draw roads; no trim_ter required
|
||||||
|
TRIM_WALKWAY = 16, // the game will draw walkway corners; trim_ter is base terrain to draw on
|
||||||
|
TRIM_WATERFALL = 17, // special case for waterfalls
|
||||||
|
TRIM_CITY = 18, // the game will join roads up to this space but not draw roads on the space
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
/* items[i].type a.k.a type of weapon */
|
||||||
|
enum eWeapType {
|
||||||
|
ITEM_NOT_MELEE = 0,
|
||||||
|
ITEM_EDGED = 1,
|
||||||
|
ITEM_BASHING = 2,
|
||||||
|
ITEM_POLE = 3,
|
||||||
|
};
|
||||||
|
|
||||||
|
/* items[i].variety a.k.a item type (in editor) */
|
||||||
|
enum eItemType {
|
||||||
|
ITEM_TYPE_NO_ITEM = 0,
|
||||||
|
ITEM_TYPE_ONE_HANDED = 1,
|
||||||
|
ITEM_TYPE_TWO_HANDED = 2,
|
||||||
|
ITEM_TYPE_GOLD = 3,
|
||||||
|
ITEM_TYPE_BOW = 4,
|
||||||
|
ITEM_TYPE_ARROW = 5,
|
||||||
|
ITEM_TYPE_THROWN_MISSILE = 6,
|
||||||
|
ITEM_TYPE_POTION = 7, // potion/magic item
|
||||||
|
ITEM_TYPE_SCROLL = 8, // scroll/magic item
|
||||||
|
ITEM_TYPE_WAND = 9,
|
||||||
|
ITEM_TYPE_TOOL = 10,
|
||||||
|
ITEM_TYPE_FOOD = 11,
|
||||||
|
ITEM_TYPE_SHIELD = 12,
|
||||||
|
ITEM_TYPE_ARMOR = 13,
|
||||||
|
ITEM_TYPE_HELM = 14,
|
||||||
|
ITEM_TYPE_GLOVES = 15,
|
||||||
|
ITEM_TYPE_SHIELD_2 = 16,
|
||||||
|
// don't know why a second type of shield is used ; it is actually checked
|
||||||
|
// in the armor code (item >= 12 and <= 17)
|
||||||
|
// and you can't equip another (12) shield while wearing it ... I didn't
|
||||||
|
// find a single item with this property in the bladbase.exs ...
|
||||||
|
ITEM_TYPE_BOOTS = 17,
|
||||||
|
ITEM_TYPE_RING = 18,
|
||||||
|
ITEM_TYPE_NECKLACE = 19,
|
||||||
|
ITEM_TYPE_WEAPON_POISON = 20,
|
||||||
|
ITEM_TYPE_NON_USE_OBJECT = 21,
|
||||||
|
ITEM_TYPE_PANTS = 22,
|
||||||
|
ITEM_TYPE_CROSSBOW = 23,
|
||||||
|
ITEM_TYPE_BOLTS = 24,
|
||||||
|
ITEM_TYPE_MISSILE_NO_AMMO = 25, //e.g slings
|
||||||
|
ITEM_TYPE_UNUSED1 = 26, // these are here solely because they are options in the editor
|
||||||
|
ITEM_TYPE_UNUSED2 = 27,
|
||||||
|
};
|
||||||
|
|
||||||
|
/* items[i].ability */
|
||||||
|
enum eItemAbil {
|
||||||
|
// Weapon abilities
|
||||||
|
ITEM_NO_ABILITY = 0,
|
||||||
|
ITEM_FLAMING_WEAPON = 1,
|
||||||
|
ITEM_DEMON_SLAYER = 2,
|
||||||
|
ITEM_UNDEAD_SLAYER = 3,
|
||||||
|
ITEM_LIZARD_SLAYER = 4,
|
||||||
|
ITEM_GIANT_SLAYER = 5,
|
||||||
|
ITEM_MAGE_SLAYER = 6,
|
||||||
|
ITEM_PRIEST_SLAYER = 7,
|
||||||
|
ITEM_BUG_SLAYER = 8,
|
||||||
|
ITEM_ACIDIC_WEAPON = 9,
|
||||||
|
ITEM_SOULSUCKER = 10,
|
||||||
|
ITEM_DRAIN_MISSILES = 11,
|
||||||
|
ITEM_WEAK_WEAPON = 12,
|
||||||
|
ITEM_CAUSES_FEAR = 13,
|
||||||
|
ITEM_POISONED_WEAPON = 14,
|
||||||
|
// General abilities
|
||||||
|
ITEM_PROTECTION = 30,
|
||||||
|
ITEM_FULL_PROTECTION = 31,
|
||||||
|
ITEM_FIRE_PROTECTION = 32,
|
||||||
|
ITEM_COLD_PROTECTION = 33,
|
||||||
|
ITEM_POISON_PROTECTION = 34,
|
||||||
|
ITEM_MAGIC_PROTECTION = 35,
|
||||||
|
ITEM_ACID_PROTECTION = 36,
|
||||||
|
ITEM_SKILL = 37,
|
||||||
|
ITEM_STRENGTH = 38,
|
||||||
|
ITEM_DEXTERITY = 39,
|
||||||
|
ITEM_INTELLIGENCE = 40,
|
||||||
|
ITEM_ACCURACY = 41,
|
||||||
|
ITEM_THIEVING = 42,
|
||||||
|
ITEM_GIANT_STRENGTH = 43,
|
||||||
|
ITEM_LIGHTER_OBJECT = 44,
|
||||||
|
ITEM_HEAVIER_OBJECT = 45,
|
||||||
|
ITEM_OCCASIONAL_BLESS = 46,
|
||||||
|
ITEM_OCCASIONAL_HASTE = 47,
|
||||||
|
ITEM_LIFE_SAVING = 48,
|
||||||
|
ITEM_PROTECT_FROM_PETRIFY = 49,
|
||||||
|
ITEM_REGENERATE = 50,
|
||||||
|
ITEM_POISON_AUGMENT = 51,
|
||||||
|
ITEM_DISEASE_PARTY = 52,
|
||||||
|
ITEM_WILL = 53,
|
||||||
|
ITEM_FREE_ACTION = 54,
|
||||||
|
ITEM_SPEED = 55,
|
||||||
|
ITEM_SLOW_WEARER = 56,
|
||||||
|
ITEM_PROTECT_FROM_UNDEAD = 57,
|
||||||
|
ITEM_PROTECT_FROM_DEMONS = 58,
|
||||||
|
ITEM_PROTECT_FROM_HUMANOIDS = 59,
|
||||||
|
ITEM_PROTECT_FROM_REPTILES = 60,
|
||||||
|
ITEM_PROTECT_FROM_GIANTS = 61,
|
||||||
|
ITEM_PROTECT_FROM_DISEASE = 62,
|
||||||
|
// Nonspell Usable
|
||||||
|
ITEM_POISON_WEAPON = 70, //put poison on weapon
|
||||||
|
ITEM_BLESS_CURSE = 71,
|
||||||
|
ITEM_AFFECT_POISON = 72,
|
||||||
|
ITEM_HASTE_SLOW = 73,
|
||||||
|
ITEM_AFFECT_INVULN = 74,
|
||||||
|
ITEM_AFFECT_MAGIC_RES = 75,
|
||||||
|
ITEM_AFFECT_WEB = 76,
|
||||||
|
ITEM_AFFECT_DISEASE = 77,
|
||||||
|
ITEM_AFFECT_SANCTUARY = 78,
|
||||||
|
ITEM_AFFECT_DUMBFOUND = 79,
|
||||||
|
ITEM_AFFECT_MARTYRS_SHIELD = 80,
|
||||||
|
ITEM_AFFECT_SLEEP = 81,
|
||||||
|
ITEM_AFFECT_PARALYSIS = 82,
|
||||||
|
ITEM_AFFECT_ACID = 83,
|
||||||
|
ITEM_BLISS = 84,
|
||||||
|
ITEM_AFFECT_EXPERIENCE = 85,
|
||||||
|
ITEM_AFFECT_SKILL_POINTS = 86,
|
||||||
|
ITEM_AFFECT_HEALTH = 87,
|
||||||
|
ITEM_AFFECT_SPELL_POINTS = 88,
|
||||||
|
ITEM_DOOM = 89,
|
||||||
|
ITEM_LIGHT = 90,
|
||||||
|
ITEM_STEALTH = 91,
|
||||||
|
ITEM_FIREWALK = 92,
|
||||||
|
ITEM_FLYING = 93,
|
||||||
|
ITEM_MAJOR_HEALING = 94,
|
||||||
|
// Spell Usable
|
||||||
|
ITEM_SPELL_FLAME = 110,
|
||||||
|
ITEM_SPELL_FIREBALL = 111,
|
||||||
|
ITEM_SPELL_FIRESTORM = 112,
|
||||||
|
ITEM_SPELL_KILL = 113,
|
||||||
|
ITEM_SPELL_ICE_BOLT = 114,
|
||||||
|
ITEM_SPELL_SLOW = 115,
|
||||||
|
ITEM_SPELL_SHOCKWAVE = 116,
|
||||||
|
ITEM_SPELL_DISPEL_UNDEAD = 117,
|
||||||
|
ITEM_SPELL_DISPEL_SPIRIT = 118,
|
||||||
|
ITEM_SPELL_SUMMONING = 119,
|
||||||
|
ITEM_SPELL_MASS_SUMMONING = 120,
|
||||||
|
ITEM_SPELL_ACID_SPRAY = 121,
|
||||||
|
ITEM_SPELL_STINKING_CLOUD = 122,
|
||||||
|
ITEM_SPELL_SLEEP_FIELD = 123,
|
||||||
|
ITEM_SPELL_VENOM = 124,
|
||||||
|
ITEM_SPELL_SHOCKSTORM = 125,
|
||||||
|
ITEM_SPELL_PARALYSIS = 126,
|
||||||
|
ITEM_SPELL_WEB_SPELL = 127,
|
||||||
|
ITEM_SPELL_STRENGTHEN_TARGET = 128, //wand of carrunos effect
|
||||||
|
ITEM_SPELL_QUICKFIRE = 129,
|
||||||
|
ITEM_SPELL_MASS_CHARM = 130,
|
||||||
|
ITEM_SPELL_MAGIC_MAP = 131,
|
||||||
|
ITEM_SPELL_DISPEL_BARRIER = 132,
|
||||||
|
ITEM_SPELL_MAKE_ICE_WALL = 133,
|
||||||
|
ITEM_SPELL_CHARM_SPELL = 134,
|
||||||
|
ITEM_SPELL_ANTIMAGIC_CLOUD = 135,
|
||||||
|
// Reagents
|
||||||
|
ITEM_HOLLY = 150, // Holly/Toadstool
|
||||||
|
ITEM_COMFREY_ROOT = 151,
|
||||||
|
ITEM_GLOWING_NETTLE = 152,
|
||||||
|
ITEM_WORMGRASS = 153, // Crypt Shroom/Wormgr.
|
||||||
|
ITEM_ASPTONGUE_MOLD = 154,
|
||||||
|
ITEM_EMBER_FLOWERS = 155,
|
||||||
|
ITEM_GRAYMOLD = 156,
|
||||||
|
ITEM_MANDRAKE = 157,
|
||||||
|
ITEM_SAPPHIRE = 158,
|
||||||
|
ITEM_SMOKY_CRYSTAL = 159,
|
||||||
|
ITEM_RESSURECTION_BALM = 160,
|
||||||
|
ITEM_LOCKPICKS = 161,
|
||||||
|
// Missile Abilities
|
||||||
|
ITEM_MISSILE_RETURNING = 170,
|
||||||
|
ITEM_MISSILE_LIGHTNING = 171,
|
||||||
|
ITEM_MISSILE_EXPLODING = 172,
|
||||||
|
ITEM_MISSILE_ACID = 173,
|
||||||
|
ITEM_MISSILE_SLAY_UNDEAD = 174,
|
||||||
|
ITEM_MISSILE_SLAY_DEMON = 175,
|
||||||
|
ITEM_MISSILE_HEAL_TARGET = 176,
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
/* adven[i].skills */ //complete
|
||||||
|
enum eSkill {
|
||||||
|
SKILL_STRENGTH = 0,
|
||||||
|
SKILL_DEXTERITY = 1,
|
||||||
|
SKILL_INTELLIGENCE = 2,
|
||||||
|
SKILL_EDGED_WEAPONS = 3,
|
||||||
|
SKILL_BASHING_WEAPONS = 4,
|
||||||
|
SKILL_POLE_WEAPONS = 5,
|
||||||
|
SKILL_THROWN_MISSILES = 6,
|
||||||
|
SKILL_ARCHERY = 7,
|
||||||
|
SKILL_DEFENSE = 8,
|
||||||
|
SKILL_MAGE_SPELLS = 9,
|
||||||
|
SKILL_PRIEST_SPELLS = 10,
|
||||||
|
SKILL_MAGE_LORE = 11,
|
||||||
|
SKILL_ALCHEMY = 12,
|
||||||
|
SKILL_ITEM_LORE = 13,
|
||||||
|
SKILL_DISARM_TRAPS = 14,
|
||||||
|
SKILL_LOCKPICKING = 15,
|
||||||
|
SKILL_ASSASSINATION = 16,
|
||||||
|
SKILL_POISON = 17,
|
||||||
|
SKILL_LUCK = 18,
|
||||||
|
};
|
||||||
|
|
||||||
|
/* adven[i].traits */ //complete
|
||||||
|
enum eTrait {
|
||||||
|
TRAIT_TOUGHNESS = 0,
|
||||||
|
TRAIT_MAGICALLY_APT = 1,
|
||||||
|
TRAIT_AMBIDEXTROUS = 2,
|
||||||
|
TRAIT_NIMBLE = 3,
|
||||||
|
TRAIT_CAVE_LORE = 4,
|
||||||
|
TRAIT_WOODSMAN = 5,
|
||||||
|
TRAIT_GOOD_CONST = 6,
|
||||||
|
TRAIT_HIGHLY_ALERT = 7,
|
||||||
|
TRAIT_STRENGTH = 8,
|
||||||
|
TRAIT_RECUPERATION = 9,
|
||||||
|
TRAIT_SLUGGISH = 10,
|
||||||
|
TRAIT_MAGICALLY_INEPT = 11,
|
||||||
|
TRAIT_FRAIL = 12,
|
||||||
|
TRAIT_CHRONIC_DISEASE = 13,
|
||||||
|
TRAIT_BAD_BACK = 14,
|
||||||
|
TRAIT_PACIFIST = 15,
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
/* damage type*/
|
||||||
|
/* used as parameter to some functions */
|
||||||
|
enum eDamageType {
|
||||||
|
DAMAGE_WEAPON = 0,
|
||||||
|
DAMAGE_FIRE = 1,
|
||||||
|
DAMAGE_POISON = 2,
|
||||||
|
DAMAGE_MAGIC = 3,
|
||||||
|
DAMAGE_UNBLOCKABLE = 4, //from the source files - the display is the same as the magic one (damage_monst in SPECIALS.cpp)
|
||||||
|
DAMAGE_COLD = 5,
|
||||||
|
DAMAGE_UNDEAD = 6, //from the source files - the display is the same as the weapon one
|
||||||
|
DAMAGE_DEMON = 7, //from the source files - the display is the same as the weapon one
|
||||||
|
// 8 and 9 aren't defined : doesn't print any damage. According to the source files the 9 is DAMAGE_MARKED though. Wrong ?
|
||||||
|
DAMAGE_MARKED = 10, // usage: DAMAGE_MARKED + damage_type
|
||||||
|
DAMAGE_WEAPON_MARKED = 10,
|
||||||
|
DAMAGE_FIRE_MARKED = 11,
|
||||||
|
DAMAGE_POISON_MARKED = 12,
|
||||||
|
DAMAGE_MAGIC_MARKED = 13,
|
||||||
|
DAMAGE_UNBLOCKABLE_MARKED = 14,
|
||||||
|
DAMAGE_COLD_MARKED = 15,
|
||||||
|
DAMAGE_UNDEAD_MARKED = 16,
|
||||||
|
DAMAGE_DEMON_MARKED = 17,
|
||||||
|
DAMAGE_NO_PRINT = 30, // usage: DAMAGE_NO_PRINT + damage_type
|
||||||
|
DAMAGE_WEAPON_NO_PRINT = 30,
|
||||||
|
DAMAGE_FIRE_NO_PRINT = 31,
|
||||||
|
DAMAGE_POISON_NO_PRINT = 32,
|
||||||
|
DAMAGE_MAGIC_NO_PRINT = 33,
|
||||||
|
DAMAGE_UNBLOCKABLE_NO_PRINT = 34,
|
||||||
|
DAMAGE_COLD_NO_PRINT = 35,
|
||||||
|
DAMAGE_UNDEAD_NO_PRINT = 36,
|
||||||
|
DAMAGE_DEMON_NO_PRINT = 37,
|
||||||
|
// What about both NO_PRINT and MARKED?
|
||||||
|
};
|
||||||
|
|
||||||
|
inline void operator -= (eDamageType& cur, eDamageType othr){
|
||||||
|
if((othr == DAMAGE_MARKED && cur >= DAMAGE_MARKED && cur < DAMAGE_NO_PRINT) ||
|
||||||
|
(othr == DAMAGE_NO_PRINT && cur >= DAMAGE_NO_PRINT))
|
||||||
|
cur = (eDamageType) ((int)cur - (int)othr);
|
||||||
|
}
|
||||||
|
|
||||||
|
inline void operator += (eDamageType& cur, eDamageType othr){
|
||||||
|
if((othr == DAMAGE_MARKED || othr == DAMAGE_NO_PRINT) && cur < DAMAGE_MARKED)
|
||||||
|
cur = (eDamageType) ((int)cur + (int)othr);
|
||||||
|
}
|
||||||
|
|
||||||
|
//class sbyte {
|
||||||
|
// signed char c;
|
||||||
|
//public:
|
||||||
|
// operator int() {return c;}
|
||||||
|
// sbyte(signed char k) : c(k) {}
|
||||||
|
//}
|
@@ -13,8 +13,6 @@
|
|||||||
|
|
||||||
namespace legacy { struct special_node_type; };
|
namespace legacy { struct special_node_type; };
|
||||||
|
|
||||||
typedef signed short spec_num_t;
|
|
||||||
|
|
||||||
class cSpecial {
|
class cSpecial {
|
||||||
public:
|
public:
|
||||||
short type;
|
short type;
|
||||||
|
@@ -14,97 +14,6 @@
|
|||||||
|
|
||||||
namespace legacy { struct terrain_type_type; };
|
namespace legacy { struct terrain_type_type; };
|
||||||
|
|
||||||
/* Terrains Specials Properties : scenario.ter_types[i].special */ //complete
|
|
||||||
|
|
||||||
typedef unsigned short ter_num_t;
|
|
||||||
|
|
||||||
enum eTerSpec {
|
|
||||||
// TER_SPEC_NONE = 0,
|
|
||||||
// TER_SPEC_CHANGE_WHEN_STEP_ON = 1,
|
|
||||||
// TER_SPEC_DOES_FIRE_DAMAGE = 2,
|
|
||||||
// TER_SPEC_DOES_COLD_DAMAGE = 3,
|
|
||||||
// TER_SPEC_DOES_MAGIC_DAMAGE = 4,
|
|
||||||
// TER_SPEC_POISON_LAND = 5,
|
|
||||||
// TER_SPEC_DISEASED_LAND = 6,
|
|
||||||
// TER_SPEC_CRUMBLING_TERRAIN = 7,
|
|
||||||
// TER_SPEC_LOCKABLE_TERRAIN = 8,
|
|
||||||
// TER_SPEC_UNLOCKABLE_TERRAIN = 9,
|
|
||||||
// TER_SPEC_UNLOCKABLE_BASHABLE = 10,
|
|
||||||
// TER_SPEC_IS_A_SIGN = 11,
|
|
||||||
// TER_SPEC_CALL_LOCAL_SPECIAL = 12,
|
|
||||||
// TER_SPEC_CALL_SCENARIO_SPECIAL = 13,
|
|
||||||
// TER_SPEC_IS_A_CONTAINER = 14,
|
|
||||||
// TER_SPEC_WATERFALL = 15,
|
|
||||||
// TER_SPEC_CONVEYOR_NORTH = 16,
|
|
||||||
// TER_SPEC_CONVEYOR_EAST = 17,
|
|
||||||
// TER_SPEC_CONVEYOR_SOUTH = 18,
|
|
||||||
// TER_SPEC_CONVEYOR_WEST = 19,
|
|
||||||
// TER_SPEC_BLOCKED_TO_MONSTERS = 20,
|
|
||||||
// TER_SPEC_TOWN_ENTRANCE = 21,
|
|
||||||
// TER_SPEC_CHANGE_WHEN_USED = 22,
|
|
||||||
// TER_SPEC_CALL_SPECIAL_WHEN_USED = 23,
|
|
||||||
TER_SPEC_NONE = 0,
|
|
||||||
TER_SPEC_CHANGE_WHEN_STEP_ON = 1,
|
|
||||||
TER_SPEC_DAMAGING = 2,
|
|
||||||
TER_SPEC_BRIDGE = 3, // new
|
|
||||||
TER_SPEC_BED = 4, // new
|
|
||||||
TER_SPEC_DANGEROUS = 5,
|
|
||||||
TER_SPEC_UNUSED1 = 6,
|
|
||||||
TER_SPEC_CRUMBLING = 7,
|
|
||||||
TER_SPEC_LOCKABLE = 8,
|
|
||||||
TER_SPEC_UNLOCKABLE = 9,
|
|
||||||
TER_SPEC_UNUSED2 = 10,
|
|
||||||
TER_SPEC_IS_A_SIGN = 11,
|
|
||||||
TER_SPEC_CALL_SPECIAL = 12,
|
|
||||||
TER_SPEC_UNUSED3 = 13,
|
|
||||||
TER_SPEC_IS_A_CONTAINER = 14,
|
|
||||||
TER_SPEC_WATERFALL = 15,
|
|
||||||
TER_SPEC_CONVEYOR = 16,
|
|
||||||
TER_SPEC_UNUSED4 = 17,
|
|
||||||
TER_SPEC_UNUSED5 = 18,
|
|
||||||
TER_SPEC_UNUSED6 = 19,
|
|
||||||
TER_SPEC_BLOCKED_TO_MONSTERS = 20,
|
|
||||||
TER_SPEC_TOWN_ENTRANCE = 21,
|
|
||||||
TER_SPEC_CHANGE_WHEN_USED = 22,
|
|
||||||
TER_SPEC_CALL_SPECIAL_WHEN_USED = 23,
|
|
||||||
// 1. Change when step on (What to change to, number of sound, Unused)
|
|
||||||
// 2. Damaging terrain; can't rest here (Amount of damage done, multiplier, damage type)
|
|
||||||
// 3. Reserved
|
|
||||||
// 4. Reserved
|
|
||||||
// 5. Dangerous land; can't rest here; percentage chance may be 0 (Strength, Percentage chance, status type)
|
|
||||||
// 6. Reserved
|
|
||||||
// 7. Crumbling terrain (Terrain to change to, strength?, destroyed by what - quickfire, shatter/move mountains, or both)
|
|
||||||
// 8. Lockable terrain (Terrain to change to when locked, Unused, Unused)
|
|
||||||
// 9. Unlockable terrain (Terrain to change to when locked, Difficulty, can be bashed)
|
|
||||||
// 10. Reserved
|
|
||||||
// 11. Sign (Unused, Unused, Unused)
|
|
||||||
// 12. Call special (Special to call, local or scenario?, Unused)
|
|
||||||
// 13. Reserved
|
|
||||||
// 14. Container (Unused, Unused, Unused)
|
|
||||||
// 15. Waterfall (Direction, Unused, Unused)
|
|
||||||
// 16. Conveyor Belt (Direction, Unused, Unused)
|
|
||||||
// 17. Reserved
|
|
||||||
// 18. Reserved
|
|
||||||
// 19. Reserved
|
|
||||||
// 20. Blocked to Monsters (Unused, Unused, Unused)
|
|
||||||
// 21. Town entrance (Terrain type if hidden, Unused, Unused)
|
|
||||||
// 22. Change when Used (Terrain to change to when used, Number of sound, Unused)
|
|
||||||
// 23. Call special when used (Special to call, local or scenario?, Unused)
|
|
||||||
// 24. Bridge - if the party boats over it, they get the option to land. (Unused, Unused, Unused)
|
|
||||||
};
|
|
||||||
|
|
||||||
enum eTrimType {
|
|
||||||
TRIM_NONE = 0,
|
|
||||||
TRIM_WALL = 1, // not a trim, but trims will conform to it as if it's the same ground type (eg stone wall)
|
|
||||||
TRIM_S, TRIM_SE, TRIM_E, TRIM_NE, TRIM_N, TRIM_NW, TRIM_W, TRIM_SW,
|
|
||||||
TRIM_NE_INNER, TRIM_SE_INNER, TRIM_SW_INNER, TRIM_NW_INNER,
|
|
||||||
TRIM_FRILLS = 14, // like on lava and underground water; no trim_ter required
|
|
||||||
TRIM_ROAD = 15, // the game will treat it like a road space and draw roads; no trim_ter required
|
|
||||||
TRIM_WALKWAY = 16, // the game will draw walkway corners; trim_ter is base terrain to draw on
|
|
||||||
TRIM_WATERFALL = 17, // special case for waterfalls
|
|
||||||
TRIM_CITY = 18, // the game will join roads up to this space but not draw roads on the space
|
|
||||||
};
|
|
||||||
|
|
||||||
// Depending on the special ability, the flags may need to be treated as either signed or unsigned
|
// Depending on the special ability, the flags may need to be treated as either signed or unsigned
|
||||||
union ter_flag_t {signed short s; unsigned short u;};
|
union ter_flag_t {signed short s; unsigned short u;};
|
||||||
|
|
||||||
|
@@ -6,6 +6,8 @@
|
|||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#ifndef _SOUNDTOOL_H
|
||||||
|
#define _SOUNDTOOL_H
|
||||||
#define NUM_SOUNDS 99
|
#define NUM_SOUNDS 99
|
||||||
|
|
||||||
typedef unsigned short snd_num_t;
|
typedef unsigned short snd_num_t;
|
||||||
@@ -14,3 +16,5 @@ void play_sound(short which, short how_many_times = 1);
|
|||||||
void one_sound(short which);
|
void one_sound(short which);
|
||||||
void clear_sound_memory();
|
void clear_sound_memory();
|
||||||
void flip_sound();
|
void flip_sound();
|
||||||
|
|
||||||
|
#endif
|
||||||
|
Reference in New Issue
Block a user