Heroes of Might and Magic Community
visiting hero! Register | Today's Posts | Games | Search! | FAQ/Rules | AvatarList | MemberList | Profile


Age of Heroes Headlines:  
5 Oct 2016: Heroes VII development comes to an end.. - read more
6 Aug 2016: Troubled Heroes VII Expansion Release - read more
26 Apr 2016: Heroes VII XPack - Trial by Fire - Coming out in June! - read more
17 Apr 2016: Global Alternative Creatures MOD for H7 after 1.8 Patch! - read more
7 Mar 2016: Romero launches a Piano Sonata Album Kickstarter! - read more
19 Feb 2016: Heroes 5.5 RC6, Heroes VII patch 1.7 are out! - read more
13 Jan 2016: Horn of the Abyss 1.4 Available for Download! - read more
17 Dec 2015: Heroes 5.5 update, 1.6 out for H7 - read more
23 Nov 2015: H7 1.4 & 1.5 patches Released - read more
31 Oct 2015: First H7 patches are out, End of DoC development - read more
5 Oct 2016: Heroes VII development comes to an end.. - read more
[X] Remove Ads
LOGIN:     Username:     Password:         [ Register ]
HOMM1: info forum | HOMM2: info forum | HOMM3: info mods forum | HOMM4: info CTG forum | HOMM5: info mods forum | MMH6: wiki forum | MMH7: wiki forum
Heroes Community > Library of Enlightenment > Thread: Heroes 3 - Editing heroes in memory
Thread: Heroes 3 - Editing heroes in memory This thread is 5 pages long: 1 2 3 4 5 · NEXT»
joerginger
joerginger


Hired Hero
posted July 15, 2006 01:40 AM
Edited by joerginger at 01:57, 29 Jul 2006.

Heroes 3 - Editing heroes in memory

Heroes of Might & Magic 3 + Addons (Heroes 3 Complete) & Heroes Chronicles

Data for memory editing e.g. using Winhex (or for creating a trainer)

The list is incomplete, since I never tried to find the move points, the mana, luck or morale values.

Resources: Their values start exactly 3 lines above the player name
  (or "_omputer", "Player" or the current player colour,
          depending on the game version i.e. H3, expansion or
          Chronicles, can't remember which was which)

  1st entry: wood, after that 5 times 4 Bytes for the other
          resources, the 6th entry is gold

Charakter values (primary stats): 4 lines + 1 Byte above 1st letter of first hero's name
(1 Byte each)
The highest value that can be displayed is 99.

Spells: They're stored right in front of the character values.
00 = unknown, 01 = known
Note that some spells (all level 5 ones?) don't instantly
       appear after editing them as known, you'll see this when you
       try to edit the hero again, there'll be some 00 Bytes among
       the rows of 01 Bytes.

Experience: 3 lines minus 2 Bytes below 1st letter of the hero's name (4 Bytes)

Units: 7 times 4 Bytes beginning 4 lines below experience = Unit type
(for code list, see below)

      7 times 4 Bytes immediately after 7th unit type = amount of
        units (don't put in numbers that are too high, they'll turn
        into negative)

Skills: following right after unit numbers; 00 = not available, 03 = expert
(1 Byte = 1 skill)
Skills that weren't present before editing don't get an icon,
       but their effect will be there. I'm not sure whether this
       works with wisdom or artillery, so feel free to try it
       yourself.

The skills appear in the following order after the 4th Byte of the 7th unit number:

01 Pathfinding
02 Archery
03 Logistics
04 Scouting
05 Diplomacy
06 Navigation
07 Leadership
08 Wisdom
09 Mysticism
10 Luck
11 Ballistics
12 Eagle Eye
13 Necromancy
14 Estates
15 Fire Magic
16 Air Magic
17 Water Magic
18 Earth Magic
19 Scholar
20 Tactics
21 Artillery
22 Learning
23 Offense
24 Armourer
25 Intelligence
26 Sorcery
27 Resistance
28 First Aid

Artefacts can be added, too (for code list, see below):

A little bit below the skill values there is a large block of FFFF... The series is interrupted by a 03000000 value. That's the catapult which every hero has. Each artefact is stored in 8 Bytes, only the first 4 are used, though, the latter 4 must be FFFFFFFF. If you want to add an artefact, just count 8 F's after the 03000000 artefact, and you can add any artefact to your backpack. Don't forget to actually equip them after editing.
Of course you could also try to find the artefact slots on the paper doll, but IMO that's too much work and might lead to crashes in case you put the wrong artefact in the wrong slot. The slots are somewhere in front of the catapult.

Appendix:

There is a list of hex values for unit type and for artefacts somewhere (gamefaq.org most likely), so the following lists including the comments are copied from that document:

Unit type hex codes:

00000000 - Pikeman
01000000 - Halberdier
02000000 - Archer
03000000 - Marksman
04000000 - Griffin
05000000 - Royal griffin
06000000 - Swordsman
07000000 - Crusader
08000000 - Monk
09000000 - Zealot
0A000000 - Cavalier
0B000000 - Champion
0C000000 - Angel
0D000000 - Archangel
0E000000 - Centaur
0F000000 - Centaur capitan
10000000 - Dwarf
11000000 - Battle dwarf
12000000 - Wood elf
13000000 - Grand elf
14000000 - Pegasus
15000000 - Silver pegasus
16000000 - Dendroid guard
17000000 - Dendroid solider
18000000 - Unicorn
19000000 - War unicorn
1A000000 - Green dragon
1B000000 - Gold dragon
1C000000 - Gremlin
1D000000 - Master gremlin
1E000000 - Stone gargoyle
1F000000 - Obsidian gargoyle
20000000 - Stone golem
21000000 - Iron golem
22000000 - Mage
23000000 - Arch mage
24000000 - Genie
25000000 - Master genie
26000000 - Naga
27000000 - Naga queen
28000000 - Giant
29000000 - Titan
2A000000 - Imp
2B000000 - Familiar
2C000000 - Gog
2D000000 - Magog
2E000000 - Hell hound
2F000000 - Cerberus
30000000 - Daemon
31000000 - Horned daemon
32000000 - Pit fiend
33000000 - Pit lord
34000000 - Efreet
35000000 - Efreet sultan
36000000 - Devil
37000000 - Arch Devil
38000000 - Skeleton
39000000 - Skeleton Warrior
3A000000 - Walking dead
3B000000 - Zombie
3C000000 - Wight
3D000000 - Wraight
3E000000 - Vampire
3FD00000 - Vampire lord
40000000 - Lich
41000000 - Power Lich
42000000 - Black knight
43000000 - Dead knight
44000000 - Bone dragon
45000000 - Ghost dragon
46000000 - Tryglodyte
47000000 - Infernal tryglodyte
48000000 - Harpy
49000000 - Harpy hag
4A000000 - Beholder
4B000000 - Evil eve
4C000000 - Medusa
4D000000 - Medusa queen
4E000000 - Minotaur
4F000000 - Minotaur king
50000000 - Manticore
51000000 - Scorpicore
52000000 - Red dragon
53000000 - Black dragon
54000000 - Goblin
55000000 - Hobgoblin
56000000 - Wolf rider
57000000 - Wolf raider
58000000 - Orc
59000000 - Orc chieftain
5A000000 - Ogre
5B000000 - Ogre mage
5C000000 - Roc
5D000000 - Thunderbird
5E000000 - Cyclops
5F000000 - Cyclops king
60000000 - Behemoth
61000000 - Ancient behemoth
62000000 - Gnoll
63000000 - Gnoll marauder
64000000 - Lizardman
65000000 - Lizard warrior
66000000 - Serpent fly
67000000 - Dragonfly
68000000 - Basilisk
69000000 - Greater Basilisk
6A000000 - Gorgon
6B000000 - Mighty gorgon
6C000000 - Wyvern
6D000000 - Wyvern Monarch
6E000000 - Hydra
6F000000 - Chaos hydra
70000000 - Air elemental
71000000 - Earth elemental
72000000 - Fire elemental
73000000 - Water elemental
74000000 - Golem
75000000 - Diamond golem

Some additional ones I found (expansion creatures, IIRC):

76000000 - Pixies
77000000 - Sprites
78000000 - Psychic Elementals
79000000 - Magic Elementals

85000000 - Crystal Dragons
86000000 - Faerie Dragons

88000000 - Enchanters
89000000 - Sharpshooters

Artefacts:

01000000 - Spell Scroll - but I don't know how to put a spell in it
02000000 - The Grail
03000000 - Catapult - useless
04000000 - Ballist - useless
05000000 - Ammo cart - useless
06000000 - Healers tent - useless
07000000 - Centaur's axe
08000000 - Blackshard of the dead knight
09000000 - Greater Gnoll's Fail
0A000000 - Ogre's club of havoc
0B000000 - Sword of Hellfire
0C000000 - Titan's gladius
0D000000 - Shield of the dwarven lords
0E000000 - Shield of the yawning dead
0F000000 - Buckler of the gnoll king
10000000 - Targ of the rampaging ogre
11000000 - Shield of the dammed
12000000 - Sentinel's Shield
13000000 - Helm of the alabaster unicorn
14000000 - Skull helmet
15000000 - Helm of chaos
16000000 - Crown of the supreme magi
17000000 - Hellstorm helmet
18000000 - Thunder helmet
19000000 - Beastplate of petrified wood
1A000000 - Rib cage
1B000000 - Scales of the greater balilisk
1C000000 - Tunic of the cyclops king
1D000000 - Breastplate of brimstone
1E000000 - Titan's cuirass
1F000000 - Armor of wonder
20000000 - Sandals of the saint
21000000 - Celestial necklace of bliss
22000000 - Lion's shield of courage
23000000 - Sword of judgement
24000000 - Helm of hevenly enlightenment
25000000 - Quiet eye of the dragon
26000000 - Red dragon flame tongue
27000000 - Dragon scale shield
28000000 - Dragon scale armor
29000000 - Dragonbone greaves
2A000000 - Dragon wing tobard
2B000000 - Neckace of dragonteeth
2C000000 - Crown of dragontooth
2D000000 - Still eye of the dragon
2E000000 - Clover of fortune
2F000000 - Cards of prophecy
30000000 - Ladybird of luck
31000000 - Badge of courage
32000000 - Crest of valor
33000000 - Gryph of gallantry
34000000 - Speculum
35000000 - Spyglass
36000000 - Amulet of the undertaker
37000000 - Vampire's cowl
38000000 - Dead men's boots
39000000 - Garniture of interference
3A000000 - Surcoat of counterpoise
3B000000 - Boots of polarity
3C000000 - Bow of elven cherrywood
3D000000 - Bowstring of the unicorns's mane
3E000000 - Angel feather arrows
3F000000 - Bird of perception
40000000 - Stoic watchman
41000000 - Emblem of cognizance
42000000 - Statesmen's medal
43000000 - Diplomat Ring
44000000 - Ambassador's sash
45000000 - Ring of the wayfarer
46000000 - Equestrian's gloves
47000000 - Necklace of ocean guidance
48000000 - Angel wings
49000000 - Charm of mana
4A000000 - Talisman of mana
4B000000 - Mystic orb of mana
4C000000 - Collar of conjuring
4D000000 - Ring of conjuring
4E000000 - Cape of conjuring
4F000000 - Orb of firmament
50000000 - Orb of silt
51000000 - Orb of tempstuous fire
52000000 - Orb of driving rain
53000000 - Recanter's cloak
54000000 - Spirit of opression
55000000 - Hourglass of the evil hour
56000000 - Tome of fire magic
57000000 - Tome of wind magic
58000000 - Tome of water magic
59000000 - Tome of earth magic
5A000000 - Boots of levitation
5B000000 - Golden bow
5C000000 - Sphere of permanence
5D000000 - Orb of vulnerability
5E000000 - Ring of vitality
5F000000 - Ring of life
60000000 - Vail of lifeblood
61000000 - Necklace of swiftness
62000000 - Boots of speed
63000000 - Cape of velocity
64000000 - Pendant of dispassion
65000000 - Pendant of second sight
66000000 - Pendant of holiness
67000000 - Pendant of life
68000000 - Pendant of death
69000000 - Pendant of free will
6A000000 - Pendant of agitation
6B000000 - Pendant of total recall
6C000000 - Pendant of courage
6D000000 - Everflowing cristal cloak
6E000000 - Ring of infinite gems
6F000000 - Everpouring vial of mercury
70000000 - Inexhaustable cart of ore
71000000 - Eversmoking ring of sulfur
72000000 - Inexhaustable cart of lumber
73000000 - Endless sack of gold
74000000 - Endless bag of gold
75000000 - Endless purse of gold
76000000 - Legs of legion
77000000 - Loins of legion
78000000 - Torso of legion
79000000 - Arms of legion
7A000000 - Head of legion
7B000000 - Sea capitan's hat
7C000000 - Spellbinder's hat
7D000000 - Shackles of war
7E000000 - Orb of inhibition

Combo Artefacts:

7F000000 - Dragon's vial of life
80000000 - Armageddon's blade
81000000 - Sword of angelic alliace
82000000 - Cloak of undead king
83000000 - Elixir of life
84000000 - Armor of the dammed - my favourite
85000000 - Statue of legions
86000000 - Power of the dragon father
87000000 - Titans lightning
88000000 - Admiral's hat
89000000 - Archer's bow
8A000000 - Mag's source
8A000000 - City of wealth

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
dimis
dimis


Responsible
Supreme Hero
Digitally signed by FoG
posted July 24, 2006 01:41 AM

At least interesting!

This might be real useful info if you want to test heroes. Thanks for sharing joerginger.
____________
The empty set

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
joerginger
joerginger


Hired Hero
posted July 24, 2006 01:10 PM

Quote:
This might be real useful info if you want to test heroes. Thanks for sharing joerginger.


You're welcome.
It's been quite a while since I played HOMM 3, but I wanted to make sure the list doesn't get lost completely.

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
ShanghaiAlice
ShanghaiAlice

Tavern Dweller
posted November 22, 2015 10:44 AM

I don't know if you are still using this forum but this info is so freaken useful. For a long time, having been offered eagle eye and learning whenever my heroes level up frustrates me to no end, but with a memory editor and knowing what to look for, that is no more.

Being a player that loves their spells way too much, I can't bare to play the campaign "Birth of a barbarian" where freaken Yog just refuses to pick up a spellbook. Being frustrated again reminded me of this post and how you can play god with your heroes. Although I was very disappointed to find that you didn't include the value for a spellbook, I had to experiment a whole bunch because there is no way I can play without spells (to be fair the game is called Heroes of Might and MAGIC.) I was wondering what I would get if I put all zeros in for an artifact, and low and behold, I tabbed back into the game and found a spellbook in my backpack (which is kinda amusing since the thing is impossible to unequipe,) that had me laughing for a good few minutes. Just wanted to reply and let you know that 00000000 is spellbook, useful to know when you don't feel like paying for one, or when your hero's name is Yog (take that Yog, you WILL learn magic whether you like it or not.)

____________

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
potmdehex
potmdehex


Known Hero
professional ERM™ scripter
posted November 22, 2015 04:04 PM

ShanghaiAlice said:

...


Yes, it's interesting that the Spellbook is indeed an artifact like any other. I actually add a spellbook temporarily as a very dirty hack to make the Hero Trade screen refresh after doing a Hero Swap (swapping all artifacts between two heroes) in HDE Mod: code.

On a related note you will notice if you play around editing heroes that all slots, including the Spellbook and Warmachine slots, can hold any artifact.

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
ShanghaiAlice
ShanghaiAlice

Tavern Dweller
posted November 27, 2015 09:21 AM

potmdehex said:
ShanghaiAlice said:

...


Yes, it's interesting that the Spellbook is indeed an artifact like any other. I actually add a spellbook temporarily as a very dirty hack to make the Hero Trade screen refresh after doing a Hero Swap (swapping all artifacts between two heroes) in HDE Mod: [url=https://github.com/potmdehex/homm3tools/blob/master/hd_edition/hde_mod/mod/hero_trade.c#L340]code[/url].

On a related note you will notice if you play around editing heroes that all slots, including the Spellbook and Warmachine slots, can hold any artifact.


yup, I always add artifact at the last misc slot, eventually realized I was wearing things that doesn't go there
____________

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
krebo_gober
krebo_gober

Tavern Dweller
posted May 04, 2016 12:51 PM
Edited by krebo_gober at 12:53, 04 May 2016.

@joerginger. I'm using your list and use it on cheat engine, published on [url=http://lemarine-krebo.blogspot.co.id/2016/05/heroes-chronicles-memory-edit.html]my blog[/url]. If you find it is annoying, then I'll delete it. Thank you.
____________

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
Maurice
Maurice

Hero of Order
Part of the furniture
posted May 04, 2016 01:15 PM
Edited by Maurice at 19:21, 04 May 2016.

I doubt joerginger will mind . His last post on these forums is from february 2007, so that has been a while .

The format detailed above is also the format used inside savegames, by the way, which may allow for easier editing. At least, I find it more convenient to do it offline instead of in memory.

The savegames are all simply zipped archives, so you can open them with something like WinRar and then unzip them. Edit them with a hex editor and you have the various parts as listed in joelgringer's post.

After making the changes you desire, be sure to zip them using 7zip, giving the file a proper extension (.cgm for campaign saves, .gm1 for single player games) instead of the .zip extension. Don't use WinRar for this, it uses a different compression method! Place it in the same folder as your other savegames. My advice would be to give the file a different name, too, so as to not overwrite your original savegame. If you somehow botched the hex editing (not that it ever happened to me *whistles* ), you at least still have the original.

Edit: For personal use, I made a mapping of the various parts of the savegame, especially the Hero section. I'll see about detailing it once I am home.
____________
The last Reasonable Steward of Good Game Design and a Responsible Hero of HC. - Verriker

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
Maurice
Maurice

Hero of Order
Part of the furniture
posted May 04, 2016 07:58 PM

Within Heroes savegames, each Hero will be listed, even Heroes that aren't even available on a given map. The number of bytes te describe each Hero is 1094 and most of these will be taken up by Artifacts.

If a savegame is of a campaign game with carryover Heroes from previous maps, the savegame will contain those carryover Heroes too in a separate section - this means it's possible to have two Hero descriptions within the savegame: the first one is as the Hero has developed up until the start of that particular map, the other as the Hero evolves during that map. The reason to retain those is for when you restart the map later on, or for Heroes that aren't used in that map but rather saved for a later map in the same campaign.

Since the Hero name is the most clearly visible and therefore most easily found within a savegame, I use the first character of a Hero's name as the offset from which to find all the other relevant values. In short (all values are in Little Endian, which means the least significant byte is the first one on the left, increasing in value by a factor of 256 for each next position):


Offsets from    Data type
first letter
of Hero name
-195 .. -194    X coordinate of hero (0 is topleft corner)
-193 .. -192    Y coordinate of hero (0 is topleft corner)
-191            Z coordinate of Hero (0 = surface, 1 = subterranean)
-190 .. -160    ? Unknown, Hero specifics? Portrait, angle, looks?
-159 .. -151    ? Seems to govern Hero specifics; 158 is the Class
-150 .. -147    X coordinate of destination marker)
-146 .. -143    Y coordinate of destination marker
-142 .. -139    ? Seems to depend on level, 0 at lvl 1, 6 at lvl 6 and 20 at lvl 23, all on 3rd byte
-138 .. -135    Maximum movement points
-134 .. -131    Current movement points remaining
-130 .. -127    Experience
-126 .. -123    Number of skill slots shown on the Hero sheet (value from 00 00 00 00 to 08 00 00 00)
-122 .. -121    Mana points
-120            Hero's level
-119 .. -57     ? Temporary buffs ?
-56  .. -29     Creature ID (see Creature ID table; see note 1)
-28  .. -1      Creature amounts (see note 2)
+0   .. +12     Hero name
+13  .. +40     Skill level (see Skill ID table, see note 3)
+41  .. +68     Skill slot on sheet (see note 4)
+69  .. +72     Primary skills (Attack, Defense, Spell Power, Knowledge, in that order - also includes Artifact boni)
+73  .. +212    Spells (see note 5)
+213 .. +876    Artifacts carried (see note 6)


Note 1: This is a range of 7x 4 bytes. Each set of 4 bytes holds the ID of the creature carried by the Hero, in the order as shown on the Hero sheet from left to right. Empty spots have a value of FF FF FF FF, while when there's a creature in the spot, it will show as XX 00 00 00, where XX is the Creature ID.

Note 2: This is a range of 7x 4 bytes as well, corresponding to the same list as under note 1. It holds the total number of creatures for the corresponding position.

Note 3: These 28 bytes each signify one particular skill, depending on the position. So the very first byte in the string is the first skill, the second byte is the second skill, etc ... all the way up to the 28th skill. The skill level has a range of 00 (unskilled) to 03 (Expert level). See the respective skills down below in the Skill table. Note that a Hero could potentially be skilled to Expert level in ALL 28 skills, by just setting these all to 03. They don't need to be shown on the Hero sheet in order to be effective.

Note 4: This string of 28 bytes has a value running from 00 through 08 and has the same follow up order for the skill positions mentioned under note 3. The value indicates where the skill is shown on the Hero sheet, which shows two columns of 4 skill rows each. The topleft position is 1, the top right is 2, etc ... with the bottom right being position 8. The values of 01 through 08 have to be unique within this 28 byte string, since each slot on the Hero sheet can only carry one skill. Keep in mind that the Hero also has an overall number governing how many skills will be shown on the Hero sheet, see the byte at offset -126 ... -123.

Note 5: The Spell listing consists of two strings of 70 bytes each. Each position details one specific spell, just as with the skills detailed under note 3 and 4. See the Spell Table for which spell is at which position. Both 70-byte strings have a value of either 00 or 01 at each byte. The first 70 byte string determines whether the Hero has the specific spell written in his spellbook. The second 70 byte string determines whether the Hero has the spell available in his spellbook - as a spell could be present due to carrying an Artifact (Tome of - Magic, Spell Scroll, Artifact). Logically, spells that are at 01 in the first 70 byte string also have a 01 at the second string .

Note 6: Artifacts carried are 83 strings of 8 bytes each. The first 4 of these 8 bytes are the Artifact ID. See the Artifact ID table for which one is which. The next 4 bytes of those 8 are only used for Spell Scrolls, in which case it lists the Spell ID of the scroll. Otherwise, these 4 bytes have the value FF FF FF FF. The order of these 8 bytes also determines where on the Hero the artifact is shown. Listing those here (and note that some slots are special in that they can only carry one specific artifact, namely the Catapult, First Aid Tent, Ammo Cart, Ballista and Spell Book slots) :


+213 .. +216 Helm slot
+221 .. +224 Cloak slot
+229 .. +232 Neck slot
+237 .. +240 Weapon slot
+245 .. +248 Shield slot
+253 .. +256 Armor slot
+261 .. +264 Left ring slot
+269 .. +272 Right ring slot
+277 .. +280 Boots slot
+285 .. +288 Top side slot
+293 .. +296 Second side slot
+301 .. +304 Third side slot
+309 .. +312 Bottom slot, right
+317 .. +320 Ballista slot*
+325 .. +328 Ammo Cart slot*
+333 .. +336 First Aid Tent slot*
+341 .. +344 Catapult slot*
+349 .. +352 Spellbook slot*
+357 .. +360 Bottom slot, left
+365 .. +368 Inventory slot 1
+373 .. +376 Inventory slot 2
+381 .. +384 Inventory slot 3
+389 .. +392 Inventory slot 4
+397 .. +400 Inventory slot 5
+405 .. +408 Inventory slot 6
+413 .. +416 Inventory slot 7
+421 .. +424 Inventory slot 8
+429 .. +432 Inventory slot 9
+437 .. +440 Inventory slot 10
+445 .. +448 Inventory slot 11
+453 .. +456 Inventory slot 12
+461 .. +464 Inventory slot 13
+469 .. +472 Inventory slot 14
+477 .. +480 Inventory slot 15
+485 .. +488 Inventory slot 16
+493 .. +496 Inventory slot 17
+501 .. +504 Inventory slot 18
+509 .. +512 Inventory slot 19
+517 .. +520 Inventory slot 20
+525 .. +528 Inventory slot 21
+533 .. +536 Inventory slot 22
+541 .. +544 Inventory slot 23
+549 .. +552 Inventory slot 24
+557 .. +560 Inventory slot 25
+565 .. +568 Inventory slot 26
+573 .. +576 Inventory slot 27
+581 .. +584 Inventory slot 28
+589 .. +592 Inventory slot 29
+597 .. +600 Inventory slot 30
+605 .. +608 Inventory slot 31
+613 .. +616 Inventory slot 32
+621 .. +624 Inventory slot 33
+629 .. +632 Inventory slot 34
+637 .. +640 Inventory slot 35
+645 .. +648 Inventory slot 36
+653 .. +656 Inventory slot 37
+661 .. +664 Inventory slot 38
+669 .. +672 Inventory slot 39
+677 .. +680 Inventory slot 40
+685 .. +688 Inventory slot 41
+693 .. +696 Inventory slot 42
+701 .. +704 Inventory slot 43
+709 .. +712 Inventory slot 44
+717 .. +720 Inventory slot 45
+725 .. +728 Inventory slot 46
+733 .. +736 Inventory slot 47
+741 .. +744 Inventory slot 48
+749 .. +752 Inventory slot 49
+757 .. +760 Inventory slot 50
+765 .. +768 Inventory slot 51
+773 .. +776 Inventory slot 52
+781 .. +784 Inventory slot 53
+789 .. +792 Inventory slot 54
+797 .. +800 Inventory slot 55
+805 .. +808 Inventory slot 56
+813 .. +816 Inventory slot 57
+821 .. +824 Inventory slot 58
+829 .. +832 Inventory slot 59
+837 .. +840 Inventory slot 60
+845 .. +848 Inventory slot 61
+853 .. +856 Inventory slot 62
+861 .. +864 Inventory slot 63
+869 .. +872 Inventory slot 64

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
Maurice
Maurice

Hero of Order
Part of the furniture
posted May 04, 2016 07:59 PM

Creature ID's
00 - Pikeman
01 - Halberdier
02 - Archer
03 - Marksman
04 - Griffin
05 - Royal griffin
06 - Swordsman
07 - Crusader
08 - Monk
09 - Zealot
0A - Cavalier
0B - Champion
0C - Angel
0D - Archangel
0E - Centaur
0F - Centaur capitan
10 - Dwarf
11 - Battle dwarf
12 - Wood elf
13 - Grand elf
14 - Pegasus
15 - Silver pegasus
16 - Dendroid guard
17 - Dendroid solider
18 - Unicorn
19 - War unicorn
1A - Green dragon
1B - Gold dragon
1C - Gremlin
1D - Master gremlin
1E - Stone gargoyle
1F - Obsidian gargoyle
20 - Stone golem
21 - Iron golem
22 - Mage
23 - Arch mage
24 - Genie
25 - Master genie
26 - Naga
27 - Naga queen
28 - Giant
29 - Titan
2A - Imp
2B - Familiar
2C - Gog
2D - Magog
2E - Hell hound
2F - Cerberus
30 - Daemon
31 - Horned daemon
32 - Pit fiend
33 - Pit lord
34 - Efreet
35 - Efreet sultan
36 - Devil
37 - Arch Devil
38 - Skeleton
39 - Skeleton Warrior
3A - Walking dead
3B - Zombie
3C - Wight
3D - Wraight
3E - Vampire
3F - Vampire lord
40 - Lich
41 - Power Lich
42 - Black knight
43 - Dead knight
44 - Bone dragon
45 - Ghost dragon
46 - Tryglodyte
47 - Infernal tryglodyte
48 - Harpy
49 - Harpy hag
4A - Beholder
4B - Evil eve
4C - Medusa
4D - Medusa queen
4E - Minotaur
4F - Minotaur king
50 - Manticore
51 - Scorpicore
52 - Red dragon
53 - Black dragon
54 - Goblin
55 - Hobgoblin
56 - Wolf rider
57 - Wolf raider
58 - Orc
59 - Orc chieftain
5A - Ogre
5B - Ogre mage
5C - Roc
5D - Thunderbird
5E - Cyclops
5F - Cyclops king
60 - Behemoth
61 - Ancient behemoth
62 - Gnoll
63 - Gnoll marauder
64 - Lizardman
65 - Lizard warrior
66 - Serpent fly
67 - Dragonfly
68 - Basilisk
69 - Greater Basilisk
6A - Gorgon
6B - Mighty gorgon
6C - Wyvern
6D - Wyvern Monarch
6E - Hydra
6F - Chaos hydra
70 - Air elemental
71 - Earth elemental
72 - Fire elemental
73 - Water elemental
74 - Golem
75 - Diamond golem
76 - Pixies
77 - Sprites
78 - Phychic elemental
79 - Magic elemental
7B - Ice elemental
7D - Magma elemental
7F - Storm elemental
81 - Energy elemental
82 - Firebird
83 - Phoenix
84 - Azure dragons
85 - Crystal dragons
86 - Faeri dragons
87 - Rust dragons
88 - Enchanters
89 - Sharpshooters
8A - Halflings
8B - Peasants
8C - Boars
8D - Mummies
8E - Nomads
8F - Rogues
90 - Trolls

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
Maurice
Maurice

Hero of Order
Part of the furniture
posted May 04, 2016 08:02 PM


Artifacts
00 - Spellbook
01 - Spell scroll*
02 - The Grail
03 - Catapult
04 - Ballista
05 - Ammo Cart
06 - First Aid Tent
07 - Centaur's axe
08 - Blackshard of the dead knight
09 - Greater Gnoll's Fail
0A - Ogre's club of havoc
0B - Sword of Hellfire
0C - Titan's gladius
0D - Shield of the dwarven lords
0E - Shield of the yawning dead
0F - Buckler of the gnoll king
10 - Targ of the rampaging ogre
11 - Shield of the dammed
12 - Sentinel's Shield
13 - Helm of the alabaster unicorn
14 - Skull helmet
15 - Helm of chaos
16 - Crown of the supreme magi
17 - Hellstorm helmet
18 - Thunder helmet
19 - Beastplate of petrified wood
1A - Rib cage
1B - Scales of the greater balilisk
1C - Tunic of the cyclops king
1D - Breastplate of brimstone
1E - Titan's cuirass
1F - Armor of wonder
20 - Sandals of the saint
21 - Celestial necklace of bliss
22 - Lion's shield of courage
23 - Sword of judgement
24 - Helm of hevenly enlightenment
25 - Quiet eye of the dragon
26 - Red dragon flame tongue
27 - Dragon scale shield
28 - Dragon scale armor
29 - Dragonbone greaves
2A - Dragon wing tabard
2B - Neckace of dragonteeth
2C - Crown of dragontooth
2D - Still eye of the dragon
2E - Clover of fortune
2F - Cards of prophecy
30 - Ladybird of luck
31 - Badge of courage
32 - Crest of valor
33 - Gryph of gallantry
34 - Speculum
35 - Spyglass
36 - Amulet of the undertaker
37 - Vampire's cowl
38 - Dead men's boots
39 - Garniture of interference
3A - Surcoat of counterpoise
3B - Boots of polarity
3C - Bow of elven cherrywood
3D - Bowstring of the unicorns's mane
3E - Angel feather arrows
3F - Bird of perception
40 - Stoic watchman
41 - Emblem of cognizance
42 - Statesmen's medal
43 - Diplomat Ring
44 - Ambassador's sash
45 - Ring of the wayfarer
46 - Equestrian's gloves
47 - Necklace of ocean guidance
48 - Angel wings
49 - Charm of mana
4A - Talisman of mana
4B - Mystic orb of mana
4C - Collar of conjuring
4D - Ring of conjuring
4E - Cape of conjuring
4F - Orb of firmament
50 - Orb of silt
51 - Orb of tempestous fire
52 - Orb of driving rain
53 - Recanter's cloak
54 - Spirit of opression
55 - Hourglass of the evil hour
56 - Tome of fire magic
57 - Tome of wind magic
58 - Tome of water magic
59 - Tome of earth magic
5A - Boots of levitation
5B - Golden bow
5C - Sphere of permanence
5D - Orb of vulnerability
5E - Ring of vitality
5F - Ring of life
60 - Vail of lifeblood
61 - Necklace of swiftness
62 - Boots of speed
63 - Cape of velocity
64 - Pendant of dispassion
65 - Pendant of second sight
66 - Pendant of holiness
67 - Pendant of life
68 - Pendant of death
69 - Pendant of free will
6A - Pendant of agitation
6B - Pendant of total recall
6C - Pendant of courage
6D - Everflowing cristal cloak
6E - Ring of infinite gems
6F - Everpouring vial of mercury
70 - Inexhaustable cart of ore
71 - Eversmoking ring of sulfur
72 - Inexhaustable cart of lumber
73 - Endless sack of gold
74 - Endless bag of gold
75 - Endless purse of gold
76 - Legs of legion
77 - Loins of legion
78 - Torso of legion
79 - Arms of legion
7A - Head of legion
7B - Sea capitan's hat
7C - Spellbinder's hat
7D - Shackles of war
7E - Orb of inhibition

(combine artifacts and specials)
7F - vial of dragonblood
80 - Armageddon's blade
81 - angelic alliance
82 - Cloak of undead king
83 - Elixir of life
84 - Armor of the dammed
85 - Statue of legions
86 - Power of the dragon father
87 - Titans lightning
88 - Admiral's hat
89 - Archer's bow

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
Maurice
Maurice

Hero of Order
Part of the furniture
posted May 04, 2016 08:03 PM


Secondary skills
Position and skill at that position
0 Pathfinding
1 Archery
2 Logistics
3 Scouting
4 Diplomacy
5 Navigation
6 Leadership
7 Wisdom
8 Mysticism
9 Luck
10 Ballistics
11 Eagle Eye
12 Necromancy
13 Estates
14 Fire Magic
15 Air Magic
16 Water Magic
17 Earth Magic
18 Scholar
19 Tactics
20 Artillery
21 Learning
22 Offense
23 Armorer
24 Intelligence
25 Sorcery
26 Resistance
27 First Aid

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
Maurice
Maurice

Hero of Order
Part of the furniture
posted May 04, 2016 08:05 PM
Edited by Maurice at 20:08, 04 May 2016.


Spells
Position and which spell
   Spell ID
      Spell name
0  00 Summon Boat
1  01 Scuttle Boat
2  02 Visions
3  03 View Earth
4  04 Disguise
5  05 View Air
6  06 Fly
7  07 Water Walk
8  08 Dimension Door
9  09 Town Portal
10 0A Quick Sand
11 0B Land Mine
12 0C Force Field
13 0D Fire Wall
14 0E Earthquake
15 0F Magic Arrow
16 10 Ice Bolt
17 11 Lightning Bolt
18 12 Implosion
19 13 Chain Lightning
20 14 Frost Ring
21 15 Fireball
22 16 Inferno
23 17 Meteor Shower
24 18 Death Ripple
25 19 Destroy Undead
26 1A Armageddon
27 1B Shield
28 1C Air Shield
29 1D Fire Shield
30 1E Protection from Air
31 1F Protection from Fire
32 20 Protection from Water
33 21 Protection from Earth
34 22 Anti-Magic
35 23 Dispel
36 24 Magic Mirror
37 25 Cure
38 26 Resurrection
39 27 Animate Dead
40 28 Sacrifice
41 29 Bless
42 2A Curse
43 2B Bloodlust
44 2C Precision
45 2D Weakness
46 2E Stone Skin
47 2F Disrupting Ray
48 30 Prayer
49 31 Mirth
50 32 Sorrow
51 33 Fortune
52 34 Misfortune
53 35 Haste
54 36 Slow
55 37 Slayer
56 38 Frenzy
57 39 Titan's Lightning Bolt
58 3A Counterstrike
59 3B Berserk
60 3C Hypnotize
61 3D Forgetfulness
62 3E Blind
63 3F Teleport
64 40 Remove Obstacle
65 41 Clone
66 42 Fire Elemental
67 43 Earth Elemental
68 44 Water Elemental
69 45 Air Elemental

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
Maurice
Maurice

Hero of Order
Part of the furniture
posted May 04, 2016 08:16 PM
Edited by Maurice at 20:21, 04 May 2016.

If you wish to know which spells are contained within the Mage Guild of a given Town but don't feel like building up the Town to the max, you can also find that information within the save game.

Locate the Town Name and taking the first letter as position 0, you can find the Mage Guild spells at these offsets:

+125 .. +148 Tier 1 Mage Guild spells
+149 .. +172 Tier 2 Mage Guild spells
+173 .. +196 Tier 3 Mage Guild spells
+197 .. +220 Tier 4 Mage Guild spells
+221 .. +228 Tier 5 Mage Guild spells


The first four Tiers consist of 6 strings of 4 bytes each, each holding a Spell ID (see the Spell ID table above). Although higher Tiers have ever fewer spells, in the save game they are all 6 slots in size, except Tier 5, which is only 8 bytes long and hence can only contain 2 spells.

Only Tower can benefit from 6 spells are Tier 1, with the Library, all the other Towns are restricted to 5 spells at most. Still, all Towns have the 6th spell listed. Note that the spell slots unavailable to any Town only contain garbage bytes (often 00 00 00 00, but I've also seen other garbage bytes). For instance, the 6th spell slot at Tier 2 and the 5th and 6th spell slot are unavailable for any Town and only contain garbage. They're still there within the savegame file, though. At the same time, even for Towns without a Library (i.e. other than Tower), a valid spell is listed in the slot that can only be accessed with a Library.

Also, for Towns that cap off at a Tier lower than 5 (Stronghold, Fortress and Castle), the unused Tiers contain FF FF FF FF for all spells at those unavailable Tiers.

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
potmdehex
potmdehex


Known Hero
professional ERM™ scripter
posted May 04, 2016 09:04 PM
Edited by potmdehex at 21:53, 04 May 2016.

Good posts, Maurice.

Regarding the hero struct, it is documented in a few places publically online, for example my own here and another more complete one here. It is the same one used in-memory when the game is running.

The spell IDs etc listed are the same in .h3m maps for anyone wondering.

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
Maurice
Maurice

Hero of Order
Part of the furniture
posted May 04, 2016 11:23 PM

Nice links. I've examined them a bit and I do notice similar elements - but also that their follow up order in memory seems different? For instance, I see the Hero name actually preceding destination coordinates. I must say I'm a bit surprised by that, I always assumed the savegames were just memory dumps, but it seems they're getting structured element by element before being written to disk.

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
krebo_gober
krebo_gober

Tavern Dweller
posted May 05, 2016 08:27 PM

Maurice said:
I doubt joerginger will mind . His last post on these forums is from february 2007, so that has been a while .

The format detailed above is also the format used inside savegames, by the way, which may allow for easier editing. At least, I find it more convenient to do it offline instead of in memory.

The savegames are all simply zipped archives, so you can open them with something like WinRar and then unzip them. Edit them with a hex editor and you have the various parts as listed in joelgringer's post.

After making the changes you desire, be sure to zip them using 7zip, giving the file a proper extension (.cgm for campaign saves, .gm1 for single player games) instead of the .zip extension. Don't use WinRar for this, it uses a different compression method! Place it in the same folder as your other savegames. My advice would be to give the file a different name, too, so as to not overwrite your original savegame. If you somehow botched the hex editing (not that it ever happened to me *whistles* ), you at least still have the original.

Edit: For personal use, I made a mapping of the various parts of the savegame, especially the Hero section. I'll see about detailing it once I am home.


Well, thanks Maurice. And your lists is more awesome. I've tried gzip before. And then 7zip. But it needs save and reload. So I give it a try on cheat engine.

But [url=http://blog.yimingliu.com/2007/02/03/hacking-homm-iv-saved-game/]this blog[/url] is the one that made me trying the same thing on heroes 3.
____________

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
RoseKavalier
RoseKavalier


Admirable
Supreme Hero
posted May 06, 2016 06:08 PM

Doesn't such a tool already exist or a you looking to add functionality?

 Send Instant Message | Send E-Mail | View Profile | PP | Quote Reply | Link
krebo_gober
krebo_gober

Tavern Dweller
posted May 07, 2016 06:47 AM

RoseKavalier said:
Doesn't [url=http://heroescommunity.com/viewthread.php3?TID=30459]such a tool[/url] already exist or a you looking to add functionality?


I've tried it on gog version. It doesn't work for me
____________

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
RoseKavalier
RoseKavalier


Admirable
Supreme Hero
posted May 07, 2016 02:48 PM

1) Did you try running it as Administrator?

2) Are you using HDmod? (I read it is not compatible)

 Send Instant Message | Send E-Mail | View Profile | PP | Quote Reply | Link
Jump To: « Prev Thread . . . Next Thread » This thread is 5 pages long: 1 2 3 4 5 · NEXT»
Post New Poll    Post New Topic    Post New Reply

Page compiled in 0.1223 seconds