/* This file has been generated by IDA. It contains local type definitions from C:\Users\jkoppel\Dropbox\H2ReverseEng\HEROES2W.idb */ /* 1 */ enum spellpower_offset { MAX_STACKS = 0x14, }; /* 2 */ enum CREATURE_FLAGS { TWO_HEXER = 0x1, FLYER = 0x2, SHOOTER = 0x4, TWO_HEX_ATTACKER = 0x8, DEAD = 0x10, HAS_GOOD_MORALE = 0x20, RETALIATED = 0x40, MAYBE_NOT_LOST_TURN = 0x80, MIRROR_IMAGE = 0x100, CREATURE_RED = 0x200, UNDEAD = 0x400, CREATURE_BROWN = 0x2000, CREATURE_PETRIFIED = 0x4000, }; /* 3 */ enum MACRO_ERROR_CLIENT { ERROR_CLIENT_ALREADY_EXISTS = 183, ERROR_NO_MESSAGES = 259, }; /* 4 */ enum MACRO_NULL { NULL = 0, }; /* 5 */ enum MACRO_SEEK { SEEK_SET = 0, SEEK_CUR = 1, SEEK_END = 2, MAX_FILENAME_LENGTH = 13, MMIO_DEFAULTBUFFER = 8192, }; /* 6 */ enum MACRO_O { O_RDONLY = 0, O_WRONLY = 1, O_RDWR = 2, O_APPEND = 8, O_CREAT = 256, O_TRUNC = 512, O_EXCL = 1024, O_TEXT = 16384, O_BINARY = 32768, }; /* 7 */ enum MACRO_DRIVERVERSION { DRIVERVERSION = 0, TECHNOLOGY = 2, HORZSIZE = 4, VERTSIZE = 6, HORZRES = 8, VERTRES = 10, BITSPIXEL = 12, PLANES = 14, NUMBRUSHES = 16, NUMPENS = 18, NUMMARKERS = 20, NUMFONTS = 22, NUMCOLORS = 24, PDEVICESIZE = 26, CURVECAPS = 28, LINECAPS = 30, POLYGONALCAPS = 32, TEXTCAPS = 34, CLIPCAPS = 36, RASTERCAPS = 38, ASPECTX = 40, ASPECTY = 42, ASPECTXY = 44, LOGPIXELSX = 88, LOGPIXELSY = 90, SIZEPALETTE = 104, NUMRESERVED = 106, COLORRES = 108, PHYSICALWIDTH = 110, PHYSICALHEIGHT = 111, PHYSICALOFFSETX = 112, PHYSICALOFFSETY = 113, SCALINGFACTORX = 114, SCALINGFACTORY = 115, VREFRESH = 116, DESKTOPVERTRES = 117, DESKTOPHORZRES = 118, BLTALIGNMENT = 119, SHADEBLENDCAPS = 120, COLORMGMTCAPS = 121, }; /* 8 */ enum MSG_WINDOW_OPTIONS { WITH_OKAY_BUTTON = 1, WITH_YES_NO_BUTTONS = 2, WITH_CANCEL_BUTTON = 3, TRANSIENT_FOR_RIGHT_CLICKS = 4, }; /* 9 */ #pragma pack(push, 1) union in_addrC13EC994467D6E67044F092615EC7EA9 { u_long S_un_b; in_addrC13EC994467D6E67044F092615EC7EA94DE764E669F663DACA3CBFDE73714CB5 S_un_w; int S_addr; }; #pragma pack(pop) /* 10 */ #pragma pack(push, 1) struct in_addrC13EC994467D6E67044F092615EC7EA901C175C1F0716DCA00314EDD79DBC0A0 { u_char s_b1; u_char s_b2; u_char s_b3; u_char s_b4; }; #pragma pack(pop) /* 11 */ #pragma pack(push, 1) struct in_addrC13EC994467D6E67044F092615EC7EA94DE764E669F663DACA3CBFDE73714CB5 { u_short s_w1; u_short s_w2; }; #pragma pack(pop) /* 12 */ #pragma pack(push, 1) struct widget { widgetVtable *vtable; heroWindow *parentWindow; widget *nextInLinkedList; widget *prevInLinkedList; __int16 fieldID; __int16 componentIndex; __int16 field_14; __int16 flags; __int16 offsetX; __int16 offsetY; __int16 width; __int16 height; }; #pragma pack(pop) /* 13 */ #pragma pack(push, 1) struct button { widgetVtable *vtable; heroWindow *parentWindow; int nextInLinkedList; int prevInLinkedList; __int16 fieldID; __int16 field_12; __int16 field_14; BUTTON_FLAGS flags; __int16 offsetY; __int16 width; __int16 height; icon *icon; __int16 normalImageIdx; __int16 armedImageIdx; __int16 field_28; __int16 field_2A; int icnFileID; }; #pragma pack(pop) /* 14 */ #pragma pack(push, 1) struct textWidget { widgetVtable *vtable; heroWindow *parentWindow; int nextInLinkedList; int prevInLinkedList; __int16 fieldID; __int16 field_12; __int16 field_14; __int16 field_16; __int16 offsetX; __int16 offsetY; __int16 width; __int16 height; char *content; font *font; __int16 field_28; char field_2A; }; #pragma pack(pop) /* 15 */ #pragma pack(push, 1) struct textEntryWidget { int vtable; heroWindow *parentWindow; int nextInLinkedList; int prevInLinkedList; __int16 fieldID; __int16 field_12; __int16 field_14; __int16 field_16; __int16 offsetX; __int16 offsetY; __int16 width; __int16 height; void *ptrToFifthShortPlusFiveManyBytes; int font; __int16 field_28; char field_2A; int icon; __int16 field_2F; __int16 field_31; __int16 fifthShort; __int16 field_35; __int16 field_37; __int16 field_39; __int16 field_3B; __int16 field_3D; __int16 field_3F; __int16 field_41; __int16 field_43; __int16 field_45; __int16 field_47; __int16 type; __int16 field_4B; char _2; }; #pragma pack(pop) /* 16 */ #pragma pack(push, 1) struct heroWindow { int idx; heroWindow *nextWindow; heroWindow *prevWindow; char filename[20]; int flags1; int flags2; int xOffset; int yOffset; int width; int height; widget *lastWidget; widget *firstWidget; bitmap *bitmap; }; #pragma pack(pop) /* 17 */ #pragma pack(push, 1) struct resource { resourceVtable *vtable; RESOURCE_TYPE resourceType; __int16 referenceCount; unsigned int fileID; resource *next; }; #pragma pack(pop) /* 18 */ #pragma pack(push, 1) struct font { resourceVtable *vtable; __int16 resourceType; __int16 referenceCount; int fileID; int next; int lineHeight; int whetherFirstShortIsMoreThan13; int field_18; icon *icon; }; #pragma pack(pop) /* 19 */ #pragma pack(push, 1) struct palette { resourceVtable *vtable; __int16 resourceType; __int16 referenceCount; int fileID; int next; signed __int8 *contents; }; #pragma pack(pop) /* 20 */ #pragma pack(push, 1) struct icon { resourceVtable *vtable; RESOURCE_TYPE resourceType; __int16 referenceCount; int fileID; resource *next; __int16 numSprites; IconEntry *headersAndImageData; }; #pragma pack(pop) /* 21 */ #pragma pack(push, 1) struct AggregateHeader { int id; int off; int length; }; #pragma pack(pop) /* 22 */ #pragma pack(push, 1) struct MemoryBlockInfo { char initialized; int contents; int len; char src_file_of_loading[61]; int lineno_of_loading; }; #pragma pack(pop) /* 23 */ #pragma pack(push, 1) struct managerVtable { int (__thiscall *Open)(baseManager *, int); void (__thiscall *Close)(baseManager *); int (__fastcall *Main)(baseManager *, tag_message *); }; #pragma pack(pop) /* 24 */ #pragma pack(push, 1) struct resourceManager { managerVtable *vtable; baseManager *next; baseManager *prev; MANAGER_TYPE type; int idx; char name[30]; int ready; resource *firstLoadedResource; int numOpenAGGFiles; int curHandleIdx; int fileDescriptors[2]; AggregateHeader *aggContentInfo[2]; int numberOfFilesInAGG[2]; int expunging; int field_5E; char resourceToLoad[60]; int fileID; }; #pragma pack(pop) /* 25 */ #pragma pack(push, 1) struct soundManager { managerVtable *vtable; baseManager *next; baseManager *prev; int type; int idx; char name[30]; int ready; int redbookStatus; HDIGDRIVER hdidriver; int field_3E; char _0[22]; HSAMPLE hsamples[14]; int field_90; int field_94; int numSamplesAllocated; char _1[84]; char _2[1152]; int field_570; int _3; int field_578; char currentTrack; char _4[267]; int aiMusicOff; int volRelated; int _5; int field_694; int field_698; __int16 outputDeviceID; int field_69E; int usingRedbookRelated; int field_6A6; float field_6AA; int someTick; }; #pragma pack(pop) /* 26 */ #pragma pack(push, 1) struct game { __int16 gameDifficulty; char relatedToCurViewSideOrCampaign; char field_3; char relatedToCampaignMap; char _1[120]; char field_7D; char hasDwarfAlliance; char maybeIsGoodCampaign; char field_80; char field_81; char field_82; char field_83; char field_84; char field_85; char isDwarfbane; char hasDragonAlliance; char field_88; char _11[193]; char lastSaveFile[251]; char _12[100]; SMapHeader mapHeader; char relatedToPlayerPosAndColor[6]; char playerHandicap[6]; char relatedToColorOfPlayerOrFaction[6]; char somePlayerCodeOr10IfMayBeHuman[6]; char difficulty; char mapFilename[40]; char numPlayers; char couldBeNumDefeatedPlayers; char playerDead[6]; __int16 day; __int16 week; __int16 month; playerData players[6]; fullMap map; char numObelisks; town castles[72]; char field_2773[72]; char field_27BB[9]; hero heroes[54]; char relatedToHeroForHireStatus[54]; mine mines[144]; char field_60A6[144]; char artifactGeneratedRandomly[103]; boat boats[48]; char boatBuilt[48]; char obeliskVisitedMasks[48]; char field_637D[24]; char ultimateArtifactLocX; char ultimateArtifactLocY; char ultimateArtifactIdx; int field_6398; char _B[14]; char currentRumor[301]; __int16 numRumors; __int16 rumorIndices[30]; __int16 numEvents; char eventIndices[60]; char _C[40]; __int16 numMapEvents; __int16 mapEventIndices[70]; int (__thiscall *callback)(tag_message *); char field_660D; char field_660E; }; #pragma pack(pop) /* 27 */ #pragma pack(push, 1) struct fullMap { mapCell *tiles; mapCellExtra *cellExtras; int width; int height; int numCellExtras; }; #pragma pack(pop) /* 29 */ #pragma pack(push, 1) struct hero { __int16 spellpoints; char idx; char ownerIdx; char field_4; char field_5; char field_6; char field_7; char field_8; char field_9; char name[13]; char factionID; char heroID; int x; int y; __int16 field_21; __int16 field_23; __int16 field_25; __int16 field_27; __int8 relatedToX; __int8 relatedToY; __int8 relatedToFactionID; __int8 directionFacing; __int16 occupiedObjType; __int16 occupiedObjVal; int mobility; int remainingMobility; int experience; __int16 oldLevel; char primarySkills[4]; char field_43; char tempMoraleBonuses; char tempLuckBonuses; char field_46; int gazeboesVisited; int fortsVisited; int witchDoctorHutsVisited; int mercenaryCampsVisited; int standingStonesVisited; int treesOfKnowledgeVisited; int xanadusVisited; char randomSeed; char wisdomLastOffered; armyGroup army; char secondarySkillLevel[14]; char skillIndex[14]; int numSecSkillsKnown; char spellsLearned[65]; char artifacts[14]; int flags; char isCaptain; int field_E8; char scrollSpell[14]; }; #pragma pack(pop) /* 30 */ #pragma pack(push, 1) struct armyGroup { char creatureTypes[5]; __int16 quantities[5]; }; #pragma pack(pop) /* 31 */ #pragma pack(push, 1) struct army { char mightBeIsAttacking; char animatingRangedAttack; char mightBeAttackAnimIdx; char field_3; char field_4; char field_5; int field_6; H2RECT stackSizeDispBounds; H2RECT field_1A; H2RECT bounds; H2RECT effectAnimationBounds; int curFidget; float field_4E; int targetOwner; int targetStackIdx; int targetNeighborIdx; int field_5E; int targetHex; int probablyIsNeedDrawSpellEffect; int mirroredIdx; int mirrorIdx; int lifespan; int creatureIdx; int occupiedHex; int animationType; int animationFrame; int facingRight; int field_8A; int field_8E; int initialQuantity; int quantity; unsigned int previousQuantity; int temporaryQty; int damage; int armyIdx; int otherBadLuckThing; int speed; int field_B2; int luckStatus; tag_monsterInfo creature; __int16 field_D4; int damageTakenDuringSomeTimePeriod; int hasTakenLosses; int dead; int spellEnemyCreatureAbilityIsCasting; int owningSide; int stackIdx; int baseFidgetTime; int morale; int luck; int field_FA; int yDrawOffset; int xDrawOffset; int numActiveEffects; char effectStrengths[19]; int field_11D; int hitByHydraAttack; void *field_125; SMonFrameInfo frameInfo; icon *creatureIcon; icon *missileIcon; sample *combatSounds[7]; }; #pragma pack(pop) /* 32 */ #pragma pack(push, 1) struct combatManager { managerVtable *vtable; baseManager *next; baseManager *prev; int type; int idx; char name[30]; int ready; palette *palette; char _1[768]; char combatMessageRow1[120]; char combatMessageRow2[120]; char field_42A[117]; char field_49F[117]; hexcell combatGrid[117]; int terrainType; int combatFieldFringeID; int field_31E6; int field_31EA; int field_31EE; int combatFieldCoverID; icon *combatScreenIcons[15]; icon *combatObjIcons[8]; int numCombatObjs; __int16 eagleEyeSpellLearned[2]; int drawBridgePosition; int hasMoat; char turretStatus[4]; char wallStatus[4]; char ballistaDestroyed; bitmap *couldBeBitmapForFieldItself; bitmap *probablyBitmapForCombatScreen; bitmap *bitmap1; int zeroedAfterAnimatingDeathAndHolySpells; int field_327B; town *castles[2]; hero *heroes[2]; hero captain; int heroSpellpowers[2]; armyGroup *armies[2]; int shadedHex; char shouldDoHeroFidget1[2]; char shouldDoHeroFidget2[2]; char field_33A1[2]; char field_33A3[2]; int heroAnimationType[2]; int heroAnimationFrameCount[2]; int heroType[2]; int lastHeroAnimationCompleteTime[2]; icon *heroIcon[2]; icon *heroFlagIcon[2]; int heroFlagIconIdx[2]; H2RECT heroBounds[2]; H2RECT heroFlagBounds[2]; H2RECT moatPartBounds[9]; int otherCombatMessageRelatedTime; int combatMessageRelatedTime; int couldBeShouldResetCombatMessage; char _7[100]; char summonedCreatureType[2]; int field_351F[2]; int involvedInBadMorale[2]; int playerID[2]; int experienceForDefeating[2]; int field_353F; int field_3543; int numCreatures[2]; army creatures[2][21]; int activeStackOwner; int activeStack; int field_F2AB; int currentActionSide; int field_F2B3; int field_F2B7; int field_F2BB; int field_F2BF; int field_F2C3; int field_F2C7; int field_F2CB; int field_F2CF; H2RECT catapultBounds; H2RECT ballistaBounds; H2RECT drawbridgeBounds; H2RECT field_F303; int probablyCatapultImgIdx[2]; char _11[8]; int timesCatapultMustFire[2]; int timesGarrisonMustFire[2]; int isCastleBattle; char _12[20]; int zeroedInHandleCatapult1; int zeroedInHandleCatapult2; float field_F353; int field_F357; int field_F35B; float ghostAndVampireAbilityStrength[2]; heroWindow *window; int field_F36B; int field_F36F; int field_F373; int field_F377[2]; signed int limitCreature[2][20]; int field_F41F[2]; int field_F427[2]; int field_F42F; int casualtyRelatedTextWidgets[50]; int field_F4FB; int field_F4FF; char field_F503[24]; int field_F51B; int field_F51F; H2RECT field_F523; char _15[16]; int field_F543; int field_F547; int field_F54B[2]; int field_F553; int field_F557; char _16[28]; char shouldVanish[2][20]; char anyStacksShouldVanish; char combatBackgroundFilename[13]; char hexNeighbors[117][6]; heroWindow *combatEndWindow; int current_spell_id; int winningSide; }; #pragma pack(pop) /* 33 */ #pragma pack(push, 1) struct hexcell { __int16 centerX; __int16 occupyingCreatureBottomY; __int16 leftX; __int16 topY; __int16 rightX; __int16 otherY1; __int16 otherY2; char isBlocked; char combatObjIdx; char unitOwner; signed __int8 stackIdx; char occupiersOtherHexIsToLeft; int numCorpses; char corpseOwners[14]; char corpseStackIndices[14]; char corpseOtherHexIsToLeft[14]; char field_41; H2RECT drawingBounds; char field_52[16]; }; #pragma pack(pop) /* 34 */ #pragma pack(push, 1) struct baseManager { managerVtable *vtable; baseManager *next; baseManager *prev; int type; int idx; char name[30]; int ready; }; #pragma pack(pop) /* 35 */ #pragma pack(push, 1) struct secondary_skill_chances { char skill_chances[6]; }; #pragma pack(pop) /* 36 */ #pragma pack(push, 1) struct primary_skill_all_chances { primary_skill_chances chancesForBeforeOrAfterLvl10[2]; }; #pragma pack(pop) /* 37 */ #pragma pack(push, 1) struct primary_skills { char attack; char defense; char spellpower; char knowledge; char _; }; #pragma pack(pop) /* 38 */ #pragma pack(push, 1) struct building_cost { int wood; int mercury; int ore; int sulfur; int crystal; int gems; int gold; }; #pragma pack(pop) /* 39 */ #pragma pack(push, 1) struct tag_monsterInfo { __int16 cost; int fight_value; char fight_value_aux; char growth; __int16 hp; char faction; char speed; char attack; char defense; char min_damage; char max_damage; char shots; char short_name[5]; __int16 creature_flags; __int16 _; }; #pragma pack(pop) /* 40 */ enum COMBAT_CONSTANTS { HEX_GRID_SIZE = 0x75, }; /* 41 */ enum Spell { SPELL_FIREBALL = 0, SPELL_FIREBLAST = 1, SPELL_LIGHTNING_BOLT = 2, SPELL_CHAIN_LIGHTNING = 3, SPELL_TELEPORT = 4, SPELL_CURE = 5, SPELL_MASS_CURE = 6, SPELL_RESURRECT = 7, SPELL_RESURRECT_TRUE = 8, SPELL_HASTE = 9, SPELL_MASS_HASTE = 10, SPELL_SLOW = 11, SPELL_MASS_SLOW = 12, SPELL_BLIND = 13, SPELL_BLESS = 14, SPELL_MASS_BLESS = 15, SPELL_STONESKIN = 16, SPELL_STEELSKIN = 17, SPELL_CURSE = 18, SPELL_MASS_CURSE = 19, SPELL_HOLY_WORD = 20, SPELL_HOLY_SHOUT = 21, SPELL_ANTI_MAGIC = 22, SPELL_DISPEL_MAGIC = 23, SPELL_MASS_DISPEL = 24, SPELL_MAGIC_ARROW = 25, SPELL_BERZERKER = 26, SPELL_ARMAGEDDON = 27, SPELL_ELEMENTAL_STORM = 28, SPELL_METEOR_SHOWER = 29, SPELL_PARALYZE = 30, SPELL_HYPNOTIZE = 31, SPELL_COLD_RAY = 32, SPELL_COLD_RING = 33, SPELL_DISRUPTING_RAY = 34, SPELL_DEATH_RIPPLE = 35, SPELL_DEATH_WAVE = 36, SPELL_DRAGON_SLAYER = 37, SPELL_BLOOD_LUST = 38, SPELL_ANIMATE_DEAD = 39, SPELL_MIRROR_IMAGE = 40, SPELL_SHIELD = 41, SPELL_MASS_SHIELD = 42, SPELL_SUMMON_EARTH_ELEMENTAL = 43, SPELL_SUMMON_AIR_ELEMENTAL = 44, SPELL_SUMMON_FIRE_ELEMENTAL = 45, SPELL_SUMMON_WATER_ELEMENTAL = 46, SPELL_EARTHQUAKE = 47, SPELL_VIEW_MINES = 48, SPELL_VIEW_RESOURCES = 49, SPELL_VIEW_ARTIFACTS = 50, SPELL_VIEW_TOWNS = 51, SPELL_VIEW_HEROES = 52, SPELL_VIEW_ALL = 53, SPELL_IDENTIFY = 54, SPELL_SUMMON_BOAT = 55, SPELL_DIMENSION_DOOR = 56, SPELL_TOWN_GATE = 57, SPELL_TOWN_PORTAL = 58, SPELL_VISIONS = 59, SPELL_HAUNT = 60, SPELL_SET_EARTH_GUARDIAN = 61, SPELL_SET_AIR_GUARDIAN = 62, SPELL_SET_FIRE_GUARDIAN = 63, SPELL_SET_WATER_GUARDIAN = 64, SPELL_MEDUSA_PETRIFY = 101, SPELL_ARCHMAGI_DISPEL = 102, SPELL_NONE = 4294967295, }; /* 42 */ #pragma pack(push, 1) struct border { widgetVtable *vtable; heroWindow *parentWindow; widget *nextInLinkedList; int prevInLinkedList; __int16 fieldID; __int16 field_12; __int16 backgroundType; __int16 flagsRelatedToShouldDisplayAndPerhapsMouseCode; __int16 offsetX; __int16 offsetY; __int16 width; __int16 height; bitmap *bitmap; icon *icon; __int16 color; }; #pragma pack(pop) /* 43 */ enum CREATURE_ATTRIBUTES : __int8 { ATTR_MIRROR_IMAGE = 0x1, ATTR_BLOODLUST_RED = 0x2, ATTR_UNDEAD = 0x4, ATTR_BROWN = 0x20, ATTR_PETRIFY_GRAY = 0x40, }; /* 44 */ enum CREATURES { CREATURE_PEASANT = 0, CREATURE_ARCHER = 1, CREATURE_RANGER = 2, CREATURE_PIKEMAN = 3, CREATURE_VETERAN_PIKEMAN = 4, CREATURE_SWORDSMAN = 5, CREATURE_MASTER_SWORDSMAN = 6, CREATURE_CAVALRY = 7, CREATURE_CHAMPION = 8, CREATURE_PALADIN = 9, CREATURE_CRUSADER = 10, CREATURE_GOBLIN = 11, CREATURE_ORC = 12, CREATURE_ORC_CHIEF = 13, CREATURE_WOLF = 14, CREATURE_OGRE = 15, CREATURE_OGRE_LORD = 16, CREATURE_TROLL = 17, CREATURE_WAR_TROLL = 18, CREATURE_CYCLOPS = 19, CREATURE_SPRITE = 20, CREATURE_DWARF = 21, CREATURE_BATTLE_DWARF = 22, CREATURE_ELF = 23, CREATURE_GRAND_ELF = 24, CREATURE_DRUID = 25, CREATURE_GREATER_DRUID = 26, CREATURE_UNICORN = 27, CREATURE_PHOENIX = 28, CREATURE_CENTAUR = 29, CREATURE_GARGOYLE = 30, CREATURE_GRIFFIN = 31, CREATURE_MINOTAUR = 32, CREATURE_MINOTAUR_KING = 33, CREATURE_HYDRA = 34, CREATURE_GREEN_DRAGON = 35, CREATURE_RED_DRAGON = 36, CREATURE_BLACK_DRAGON = 37, CREATURE_HALFLING = 38, CREATURE_BOAR = 39, CREATURE_IRON_GOLEM = 40, CREATURE_STEEL_GOLEM = 41, CREATURE_ROC = 42, CREATURE_MAGE = 43, CREATURE_ARCHMAGE = 44, CREATURE_GIANT = 45, CREATURE_TITAN = 46, CREATURE_SKELETON = 47, CREATURE_ZOMBIE = 48, CREATURE_MUTANT_ZOMBIE = 49, CREATURE_MUMMY = 50, CREATURE_ROYAL_MUMMY = 51, CREATURE_VAMPIRE = 52, CREATURE_VAMPIRE_LORD = 53, CREATURE_LICH = 54, CREATURE_POWER_LICH = 55, CREATURE_BONE_DRAGON = 56, CREATURE_ROGUE = 57, CREATURE_NOMAD = 58, CREATURE_GHOST = 59, CREATURE_GENIE = 60, CREATURE_MEDUSA = 61, CREATURE_EARTH_ELEMENTAL = 62, CREATURE_AIR_ELEMENTAL = 63, CREATURE_FIRE_ELEMENTAL = 64, CREATURE_WATER_ELEMENTAL = 65, }; /* 45 */ enum STACK_MODIFYING_EFFECT { EFFECT_HASTE = 0, EFFECT_SLOW = 1, EFFECT_BLIND = 2, EFFECT_BLESS = 3, EFFECT_CURSE = 4, EFFECT_BERSERKER = 5, EFFECT_PARALYZE = 6, EFFECT_HYPNOTIZE = 7, EFFECT_DRAGON_SLAYER = 8, EFFECT_BLOOD_LUST = 9, EFFECT_SHIELD = 10, EFFECT_PETRIFY = 11, EFFECT_ANTI_MAGIC = 12, EFFECT_STONESKIN = 13, EFFECT_STEELSKIN = 14, }; /* 46 */ enum ARTIFACT { ARTIFACT_ULTIMATE_BOOK_OF_KNOWLEDGE = 0, ARTIFACT_ULTIMATE_SWORD_OF_DOMINION = 1, ARTIFACT_ULTIMATE_CLOAK_OF_PROTECTION = 2, ARTIFACT_ULTIMATE_WAND_OF_MAGIC = 3, ARTIFACT_ULTIMATE_SHIELD = 4, ARTIFACT_ULTIMATE_STAFF = 5, ARTIFACT_ULTIMATE_CROWN = 6, ARTIFACT_GOLDEN_GOOSE = 7, ARTIFACT_ARCANE_NECKLACE_OF_MAGIC = 8, ARTIFACT_CASTERS_BRACELET_OF_MAGIC = 9, ARTIFACT_MAGES_RING_OF_POWER = 10, ARTIFACT_WITCHS_BROACH_OF_MAGIC = 11, ARTIFACT_MEDAL_OF_VALOR = 12, ARTIFACT_MEDAL_OF_COURAGE = 13, ARTIFACT_MEDAL_OF_HONOR = 14, ARTIFACT_MEDAL_OF_DISTINCTION = 15, ARTIFACT_FIZBIN_OF_MISFOURTUNE = 16, ARTIFACT_THUNDER_MACE_OF_DOMINION = 17, ARTIFACT_ARMORED_GAUNTLETS_OF_PROTECTION = 18, ARTIFACT_DEFENDER_HELM_OF_PROTECTION = 19, ARTIFACT_GIANT_FLAIL_OF_DOMINION = 20, ARTIFACT_BALLISTA_OF_QUICKNESS = 21, ARTIFACT_STEALTH_SHIELD_OF_PROTECTION = 22, ARTIFACT_DRAGON_SWORD_OF_DOMINION = 23, ARTIFACT_POWER_AXE_OF_DOMINION = 24, ARTIFACT_DIVINE_BREASTPLATE_OF_PROTECTION = 25, ARTIFACT_MINOR_SCROLL_OF_KNOWLEDGE = 26, ARTIFACT_MAJOR_SCROLL_OF_KNOWLEDGE = 27, ARTIFACT_SUPERIOR_SCROLL_OF_KNOWLEDGE = 28, ARTIFACT_FOREMOST_SCROLL_OF_KNOWLEDGE = 29, ARTIFACT_ENDLESS_SACK_OF_GOLD = 30, ARTIFACT_ENDLESS_BAG_OF_GOLD = 31, ARTIFACT_ENDLESS_PURSE_OF_GOLD = 32, ARTIFACT_NOMAD_BOOTS_OF_MOBILITY = 33, ARTIFACT_TRAVELERS_BOOTS_OF_MOBILITY = 34, ARTIFACT_LUCKY_RABBITS_FOOT = 35, ARTIFACT_GOLDEN_HORSESHOE = 36, ARTIFACT_GAMBLERS_LUCKY_COIN = 37, ARTIFACT_FOUR_LEAF_CLOVER = 38, ARTIFACT_TRUE_COMPASS_OF_MOBILITY = 39, ARTIFACT_SAILORS_ASTROLABE_OF_MOBILITY = 40, ARTIFACT_EVIL_EYE = 41, ARTIFACT_ENCHANTED_HOURGLASS = 42, ARTIFACT_GOLD_WATCH = 43, ARTIFACT_SKULLCAP = 44, ARTIFACT_ICE_CLOAK = 45, ARTIFACT_FIRE_CLOAK = 46, ARTIFACT_LIGHTNING_HELM = 47, ARTIFACT_EVERCOLD_ICICLE = 48, ARTIFACT_EVERHOT_LAVA_ROCK = 49, ARTIFACT_LIGHTNING_ROD = 50, ARTIFACT_SNAKE_RING = 51, ARTIFACT_ANKH = 52, ARTIFACT_BOOK_OF_ELEMENTS = 53, ARTIFACT_ELEMENTAL_RING = 54, ARTIFACT_HOLY_PENDANT = 55, ARTIFACT_PENDANT_OF_FREE_WILL = 56, ARTIFACT_PENDANT_OF_LIFE = 57, ARTIFACT_SERENITY_PENDANT = 58, ARTIFACT_SEEING_EYE_PENDANT = 59, ARTIFACT_KINETIC_PENDANT = 60, ARTIFACT_PENDANT_OF_DEATH = 61, ARTIFACT_WAND_OF_NEGATION = 62, ARTIFACT_GOLDEN_BOW = 63, ARTIFACT_TELESCOPE = 64, ARTIFACT_STATESMANS_QUILL = 65, ARTIFACT_WIZARDS_HAT = 66, ARTIFACT_POWER_RING = 67, ARTIFACT_AMMO_CART = 68, ARTIFACT_TAX_LIEN = 69, ARTIFACT_HIDEOUS_MASK = 70, ARTIFACT_ENDLESS_POUCH_OF_SULFUR = 71, ARTIFACT_ENDLESS_VIAL_OF_MERCURY = 72, ARTIFACT_ENDLESS_POUCH_OF_GEMS = 73, ARTIFACT_ENDLESS_CORD_OF_WOOD = 74, ARTIFACT_ENDLESS_CART_OF_ORE = 75, ARTIFACT_ENDLESS_POUCH_OF_CRYSTAL = 76, ARTIFACT_SPIKED_HELM = 77, ARTIFACT_SPIKED_SHIELD = 78, ARTIFACT_WHITE_PEARL = 79, ARTIFACT_BLACK_PEARL = 80, ARTIFACT_MAGIC_BOOK = 81, ARTIFACT_NONE1 = 82, ARTIFACT_NONE2 = 83, ARTIFACT_NONE3 = 84, ARTIFACT_NONE4 = 85, ARTIFACT_SPELL_SCROLL = 86, ARTIFACT_ARM_OF_THE_MARTYR = 87, ARTIFACT_BREASTPLATE_OF_ANDURAN = 88, ARTIFACT_BROACH_OF_SHIELDING = 89, ARTIFACT_BATTLE_GARB_OF_ANDURAN = 90, ARTIFACT_CRYSTAL_BALL = 91, ARTIFACT_HEART_OF_FIRE = 92, ARTIFACT_HEART_OF_ICE = 93, ARTIFACT_HELMET_OF_ANDURAN = 94, ARTIFACT_HOLY_HAMMER = 95, ARTIFACT_LEGENDARY_SCEPTER = 96, ARTIFACT_MASTHEAD = 97, ARTIFACT_SPHERE_OF_NEGATION = 98, ARTIFACT_STAFF_OF_WIZARDRY = 99, ARTIFACT_SWORD_BREAKER = 100, ARTIFACT_SWORD_OF_ANDURAN = 101, ARTIFACT_SPADE_OF_NECROMANCY = 102, }; /* 47 */ enum HERO_CONSTANTS { MAX_ARTIFACTS = 14, MAX_TOTAL_HEROES = 48, }; /* 48 */ #pragma pack(push, 1) struct listBox { int vtable; heroWindow *parentWindow; int nextInLinkedList; int prevInLinkedList; __int16 fieldID; __int16 componentIdx; __int16 field_14; __int16 field_16; __int16 offsetX; __int16 offsetY; __int16 width; __int16 height; int fontID; icon *icon; __int16 field_28; __int16 field_2A; __int16 field_2C; __int16 field_2E; __int16 field_30; __int16 field_32; __int16 field_34; __int16 field_36; __int16 field_38; __int16 field_3A; __int16 field_3C; __int16 field_3E; __int16 field_40; __int16 field_42; __int16 field_44[23]; __int16 field_72[15]; }; #pragma pack(pop) /* 49 */ enum CREATE_STACK_CONSTANTS { NUM_EFFECTS = 0xF, }; /* 50 */ #pragma pack(push, 1) struct SSpellInfo { char soundName[9]; char level; char spriteIdx; char creatureEffectAnimationIdx; __int16 appearingChance; char cost; char nonMagicFactionAppearanceChance[6]; unsigned __int8 attributes; }; #pragma pack(pop) /* 51 */ enum SPELL_ATTRIBUTES { ATTR_COMMON_SPELL = 0x1, ATTR_COMBAT_SPELL = 0x2, ATTR_ADVENTURE_SPELL = 0x4, ATTR_DURATIONED_SPELL = 0x8, }; /* 52 */ #pragma pack(push, 1) struct type_info { void *vftable; int _m_data; char _m_d_name[]; }; #pragma pack(pop) /* 53 */ #pragma pack(push, 1) struct PMD { int mdisp; int pdisp; int vdisp; }; #pragma pack(pop) /* 58 */ #pragma pack(push, 1) struct inputManager { managerVtable *vtable; baseManager *next; baseManager *prev; int type; int idx; char name[30]; int ready; tag_message inputInstances[64]; int currentInputEvt; int currentInfoField; int readingInputMutex; int field_742; int field_746; int field_74A; __int16 keycodeRelated[128]; int field_84E; int field_852; int normalizingKeycodeRelated; int field_85A; int forSettingBitmask; int field_862; int field_866; }; #pragma pack(pop) /* 59 */ #pragma pack(push, 1) struct widgetVtable { void (__thiscall *paint)(widget *); void (__thiscall *cleanUp)(widget *, int); int (__thiscall *handleEvent)(widget *, tag_message *x); }; #pragma pack(pop) /* 60 */ #pragma pack(push, 1) struct mouseManager { float vtable; baseManager *next; baseManager *prev; int type; int idx; char name[30]; int ready; bitmap *bitmap; int spriteIdx; icon *cursorIcon; MOUSE_CURSOR_CATEGORY cursorCategory; int cursorIdx; int field_4A; int field_4E; int field_52; int field_56; int field_5A; int cursorTopLeftX; int cursorTopLeftY; int field_66; int field_6A; int field_6E; int field_72; int cursorWidth; int cursorHeight; int field_7E; int couldBeShowMouse; int cursorDisabled; }; #pragma pack(pop) /* 61 */ #pragma pack(push, 1) struct tag_message { INPUT_EVENT_CODE eventCode; int xCoordOrKeycode; int yCoordOrFieldID; int inputTypeBitmask; int altXCoord; int altYCoord; void *payload; }; #pragma pack(pop) /* 62 */ enum INPUT_EVENT_CODE { INPUT_KEYDOWN_EVENT_CODE = 0x1, INPUT_KEYUP_EVENT_CODE = 0x2, INPUT_MOUSEMOVE_EVENT_CODE = 0x4, INPUT_LEFT_CLICK_EVENT_CODE = 0x8, INPUT_LEFT_UP_EVENT_CODE = 0x10, INPUT_RIGHT_CLICK = 0x20, INPUT_RIGHT_UP_EVENT_CODE = 0x40, INPUT_GUI_MESSAGE_CODE = 0x200, }; /* 64 */ #pragma pack(push, 1) struct heroWindowManager { managerVtable *vtable; baseManager *next; baseManager *prev; int type; int idx; char name[30]; int ready; heroWindow *firstWindow; heroWindow *lastWindow; heroWindow *topmostWindow; heroWindow *nextTopmostWindow; bitmap *screenBuffer; bitmap *fizzleSource; bitmap *field_4E; int numScreenshots; int cycleColors; int buttonPressedCode; int hoveredFieldID; }; #pragma pack(pop) /* 65 */ #pragma pack(push, 1) struct MainWindow { unsigned int showMenu; signed int x; signed int y; unsigned int width; unsigned int height; unsigned int fullScreen; unsigned int colorMouseCursor; }; #pragma pack(pop) /* 66 */ enum MENU_BUTTON { MENU_BUTTON_640X480 = 40005, MENU_BUTTON_800X600 = 40006, MENU_BUTTON_1024X768 = 40007, MENU_BUTTON_1280X1024 = 40008, MENU_BUTTON_FULLSCREEN = 40009, MENU_BUTTON_MANUAL = 40052, MENU_BUTTON_ABOUT = 40053, MENU_BUTTON_PEASANTS = 41000, MENU_BUTTON_ARCHERS = 41001, MENU_BUTTON_RANGES = 41002, MENU_BUTTON_PIKEMEN = 41003, MENU_BUTTON_VETERAN_PIKEMEN = 41004, MENU_BUTTON_SWORDSMEN = 41005, MENU_BUTTON_VETERAN_SWORDSMEN = 41006, MENU_BUTTON_CAVALRIES = 41007, MENU_BUTTON_CHAMPIONS = 41008, MENU_BUTTON_PALADINS = 41009, MENU_BUTTON_CRUSADERS = 41010, MENU_BUTTON_GOBLINS = 41011, MENU_BUTTON_ORCS = 41012, MENU_BUTTON_ORC_CHIEFS = 41013, MENU_BUTTON_WOLVES = 41014, MENU_BUTTON_OGRES = 41015, MENU_BUTTON_OGRE_LORDS = 41016, MENU_BUTTON_TROLLS = 41017, MENU_BUTTON_WAR_TROLLS = 41018, MENU_BUTTON_CYCLOPES = 41019, MENU_BUTTON_SPRITES = 41020, MENU_BUTTON_DWARVES = 41021, MENU_BUTTON_BATTLE_DWARVES = 41022, MENU_BUTTON_ELVES = 41023, MENU_BUTTON_GRAND_ELVES = 41024, MENU_BUTTON_DRUIDS = 41025, MENU_BUTTON_GREATER_DRUIDS = 41026, MENU_BUTTON_UNICORNS = 41027, MENU_BUTTON_PHOENIXES = 41028, MENU_BUTTON_CENTAURS = 41029, MENU_BUTTON_GARGOYLES = 41030, MENU_BUTTON_GRIFFINS = 41031, MENU_BUTTON_MINOTAURS = 41032, MENU_BUTTON_MINOTAUR_KINDS = 41033, MENU_BUTTON_HYDRAS = 41034, MENU_BUTTON_GREEN_DRAGONS = 41035, MENU_BUTTON_RED_DRAGONS = 41036, MENU_BUTTON_BLACK_DRAGONS = 41037, MENU_BUTTON_HALFLINGS = 41038, MENU_BUTTON_BOARDS = 41039, MENU_BUTTON_IRON_GOLEMS = 41040, MENU_BUTTON_STEEL_GOLEMS = 41041, MENU_BUTTON_ROCS = 41042, MENU_BUTTON_MAGI = 41043, MENU_BUTTON_ARCHMAGI = 41044, MENU_BUTTON_GIANTS = 41045, MENU_BUTTON_TITANS = 41046, MENU_BUTTON_SKELETONS = 41047, MENU_BUTTON_ZOMBIES = 41048, MENU_BUTTON_MUTANT_ZOMBIES = 41049, MENU_BUTTON_MUMMIES = 41050, MENU_BUTTON_ROYAL_MUMMIES = 41051, MENU_BUTTON_VAMPIRES = 41052, MENU_BUTTON_VAMPIRE_LORDS = 41053, MENU_BUTTON_LICHS = 41054, MENU_BUTTON_POWER_LICHES = 41055, MENU_BUTTON_BONE_DRAGONS = 41056, MENU_BUTTON_ROGUES = 41057, MENU_BUTTON_NOMADS = 41058, MENU_BUTTON_GHOSTS = 41059, MENU_BUTTON_GENIES = 41060, MENU_BUTTON_MEDUSAS = 41061, MENU_BUTTON_EARTH_ELEMENTALS = 41062, MENU_BUTTON_AIR_ELEMENTALS = 41063, MENU_BUTTON_FIRE_ELEMENTALS = 41064, MENU_BUTTON_WATER_ELEMENTALS = 41065, MENU_BUTTON_QUIT = 41140, MENU_BUTTON_VIEW_ENTIRE_MAP = 41141, MENU_BUTTON_EXTRA_HERO_MOBILITY = 41142, MENU_BUTTON_FREE_SPELLS = 41143, MENU_BUTTON_FREE_RESOURCES = 41144, MENU_BUTTON_NO_PATHFINDING = 42000, MENU_BUTTON_BASIC_PATHFINDING = 42001, MENU_BUTTON_ADVANCED_PATHFINDING = 42002, MENU_BUTTON_EXPERT_PATHFINDING = 42003, MENU_BUTTON_NO_ARCHERY = 42004, MENU_BUTTON_BASIC_ARCHERY = 42005, MENU_BUTTON_ADVANCED_ARCHERY = 42006, MENU_BUTTON_EXPERT_ARCHERY = 42007, MENU_BUTTON_NO_LOGISTICS = 42008, MENU_BUTTON_BASIC_LOGISTICS = 42009, MENU_BUTTON_ADVANCED_LOGISTICS = 42010, MENU_BUTTON_EXPERT_LOGISTICS = 42011, MENU_BUTTON_NO_SCOUTING = 42012, MENU_BUTTON_BASIC_SCOUTING = 42013, MENU_BUTTON_ADVANCED_SCOUTING = 42014, MENU_BUTTON_EXPERT_SCOUTING = 42015, MENU_BUTTON_NO_DIPLOMACY = 42016, MENU_BUTTON_BASIC_DIPLOMACY = 42017, MENU_BUTTON_ADVANCED_DIPLOMACY = 42018, MENU_BUTTON_EXPERT_DIPLOMACY = 42019, MENU_BUTTON_NO_NAVIGATION = 42020, MENU_BUTTON_BASIC_NAVIGATION = 42021, MENU_BUTTON_ADVANCED_NAVIGATION = 42022, MENU_BUTTON_EXPERT_NAVIGATION = 42023, MENU_BUTTON_NO_LEADERSHIP = 42024, MENU_BUTTON_BASIC_LEADERSHIP = 42025, MENU_BUTTON_ADVANCED_LEADERSHIP = 42026, MENU_BUTTON_EXPERT_LEADERSHIP = 42027, MENU_BUTTON_NO_WISDOM = 42028, MENU_BUTTON_BASIC_WISDOM = 42029, MENU_BUTTON_ADVANCED_WISDOM = 42030, MENU_BUTTON_EXPERT_WISDOM = 42031, MENU_BUTTON_NO_MYSTICISM = 42032, MENU_BUTTON_BASIC_MYSTICISM = 42033, MENU_BUTTON_ADVANCED_MYSTICISM = 42034, MENU_BUTTON_EXPERT_MYSTICISM = 42035, MENU_BUTTON_NO_LUCK = 42036, MENU_BUTTON_BASIC_LUCK = 42037, MENU_BUTTON_ADVANCED_LUCK = 42038, MENU_BUTTON_EXPERT_LUCK = 42039, MENU_BUTTON_NO_BALLISTICS = 42040, MENU_BUTTON_BASIC_BALLISTICS = 42041, MENU_BUTTON_ADVANCED_BALLISTICS = 42042, MENU_BUTTON_EXPERT_BALLISTICS = 42043, MENU_BUTTON_NO_EAGLE_EYES = 42044, MENU_BUTTON_BASIC_EAGLE_EYES = 42045, MENU_BUTTON_ADVANCED_EAGLE_EYES = 42046, MENU_BUTTON_EXPERT_EAGLE_EYES = 42047, MENU_BUTTON_NO_NECROMANCY = 42048, MENU_BUTTON_BASIC_NECROMANCY = 42049, MENU_BUTTON_ADVANCED_NECROMANCY = 42050, MENU_BUTTON_EXPERT_NECROMANCY = 42051, MENU_BUTTON_NO_ESTATES = 42052, MENU_BUTTON_BASIC_ESTATES = 42053, MENU_BUTTON_ADVANCED_ESTATES = 42054, MENU_BUTTON_EXPERT_ESTATES = 42055, MENU_BUTTON_BUILD_MAGE_GUILD = 43000, MENU_BUTTON_BUILD_THIEVES_GUILD = 43001, MENU_BUTTON_BUILD_TAVERN = 43002, MENU_BUTTON_BUILD_DOCK = 43003, MENU_BUTTON_BUILD_WELL = 43004, MENU_BUTTON_BUILD_TENT = 43005, MENU_BUTTON_BUILD_CASTLE = 43006, MENU_BUTTON_BUILD_STATUE = 43007, MENU_BUTTON_BUILD_LEFT_TURRET = 43008, MENU_BUTTON_BUILD_RIGHT_TURRET = 43009, MENU_BUTTON_BUILD_MARKET = 43010, MENU_BUTTON_BUILD_1ST_LEVEL_GROWER = 43011, MENU_BUTTON_BUILD_MOAT = 43012, MENU_BUTTON_BUILD_TOWN_SPECIFIC_BUILDING = 43013, MENU_BUTTON_BUILD_CAPTAINS_QUARTERS = 43015, MENU_BUTTON_BUILD_DWELLING_1 = 43019, MENU_BUTTON_BUILD_DWELLING_2 = 43020, MENU_BUTTON_BUILD_DWELLING_3 = 43021, MENU_BUTTON_BUILD_DWELLING_4 = 43022, MENU_BUTTON_BUILD_DWELLING_5 = 43023, MENU_BUTTON_BUILD_DWELLING_6 = 43024, MENU_BUTTON_BUILD_DWELLING_2_UPGRADE = 43025, MENU_BUTTON_BUILD_DWELLING_3_UPGRADE = 43026, MENU_BUTTON_BUILD_DWELLING_4_UPDGRADE = 43027, MENU_BUTTON_BUILD_DWELLING_5_UPGRADE = 43028, MENU_BUTTON_BUILD_DWELLING_6_UPGRADE = 43029, MENU_BUTTON_BUILD_DWELLING_6_UPGRADE_2 = 43030, MENU_BUTTON_BUILD_ALL_BUILDINGS = 43100, }; /* 67 */ #pragma pack(push, 1) struct SAMPLE2 { sample *file; HSAMPLE sample; }; #pragma pack(pop) /* 68 */ #pragma pack(push, 1) struct IconEntry { __int16 offsetX; __int16 offsetY; __int16 width; __int16 height; char someSortOfLength; int off; }; #pragma pack(pop) /* 69 */ enum CREATURE_EFFECT_ANIMATION_INDEX : __int8 { ANIM_NONE_IDX = 0, ANIM_MAGIC01_IDX = 1, ANIM_MAGIC02_IDX = 2, ANIM_MAGIC03_IDX = 3, ANIM_MAGIC04_IDX = 4, ANIM_MAGIC05_IDX = 5, ANIM_MAGIC06_IDX = 6, ANIM_MAGIC07_IDX = 7, ANIM_MAGIC08_IDX = 8, ANIM_RAINBOW_LUCK_IDX = 9, ANIM_CLOUD_LUCK_IDX = 10, ANIM_MORALE_GOOD_IDX = 11, ANIM_MORALE_BAD_IDX = 12, ANIM_RED_DEATH_IDX = 13, ANIM_RED_FIRE_IDX = 14, ANIM_SPARKS_IDX = 15, ANIM_ELECTRIC_IDX = 16, ANIM_PHISICAL_IDX = 17, ANIM_BLUEFIRE_IDX = 18, ANIM_ICECLOUD_IDX = 19, ANIM_LICHCLOUD_IDX = 20, ANIM_BLESS_IDX = 21, ANIM_BERZERK_IDX = 22, ANIM_SHIELD_IDX = 23, ANIM_HASTE_IDX = 24, ANIM_PARALYZE_IDX = 25, ANIM_HYPNOTIZE_IDX = 26, ANIM_DRAGONSLAYER_IDX = 27, ANIM_BLIND_IDX = 28, ANIM_CURSE_IDX = 29, ANIM_STONESKIN_IDX = 30, ANIM_STEELSKIN_IDX = 31, }; /* 70 */ #pragma pack(push, 1) struct RGB { char red; char green; char blue; }; #pragma pack(pop) /* 71 */ enum SPECIAL_PALETTE_INDICES { SPECIAL_PALETTE_INDICES_1 = 214, SPECIAL_PALETTE_INDICES_2 = 246, }; /* 73 */ enum CREATURE_EVENT_CODE { CREATURE_MOVED_CODE = 0, CREATURE_TOOK_TURN_EVENT_CODE = 1, CREATURE_TOOK_DAMAGE_CODE = 2, }; /* 74 */ #pragma pack(push, 1) struct H2RECT { LONG left; LONG right; LONG top; LONG bottom; }; #pragma pack(pop) /* 75 */ #pragma pack(push, 1) struct sample { resourceVtable *vtable; __int16 resourceType; __int16 referenceCount; int fileID; resource *next; int field_10; void *contents; int nbytes; int codeThing; unsigned int playbackRate; unsigned int sampleType; unsigned int volume; int loopCount; }; #pragma pack(pop) /* 76 */ enum RESOURCE_TYPE : __int16 { RESOURCE_TYPE_BITMAP = 0x0, RESOURCE_TYPE_ICN = 0x1, RESOURCE_TYPE_PALETTE = 0x2, RESOURCE_TYPE_TILESET = 0x3, RESOURCE_TYPE_FONT = 0x5, RESOURCE_TYPE_SAMPLE = 0x6, }; /* 77 */ enum SECONDARY_SKILL { SECONDARY_SKILL_PATHFINDING = 0, SECONDARY_SKILL_ARCHERY = 1, SECONDARY_SKILL_LOGISTICS = 2, SECONDARY_SKILL_SCOUTING = 3, SECONDARY_SKILL_DIPLOMACY = 4, SECONDARY_SKILL_NAVIGATION = 5, SECONDARY_SKILL_LEADERSHIP = 6, SECONDARY_SKILL_WISDOM = 7, SECONDARY_SKILL_MYSTICISM = 8, SECONDARY_SKILL_LUCK = 9, SECONDARY_SKILL_BALLISTICS = 10, SECONDARY_SKILL_EAGLE_EYE = 11, SECONDARY_SKILL_NECROMANCY = 12, SECONDARY_SKILL_ESTATES = 13, }; /* 78 */ enum SPELL_CATEGORY { SPELL_CATEGORY_COMBAT = 0, SPELL_CATEGORY_ADVENTURE = 1, SPELL_CATEGORY_ALL = 2, }; /* 79 */ #pragma pack(push, 1) struct bitmap { resourceVtable *vtable; RESOURCE_TYPE resourceType; __int16 referenceCount; int fileID; int next; __int16 setInConstructor; __int16 width; __int16 height; signed __int8 *contents; }; #pragma pack(pop) /* 80 */ #pragma pack(push, 1) struct resourceVtable { int (__thiscall *scalarDeletingDestructor)(resource *this, char); }; #pragma pack(pop) /* 81 */ #pragma pack(push, 1) struct Dimension32 { int height; int width; }; #pragma pack(pop) /* 82 */ enum RESOURCE_CLEANUP_FLAGS { RESOURCE_CLEANUP_FLAGS_DELETE = 0x1, }; /* 83 */ enum BACKGROUND_TYPE : __int16 { BACKGROUND_IS_ICON = 0x1, BACKGROUND_IS_SOLID = 0x400, BACKGROUND_IS_FROM_FILE = 0x800, }; /* 84 */ enum BUTTON_FLAGS { BUTTON_IS_ARMED = 0x1, }; /* 85 */ #pragma pack(push, 1) struct CursorDimension { char width; char height; }; #pragma pack(pop) /* 86 */ enum MOUSE_CURSOR_CATEGORY { MOUSE_CURSOR_CATEGORY_ADVENTURE = 0x0, MOUSE_CURSOR_CATEGORY_COMBAT = 0x1, MOUSE_CURSOR_CATEGORY_SPELL = 0x2, }; /* 87 */ #pragma pack(push, 1) struct CursorHotspot { char x; char y; }; #pragma pack(pop) /* 88 */ enum MOUSE_CONSTANTS { NUMBER_OF_CURSORS = 0x60, }; /* 90 */ enum PRIMARY_SKILL { PRIMARY_SKILL_ATTACK = 0, PRIMARY_SKILL_DEFENSE = 1, PRIMARY_SKILL_SPELLPOWER = 2, PRIMARY_SKILL_KNOWLEDGE = 3, }; /* 91 */ #pragma pack(push, 1) struct Point16 { __int16 x; __int16 y; }; #pragma pack(pop) /* 93 */ #pragma pack(push, 1) struct SMonFrameInfo { char firstByteIgnored; __int16 offsetForBlind[2]; char startMoveAnimInfoIgnored[16]; char subStartMoveAnimInfoIgnored[16]; char mainMoveAnimInfoIgnored[16]; char subEndMoveAnimInfoIgnored[16]; char endMoveAnimInfoIgnored[16]; char fullMoveAnimInfoIgnored[16]; char moveAnimInfoIgnored[16]; char numberOfFidgets; float fidgetProbabilities[5]; int fidgetInfoIgnored[5]; int maxFidgetDelay; int stepTime; int shootingTime; int flightSpeed; __int16 projectileStartOffset[3][2]; char numMissileDirs; float projDirAngle[12]; int stackNumDispXShift[2]; char animationLengths[34]; char animationFrameToImgIdx[34][16]; }; #pragma pack(pop) /* 94 */ enum CREATURE_COMBAT_SOUNDS { CREATURE_COMBAT_MOVE_SOUND = 0x0, CREATURE_COMBAT_ATTACK_SOUND = 0x1, CREATURE_COMBAT_WINCE_SOUND = 0x2, CREATURE_COMBAT_SHOT_SOUND = 0x3, CREATURE_COMBAT_KILL_SOUND = 0x4, CREATURE_COMBAT_EXTRA_SOUND_1 = 0x5, CREATURE_COMBAT_EXTRA_SOUND_2 = 0x6, }; /* 96 */ #pragma pack(push, 1) struct primary_skill_chances { char attackChance; char defenseChance; char spellpowerChance; char knowledgeChance; }; #pragma pack(pop) /* 98 */ #pragma pack(push, 1) struct MIDIWrap { resourceVtable *vtable; __int16 resourceType; __int16 referenceCount; int fileID; resource *next; void *contents; }; #pragma pack(pop) /* 99 */ #pragma pack(push, 1) struct executive { baseManager *firstManager; baseManager *lastManager; baseManager *currentManager; _DWORD field_C; }; #pragma pack(pop) /* 100 */ #pragma pack(push, 1) struct recruitUnit { managerVtable *vtable; baseManager *next; baseManager *prev; int type; int idx; char name[30]; int ready; int field_36; int creatureType; int field_3E; int field_42; int field_46; int field_4A; int field_4E; int field_52; int field_56; armyGroup *army; int field_5E; int field_62; int field_66; int available; int field_6E; int field_72; int field_76; int field_7A; }; #pragma pack(pop) /* 101 */ #pragma pack(push, 1) struct inputManager { managerVtable *vtable; baseManager *next; baseManager *prev; int type; int idx; char name[30]; int ready; tag_message inputInstances[64]; int currentInputEvt; int currentInfoField; int readingInputMutex; int field_742; int field_746; int field_74A; __int16 keycodeRelated[128]; int field_84E; int field_852; int normalizingKeycodeRelated; int field_85A; int forSettingBitmask; int field_862; int field_866; }; #pragma pack(pop) /* 103 */ enum MANAGER_RETURN_CODE : __int32 { MANAGER_SUCCESS = 0, MANAGER_FINISHED = 2, MANAGER_FAILED = 3, }; /* 104 */ enum AI_SPELL_TYPES { AI_BATTLEFIELD_AFFECTING_SPELL = 0x0, AI_MASS_BUFF_SPELL = 0x1, AI_MASS_DEBUFF_SPELL = 0x2, AI_BALL_SPALL = 0x3, AI_TARGET_BUFF_SPELL = 0x4, AI_TARGET_DAMAGE_OR_DEBUFF_SPELL = 0x5, AI_RESURRECT_SPELL = 0x6, AI_DISPEL_SPELL = 0x7, }; /* 105 */ enum GUI_MESSAGE_CODE { GUI_MESSAGE_REPAINT = 0x2, GUI_MESSAGE_SET_TEXT = 0x3, GUI_MESSAGE_SET_IMG_IDX = 0x4, GUI_MESSAGE_REMOVE_FLAGS = 0x6, GUI_MESSAGE_SET_ICON = 0x9, GUI_MESSAGE_BUTTON_PRESSED = 0xD, GUI_MESSAGE_SET_OFFSETX = 0x34, GUI_MESSAGE_SET_OFFSETY = 0x35, GUI_MESSAGE_DROPLIST_ADD = 0x38, GUI_MESSAGE_REPLACE_ICON = 0x3C, GUI_MESSAGE_SET_WIDTH = 0x3D, }; /* 106 */ #pragma pack(push, 1) struct searchArray { int field_0; int field_4; int field_8; char _1[8]; PathfindingInfo mainDataStructure[1024]; PathfindingInfo *field_2414; int field_2418; int field_241C[63]; }; #pragma pack(pop) /* 107 */ enum COMBAT_GUI { COMBAT_GUI_MESSAGE_ROW_1 = 12, COMBAT_GUI_MESSAGE_ROW_2 = 13, }; /* 109 */ #pragma pack(push, 1) struct town { char idx; char ownerIdx; char alignment; char factionID; unsigned __int8 x; unsigned __int8 y; char buildDockRelated; char field_7; armyGroup garrison; char visitingHeroIdx; unsigned int buildingsBuiltFlags; char mageGuildLevel; char field_1D; __int16 numCreaturesInDwelling[12]; char exists; char mayNotBeUpgradedToCastle; char field_38; char playerPos; __int16 extraIdx; char mageGuildSpells[5][4]; char numSpellsOfLevel[5]; __int16 field_55; char name[12]; char field_63; }; #pragma pack(pop) /* 111 */ enum FACTION { FACTION_KNIGHT = 0x0, FACTION_BARBARIAN = 0x1, FACTION_SORCERESS = 0x2, FACTION_WARLOCK = 0x3, FACTION_WIZARD = 0x4, FACTION_NECROMANCER = 0x5, FACTION_MULTIPLE = 0x6, FACTION_RANDOM = 0x7, }; /* 112 */ enum HERO_TYPE { HERO_TYPE_KNIGHT = 0x0, HERO_TYPE_BARBARIAN = 0x1, HERO_TYPE_SORCERESS = 0x2, HERO_TYPE_WARLOCK = 0x3, HERO_TYPE_WIZARD = 0x4, HERO_TYPE_NECROMANCER = 0x5, HERO_TYPE_KNIGHT_CAPTAIN = 0x6, HERO_TYPE_BARBARIAN_CAPTAIN = 0x7, HERO_TYPE_SORCERESS_CAPTAIN = 0x8, HERO_TYPE_WARLOCK_CAPTAIN = 0x9, HERO_TYPE_WIZARD_CAPTAIN = 0xA, HERO_TYPE_NECROMANCER_CAPTAIN = 0xB, HERO_TYPE_NONE = 0xFFFFFFFF, }; /* 113 */ enum COMBAT_ICON_INDICES { COMBAT_ICON_IDX_TEXTBAR = 0x1, COMBAT_ICON_IDX_CATAPULT = 0x3, COMBAT_ICON_IDX_CASTLE = 0x5, COMBAT_ICON_IDX_KEEP = 0x7, COMBAT_ICON_SPELLS = 0x8, COMBAT_ICON_MISC = 0x9, COMBAT_ICON_VIEW_ARMY = 0xA, COMBAT_ICON_MINI_LUCK_MORALE = 0xB, COMBAT_ICON_SPELL_INF = 0xC, COMBAT_ICON_MOAT_PART = 0xD, COMBAT_ICON_MOAT_WHOLE = 0xE, }; /* 114 */ enum BRIDGE_STATUS { BRIDGE_OPEN = 0x0, BRIDGE_CLOSING_1 = 0x1, BRIDGE_CLOSING_2 = 0x2, BRIDGE_DESTROYED = 0x3, BRIDGE_CLOSED = 0x4, }; /* 115 */ #pragma pack(push, 1) struct PathfindingInfo { char field_0; char field_1; __int16 field_2; char field_4; int field_5; }; #pragma pack(pop) /* 116 */ enum HERO_FLAGS { HERO_AT_SEA = 0x80, }; /* 117 */ enum BUILDINGS_BUILT { BUILDING_THIEVES_GUILD_BUILT = 0x2, BUILDING_TAVERN_BUILT = 0x4, BUILDING_TENT_BUILT = 0x20, }; /* 118 */ enum HERO_FLAGS_2 { HERO_VISITED_WELL = 0x10, HERO_ARMY_COMPACT = 0x80, }; /* 119 */ #pragma pack(push, 1) struct SElevationOverlay { TERRAIN_BMASK terrains; _BYTE coveredHexes[15]; }; #pragma pack(pop) /* 120 */ enum TERRAIN_BMASK : __int16 { TERRAIN_GRASS_BMASK = 0x2, TERRAIN_SNOW_BMASK = 0x4, TERRAIN_DIRT_BMASK = 0x40, TERRAIN_WASTELAND_BMASK = 0x80, }; /* 121 */ #pragma pack(push, 1) struct SCmbtObstacle { int terrains; char visualHeight; char numBlocked; char hexOffs[8]; }; #pragma pack(pop) /* 122 */ enum ANIMATION_TYPE { ANIMATION_TYPE_START_MOVE = 0, ANIMATION_TYPE_SUB_START_MOVE = 1, ANIMATION_TYPE_MOVE = 2, ANIMATION_TYPE_SUB_END_MOVE = 3, ANIMATION_TYPE_END_MOVE = 4, ANIMATION_TYPE_WHOLE_MOVEMENT_CYCLE = 5, ANIMATION_TYPE_WALKING = 6, ANIMATION_TYPE_STANDING = 7, ANIMATION_TYPE_FIDGET_1 = 8, ANIMATION_TYPE_FIDGET_2 = 9, ANIMATION_TYPE_FIDGET_3 = 10, ANIMATION_TYPE_FIDGET_4 = 11, ANIMATION_TYPE_FIDGET_5 = 12, ANIMATION_TYPE_DYING = 13, ANIMATION_TYPE_WINCE = 14, ANIMATION_TYPE_WINCE_RETURN = 15, ANIMATION_TYPE_MELEE_ATTACK_UPWARDS = 16, ANIMATION_TYPE_MELEE_ATTACK_UPWARDS_RETURN = 17, ANIMATION_TYPE_TWO_HEX_ATTACK_UPWARDS = 18, ANIMATION_TYPE_TWO_HEX_ATTACK_UPWARDS_RETURN = 19, ANIMATION_TYPE_MELEE_ATTACK_FORWARDS = 20, ANIMATION_TYPE_MELEE_ATTACK_FORWARDS_RETURN = 21, ANIMATION_TYPE_TWO_HEX_ATTACK_FORWARDS = 22, ANIMATION_TYPE_TWO_HEX_ATTACK_FORWARDS_RETURN = 23, ANIMATION_TYPE_MELEE_ATTACK_DOWNWARDS = 24, ANIMATION_TYPE_MELEE_ATTACK_DOWNWARDS_RETURN = 25, ANIMATION_TYPE_TWO_HEX_ATTACK_DOWNWARDS = 26, ANIMATION_TYPE_TWO_HEX_ATTACK_DOWNWARDS_RETURN = 27, ANIMATION_TYPE_RANGED_ATTACK_UPWARDS = 28, ANIMATION_TYPE_RANGED_ATTACK_UPWARDS_RETURN = 29, ANIMATION_TYPE_RANGED_ATTACK_FORWARDS = 30, ANIMATION_TYPE_RANGED_ATTACK_FORWARDS_RETURN = 31, ANIMATION_TYPE_RANGED_ATTACK_DOWNWARDS = 32, ANIMATION_TYPE_RANGED_ATTACK_DOWNWARDS_RETURN = 33, }; /* 123 */ enum MANAGER_TYPE { MANAGER_TYPE_HERO_WINDOW_MANAGER = 0x20, MANAGER_TYPE_RESOURCE_MAMANGER = 0x80, MANAGER_TYPE_SWAP_MANAGER = 0x100, MANAGER_TYPE_COMBAT_MANAGER = 0x200, }; /* 124 */ #pragma pack(push, 1) struct iconWidget { widgetVtable *vtable; heroWindow *parentWindow; widget *nextInLinkedList; widget *prevInLinkedList; __int16 fieldID; __int16 componentIndex; __int16 field_14; __int16 field_16; __int16 offsetX; __int16 offsetY; __int16 width; __int16 height; icon *icon; __int16 imgIdx; char mirror; __int16 field_27; int iconFileID; }; #pragma pack(pop) /* 125 */ enum TERRAIN_IDX { TERRAIN_IDX_GRASS = 0x1, TERRAIN_IDX_SNOW = 0x2, TERRAIN_IDX_DIRT = 0x6, TERRAIN_IDX_WASTELAND = 0x7, }; /* 126 */ #pragma pack(push, 1) struct townManager { managerVtable *vtable; baseManager *next; baseManager *prev; int type; int idx; char name[30]; int ready; town *castle; icon *couldBeBackground; BuildingDisplay *buildingDisplays[32]; int curBuilding; int factionID; int field_C6; heroWindow *townScreen; strip *garrisonDisplay; strip *visitingArmyDisplay; strip *field_D6; int field_DA; strip *field_DE; int field_E2; strip *field_E6; int field_EA; bankBox *bankbox; char infoMessage[80]; int field_142; int field_146; int field_14A; int field_14E; int field_152; int field_156; int field_15A; int field_15E; heroWindow *curScreen; heroWindow *dialog; int field_16A; int field_16E; int recruitHeroConfirmed; hero *heroBeingRecruited; }; #pragma pack(pop) /* 127 */ #pragma pack(push, 1) struct advManager { managerVtable *vtable; baseManager *next; baseManager *prev; int type; int idx; char name[30]; int ready; int field_36; widget *someComponents[2][12]; heroWindow *adventureScreen; int sizeOfSomethingMapRelated; int field_A2; int currentTerrain; int field_AA; fullMap *map; iconWidget *heroScrollbarKnob; iconWidget *castleScrollbarKnob; int field_BA; int field_BE; tileset *groundTileset; tileset *clofTileset; tileset *stonTileset; int tilesetIcns[64]; icon *radarIcon; icon *clopIcon; int viewX; int viewY; int field_1DE; int field_1E2; int xOff; int yOff; int field_1EE; int field_1F2; int mapPortLeftX; int mapPortTopY; int field_1FE; int field_202; int field_206; int field_20A; int field_20E; int field_212; int field_216; void *heroIcons[6]; icon *boatIcon; icon *frothIcon; icon *shadowIcon; icon *boatShadowIcon; void *flagIconsHero[6]; void *flagIconsBoat[6]; int field_272; int field_276; int mobilizedHeroFactionOrBoat; int field_27E; int mobilizedHeroBaseFrameBit8IsFlip; int mobilizedHeroAnimPos; int field_28A; int field_28E; int field_292; int field_296; int field_29A; int field_29E; int hasDrawnCursor; int heroMobilized; int field_2AA; int field_2AE; int field_2B2; int field_2B6; int field_2BA; int field_2BE; int field_2C2[4][2]; void *loopSamples[28]; sample *walkSamples[9]; int identifyCast; int field_37A; }; #pragma pack(pop) /* 128 */ #pragma pack(push, 1) struct tileset { resourceVtable *vtable; RESOURCE_TYPE resourceType; __int16 referenceCount; int fileID; resource *next; __int16 numTiles; __int16 field_12; __int16 field_14; void *contents; }; #pragma pack(pop) /* 129 */ enum ADVENTURE_MAP_LOCATION { LOCATION_ALCHEMIST_LAB = 1, LOCATION_SIGN = 2, LOCATION_BUOY = 3, LOCATION_SKELETON = 4, LOCATION_DAEMON_CAVE = 5, LOCATION_TREASURE_CHEST = 6, LOCATION_FAERIE_RING = 7, LOCATION_CAMPFIRE = 8, LOCATION_FOUNTAIN = 9, LOCATION_GAZEBO = 10, LOCATION_ANCIENT_LAMP = 11, LOCATION_GRAVEYARD = 12, LOCATION_ARCHERS_HOUSE = 13, LOCATION_GOBLIN_HUT = 14, LOCATION_DWARF_COTTAGE = 15, LOCATION_PEASANT_HUT = 16, LOCATION_LOG_CABIN = 17, LOCATION_ROAD = 18, LOCATION_EVENT = 19, LOCATION_DRAGON_CITY = 20, LOCATION_LIGHTHOUSE = 21, LOCATION_WATERWHEEL = 22, LOCATION_MINE = 23, LOCATION_ARMY_CAMP = 24, LOCATION_OBELISK = 25, LOCATION_OASIS = 26, LOCATION_RESOURCE = 27, LOCATION_SAWMILL = 29, LOCATION_ORACLE = 30, LOCATION_SHRINE_FIRST = 31, LOCATION_SHIPWRECK = 32, LOCATION_SEA_CHEST = 33, LOCATION_DESRT_TENT = 34, LOCATION_TOWN = 35, LOCATION_STONE_LITHS = 36, LOCATION_WAGON_CAMP = 37, LOCATION_WELL = 38, LOCATION_WHIRLPOOL = 39, LOCATION_WINDMILL = 40, LOCATION_ARTIFACT = 41, LOCATION_HERO = 42, LOCATION_BOAT = 43, LOCATION_RANDOM_ARTIFACT = 45, LOCATION_RANDOM_RESOURCE = 46, LOCATION_RANDOM_MONSTER = 47, LOCATION_RANDOM_TOWN = 48, LOCATION_RANDOM_CASTLE = 49, LOCATION_RANDOM_MONSTER_WEAK = 51, LOCATION_RANDOM_MONSTER_MEDIUM = 52, LOCATION_RANDOM_MONSTER_STRONG = 53, LOCATION_RANDOM_MONSTER_VERY_STRONG = 54, LOCATION_RANDOM_HERO = 55, LOCATION_NOTHING_SPECIAL = 56, LOCATION_WATCH_TOWER = 58, LOCATION_TREE_HOUSE = 59, LOCATION_TREE_CITY = 60, LOCATION_RUINS = 61, LOCATION_FORT = 62, LOCATION_TRADING_POST = 63, LOCATION_ABANDONED_MINE = 64, LOCATION_DWARF_CABIN = 65, LOCATION_STANDING_STONES = 66, LOCATION_IDOL = 67, LOCATION_TREE_OF_KNOWLEDGE = 68, LOCATION_WITCH_DOCTORS_HUT = 69, LOCATION_TEMPLE = 70, LOCATION_HILL_FORT = 71, LOCATION_HALFLING_HOLE = 72, LOCATION_MERCENARY_CAMP = 73, LOCATION_SHRINE_SECOND_ORDER = 74, LOCATION_SHRINE_THIRD_ORDER = 75, LOCATION_PYRAMID = 76, LOCATION_CITY_OF_DEAD = 77, LOCATION_EXCAVATION = 78, LOCATION_SPHINX = 79, LOCATION_WAGON = 80, LOCATION_TAR_PIT = 81, LOCATION_ARTESIAN_SPRING = 82, LOCATION_TROLL_BRIDGE = 83, LOCATION_WATERING_HOLE = 84, LOCATION_WITCH_HUT = 85, LOCATION_XANADU = 86, LOCATION_CAVE = 87, LOCATION_LEAN_TO = 88, LOCATION_MAGELLANS_MAPS = 89, LOCATION_FLOTSAM = 90, LOCATION_DERELICT_SHIP = 91, LOCATION_SHIPWRECK_SURVIVOR = 92, LOCATION_BOTTLE = 93, LOCATION_MAGIC_WELL = 94, LOCATION_MAGIC_GARDEN = 95, LOCATION_OBSERVATION_TOWER = 96, LOCATION_FREEMANS_FOUNDRY = 97, LOCATION_STREAM = 98, LOCATION_TREES = 99, LOCATION_MOUNTAINS = 100, LOCATION_VOLCANO = 101, LOCATION_FLOWERS = 102, LOCATION_ROCK = 103, LOCATION_LAKE = 104, LOCATION_MANDRAKE = 105, LOCATION_DEAD_TREE = 106, LOCATION_STUMP = 107, LOCATION_CRATER = 108, LOCATION_CACTUS = 109, LOCATION_MOUND = 110, LOCATION_DUNE = 111, LOCATION_LAVA_POOL = 112, LOCATION_SHRUB = 113, LOCATION_HOLE = 114, LOCATION_OUTCROPPING = 115, LOCATION_RANDOM_ARTIFACT_TREASURE = 116, LOCATION_RANDOM_ARTIFACT_MINOR = 117, LOCATION_RANDOM_ARTIFACT_MAJOR = 118, LOCATION_BARRIER = 119, LOCATION_TRAVELLER_TENT = 120, LOCATION_EXPANSION_DWELLING = 121, LOCATION_ALCHEMIST_TOWER = 122, LOCATION_JAIL = 123, TILE_HAS_EVENT = 128, }; /* 131 */ #pragma pack(push, 1) struct mapCell { __int16 groundIndex; char bitfield_1_hasObject_1_isRoad_6_objTileset; char objectIndex; unsigned __int16 field_4_1_preventSpawn_1_isShadow_1_13_extraInfo; char field__1_hasOverlay_1_hasLateOverlay_6_overlayTileset; char overlayIndex; char flags; char objType; __int16 extraIdx; }; #pragma pack(pop) /* 132 */ #pragma pack(push, 1) struct playerData { char color; char numHeroes; char curHeroIdx; char relatedToSomeSortOfHeroCountOrIdx; char heroesOwned[8]; char heroesForPurchase[2]; char relatedToMaxOrNumHeroes; int personality; char _3[45]; char field_40; char field_41; char field_42; char daysLeftWithoutCastle; char numCastles; __int8 mightBeCurCastleIdx; char relatedToUnknown; char castlesOwned[72]; int resources[7]; char hasEvilFaction; char barrierTentsVisited; char _4_2[58]; int field_E7[7]; char _5[12]; float field_10F; int field_113; __int16 field_117; char field_119; char field_11A; }; #pragma pack(pop) /* 133 */ enum RESOURCES { RESOURCE_WOOD = 0x0, RESOURCE_MERCURY = 0x1, RESOURCE_ORE = 0x2, RESOURCE_SULFUR = 0x3, RESOURCE_CRYSTAL = 0x4, RESOURCE_GEMS = 0x5, RESOURCE_GOLD = 0x6, }; /* 135 */ #pragma pack(push, 1) struct strip { heroWindow *window; char _1[24]; int x; int y; int field_24; int drawBorder; void *field_2C[6]; icon *stripIcon; icon *creaturePortraits[5]; int creatureTypes[5]; icon *portraitIcon; icon *portraitFlagIcon; int portraitIconIdx; int field_7C; armyGroup *army; }; #pragma pack(pop) /* 136 */ enum BUILDING_CODE : __int8 { BUILDING_MAGE_GUILD = 0x0, BUILDING_THIEVES_GUILD = 0x1, BUILDING_TAVERN = 0x2, BUILDING_DOCK = 0x3, BUILDING_WELL = 0x4, BUILDING_TENT = 0x5, BUILDING_CASTLE = 0x6, BUILDING_STATUE = 0x7, BUILDING_LEFT_TURRET = 0x8, BUILDING_RIGHT_TURRET = 0x9, BUILDING_MARKET = 0xA, BUILDING_SPECIAL_GROWTH = 0xB, BUILDING_MOAT = 0xC, BUILDING_SPECIAL = 0xD, BUILDING_BOAT = 0xE, BUILDING_CAPTAIN = 0xF, BUILDING_EXT_0 = 0x10, BUILDING_EXT_1 = 0x11, BUILDING_EXT_2 = 0x12, BUILDING_DWELLING_1 = 0x13, BUILDING_DWELLING_2 = 0x14, BUILDING_DWELLING_3 = 0x15, BUILDING_DWELLING_4 = 0x16, BUILDING_DWELLING_5 = 0x17, BUILDING_DWELLING_6 = 0x18, BUILDING_UPGRADE_1 = 0x19, BUILDING_UPGRADE_2 = 0x1A, BUILDING_UPGRADE_3 = 0x1B, BUILDING_UPGRADE_4 = 0x1C, BUILDING_UPGRADE_5 = 0x1D, BUILDING_UPGRADE_5B = 0x1E, BUILDING_EXT_3 = 0x1F, }; /* 138 */ #pragma pack(push, 1) struct SBuildingInfo { char animationLength; __int16 x; __int16 y; __int16 width; __int16 height; }; #pragma pack(pop) /* 139 */ #pragma pack(push, 1) struct BuildingDisplay { int animationLength; int animationIdx; int built; int buildingCode; icon *icon; border *guiElement; }; #pragma pack(pop) /* 141 */ #pragma pack(push, 1) struct bankBox { playerData *player; __int16 x; __int16 y; heroWindow *window; }; #pragma pack(pop) /* 142 */ #pragma pack(push, 1) union Event { tag_message inputEvt; GUIMessage guiMsg; }; #pragma pack(pop) /* 143 */ #pragma pack(push, 1) struct GUIMessage { INPUT_EVENT_CODE eventCode; int messageType; int fieldID; int inputTypeBitmask; int altXCoord; int altYCoord; void *payload; }; #pragma pack(pop) /* 145 */ #pragma pack(push, 1) struct SWinSetup { WINDOW_IDS screenIdx; __int16 fieldID; char *label; }; #pragma pack(pop) /* 150 */ #pragma pack(push, 1) struct IMAGE_DATA_DIRECTORY { DWORD VirtualAddress; DWORD Length; }; #pragma pack(pop) /* 151 */ enum RESOURCEMGR_CONSTANTS { NUM_AGG_FILES = 2, NUM_GOOD_EVIL_ICONS = 37, }; /* 153 */ enum ARTIFACT_CONSTANTS { NUM_BASE_ARTIFACTS = 81, NUM_EXPANSION_ARTIFACTS = 102, }; /* 154 */ enum WIN_CONDITION_TYPES { WIN_CONDITION_CAPTURE_CASTLE = 0x1, WIN_CONDITION_DEFEAT_HERO = 0x2, WIN_CONDITION_FIND_ARTIFACT = 0x3, WIN_CONDITION_DEFEAT_COLOR = 0x4, WIN_CONDITION_ACCUMULATE_GOLD = 0x5, }; /* 155 */ enum RESOURCE_CONSTANTS { NUM_RESOURCES = 0x7, }; /* 156 */ enum SKILL_CONSTANTS { MAX_SECONDARY_SKILL_LEVELS = 3, MAX_KNOWABLE_SECONDARY_SKILLS = 8, }; /* 157 */ enum SPELL_CONSTANTS { NUM_SPELLS = 65, }; /* 158 */ enum MAP_CONSTANTS { MAX_CASTLES = 72, }; /* 159 */ #pragma pack(push, 1) struct mapCellExtra { __int16 nextIdx; unsigned __int8 _1_q_7_objTileset; char objectIndex; char field_4_1_1_1_isShadow_5; char _1_q_1_hasLateOverlay_6_q; char field_6; }; #pragma pack(pop) /* 161 */ enum WINDOW_IDS : __int8 { COMBAT_SETTINGS_WINDOW = 0x1, ADVENTURE_SETTINGS_WINDOW = 0x2, HERO_VIEW_WINDOW = 0x6, }; /* 162 */ enum GENERAL_GUI_FIELD_IDS { FIELD_TOP_BANNER = 2, BUTTON_CANCEL = 30721, BUTTON_OK = 30722, }; /* 163 */ #pragma pack(push, 1) struct boat { char idx; char x; char y; char field_3; char underlyingObjType; char underlyingObjExtra; char field_6; char owner; }; #pragma pack(pop) /* 165 */ #pragma pack(push, 1) struct SMapHeader { int field_0; __int16 field_4; char width; char height; char hasPlayer[6]; char playerMayBeHuman[6]; char playerMayBeComp[6]; char numPlayers; char minHumans; char maxHumans; char winConditionType; char relatedToWinConditionType; char allowDefeatAllVictory; __int16 winConditionArgumentOrLocX; char lossConditionType; char lossConditionArgumentOrLocX; char field_24; char noStartingHeroInCastle; char playerFactions[6]; __int16 winConditionArgumentOrLocY; __int16 lossConditionArgumentOrLocY; __int16 relatedToPlayerColorOrSide; int field_32; char field_36; char field_37; char nextTownName; char field_39; char name[60]; char description[298]; char field_1A0; char field_1A1; char numRumors; char numEvents; }; #pragma pack(pop) /* 166 */ #pragma pack(push, 1) struct mine { char field_0; char owner; char type; char guardianType; char guardianQty; char x; char y; }; #pragma pack(pop) /* 167 */ #pragma pack(push, 1) struct TownExtra { char color; char customBuildings; int buildingsBuilt; char mageGuildLevel; char customGarrison; armyGroup garrison; char hasCaptain; char field_18; char name[12]; char field_25; __int16 faction; char mayNotBeUpgraded; char field_29; char field_2A; char field_2B[6]; char _[17]; char field_42; char field_43; char field_44; char field_45; }; #pragma pack(pop) /* 168 */ #pragma pack(push, 1) struct fileRequester { managerVtable *vtable; baseManager *next; baseManager *prev; int type; int idx; char name[30]; int ready; int field_36; int field_3A; int field_3E; int field_42; char field_46[300]; char field_172[300]; int field_29E; int field_2A2; int field_2A6; int field_2AA; char field_2AE[356]; int field_412; int field_416; int field_41A; int field_41E; int field_422; int field_426; int field_42A; char field_42E; }; #pragma pack(pop) /* 169 */ enum ICON_GUI_FLAGS { ICON_GUI_VISIBLE = 0x4, }; /* 170 */ #pragma pack(push, 1) struct heroMapExtra { char owner; char hasArmy; armyGroup army; char field_11; char heroID; char artifacts[3]; char field_16; int experience; char hasSecondarySkills; char secondarySkills[8]; char secondarySkillLevel[8]; char field_2C; char hasName; char name[13]; char relatedToJailCondition; char factionID; char couldBeHasFaction; char field_3E; char field_3F; char field_40; char field_41; char field_42; char field_43; char field_44; char field_45; char field_46; char field_47; char field_48; char field_49; char field_4A; char field_4B; }; #pragma pack(pop) /* 171 */ #pragma pack(push, 1) struct SCmbtHero { __int16 castXOff; __int16 castLowXOff; __int16 castYOff; __int16 castLowYOff; char numFidgets; char animationLength[12]; char frameIndex[12][9]; }; #pragma pack(pop) /* 172 */ #pragma pack(push, 1) struct sphinxMapExtra { char unclaimed; int resourceReward[7]; __int16 artifactReward; char numAnswers; char answers[8][13]; char riddle[1]; }; #pragma pack(pop) /* 173 */ #pragma pack(push, 1) struct SignExtra { char field_0; int field_1; int field_5; char name[1]; }; #pragma pack(pop) /* 174 */ enum HERO_ANIMATION_TYPE { HERO_ANIMATION_STANDING = 0, HERO_ANIMATION_CAST_MASS = 3, HERO_ANIMATION_CAST_MASS_RETURN = 4, HERO_ANIMATION_CAST_UP = 5, HERO_ANIMATION_CAST_UP_RETURN = 6, HERO_ANIMATION_CAST_DOWN = 7, HERO_ANIMATION_CAST_DOWN_RETURN = 8, HERO_ANIMATION_FIDGET_1 = 9, HERO_ANIMATION_FIDGET_2 = 10, HERO_ANIMATION_FIDGET_3 = 11, }; /* 175 */ #pragma pack(push, 1) struct SampleChannelStruct { int field_0; int field_4; int field_8; }; #pragma pack(pop) /* 176 */ enum OBJ_TILESET { TILESET_HAUNTED = 10, TILESET_ARTIFACT = 11, TILESET_MONSTER = 12, TILESET_ARTIFACT_TAKEN = 13, TILESET_FLAG = 14, TILESET_RESOURCE_DISPLAY = 15, TILESET_HOURGLASS = 16, TILESET_ROUTE = 17, TILESET_STONBACK = 19, TILESET_MONSTER_ANIMATION = 20, TILESET_HERO = 21, TILESET_SNOW_MOUNTAIN = 22, TILESET_SWAMP_MOUNTAIN = 23, TILESET_LAVA_MOUNTAIN = 24, TILESET_DESERT_MOUNTAIN = 25, TILESET_DIRT_MOUNTAIN = 26, TILESET_MOUNTAIN_MULTIPLE = 27, TILESET_EXTRA_OVERLAY = 29, TILESET_ROAD = 30, TILESET_MOUNTAIN_CRACKED = 31, TILESET_MOUNTAIN_GRASS = 32, TILESET_TREE_JUNGLE = 33, TILESET_TREE_EVIL = 34, TILESET_OBJ_TOWN = 35, TILESET_TOWN_TERRAIN = 36, TILESET_TOWN_SHADOW = 37, TILESET_TOWN_RANDOM = 38, TILESET_OBJECT_EXTRA = 39, TILESET_OBJECT_WATER_2 = 40, TILESET_OBJECT_MULTIPLE_2 = 41, TILESET_OBJECT_TREE_SNOW = 42, TILESET_OBJECT_TREE_FIR = 43, TILESET_OBJECT_TREE_FALL = 44, TILESET_OBJECT_STREAM = 45, TILESET_OBJECT_RESOURCE = 46, TILESET_OBJECT_DUMMY = 47, TILESET_OBJECT_GRASS_2 = 48, TILESET_OBJECT_TREE_DECIDUOUS = 49, TILESET_OBJECT_WATER = 50, TILESET_OBJECT_GRASS = 51, TILESET_OBJECT_SNOW = 52, TILESET_OBJECT_SWAMP = 53, TILESET_OBJECT_LAVA = 54, TILESET_OBJECT_DESERT = 55, TILESET_OBJECT_DIRT = 56, TILESET_OBJECT_CRACKED = 57, TILESET_OBJECT_LAVA_3 = 58, TILESET_OBJECT_MULTIPLE = 59, TILESET_OBJECT_LAVA_2 = 60, TILESET_OBJECT_EXPANSION_1 = 61, TILESET_OBJECT_EXPANSION_2 = 62, TILESET_OBJECT_EXPANSION_3 = 63, }; /* 177 */ enum MAP_CELL_FLAGS { MAP_CELL_HAS_ACTIVE_HERO = 0x40, }; /* 178 */ enum NormalDialogType { DIALOG_OKAY = 0x1, DIALOG_YES_NO = 0x2, DIALOG_CANCEL = 0x3, DIALOG_RIGHT_CLICK = 0x4, DIALOG_CANCEL_ALT = 0x6, DIALOG_LEARN_CHOICE = 0x7, }; /* 179 */ #pragma pack(push, 1) struct ExpCampaign { int campaignID; int currentMapID; int numMaps; char mapChoice[8]; char mapsPlayed[8]; __int16 daysPlayed[8]; char awards[11]; char bonusChoices[8]; int unknownVariable; int mightBeScenarioID; int window; int anIntVariable; }; #pragma pack(pop) /* 180 */ #pragma pack(push, 1) struct swapManager { void *vtable; baseManager *next; baseManager *prev; int type; int idx; char name[30]; int ready; heroWindow *window; int swapButtonIcn; hero *heroes[2]; int heroIdxMovingFrom; int heroIdxMovingTo; int idxMovingFrom; int idxMovingTo; int field_56; }; #pragma pack(pop) /* End of file */