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 > Heroes 3.5 - WoG and Beyond > Thread: Heroes 3 Hacking Reference Guide
Thread: Heroes 3 Hacking Reference Guide This thread is 42 pages long: 1 ... 9 10 11 12 13 ... 20 30 40 42 · «PREV / NEXT»
FfuzzyLogik
FfuzzyLogik


Known Hero
posted April 11, 2021 05:50 PM
Edited by FfuzzyLogik at 20:23, 11 Apr 2021.

I thought se same formula was used for spell's specialists. I just calculate the result of the modifications on them...
But that was not the point of this modification, the goal was to place "creature specialist over level 2 creature" - decent champions.

Some other idea (maybe more simple) might be to change :
Bonus = (HLv + CrLv)/(CrLv+1)
Hlv = Hero level ; CrLv = Creature level

The bonus for attack and defense for creatures will be :
CrLv1 - Hlv1 : 10,0% - HLv2 : 15,0% - Hlv3 : 20,0% - HLv4 : 25,0% - HLv5 : 30,0% - HLv10 : 55,0% - HLv15 : 80,0% - HLv20 : 105%
CrLv2 - Hlv1 : 7,50% - HLv2 : 10,0% - Hlv3 : 12,5% - HLv4 : 15,0% - HLv5 : 17,5% - HLv10 : 30,0% - HLv15 : 42,5% - HLv20 : 55%
CrLV3 - Hlv1 : 6,67% - HLv2 : 8,33% - Hlv3 : 10,0% - HLv4 : 11,7% - HLv5 : 13,3% - HLv10 : 21,7% - HLv15 : 30,0% - HLv20 : 38,3%
CrLv4 - Hlv1 : 6,25% - HLv2 : 7,50% - Hlv3 : 8,75% - HLv4 : 10,0% - HLv5 : 11,3% - HLv10 : 17,5% - HLv15 : 23,8% - HLv20 : 28,3%
CrLv5 - Hlv1 : 6,00% - HLv2 : 7,00% - Hlv3 : 8,00% - HLv4 : 9,00% - HLv5 : 10,0% - HLv10 : 20,0% - HLv15 : 25,0% - HLv20 : 30%
CrLv6 - Hlv1 : 5,83% - HLv2 : 6,67% - Hlv3 : 7,50% - HLv4 : 8,33% - HLv5 : 9,17% - HLv10 : 13,3% - HLv15 : 17,5% - HLv20 : 21,7%
CrLv7 - Hlv1 : 5,70% - HLv2 : 6,40% - Hlv3 : 7,10% - HLv4 : 7,90% - HLv5 : 8,60% - HLv10 : 12,0% - HLv15 : 16,0% - HLv20 : 19%

Last idea I have to try to change this is "decreasing the dvisor"
Here if this change is done, you must not use level 1 creature specialist with this 5% bonus.
To explain to other readers, CrLv is written 0 for level 1 ; 1 for level 2... I'll write CrLv* for this value.
Bonus (normal) = 5% x (HLv-CrLv)/(CrLv* + 1)
Bonus (for this idea) = 5% x (HLv-CrLv)/(CrLv* / 2)

This calculation will globally do :
CrLv1 : division /0 => Bug
CrLv2 : 10% stats/level (very strong)
CrLv3 : 5% stats/level
CrLv4 : 3,33% stats/level
CrLv5 : 2,5% stats/level
CrLv6 : 2% stats/level
CrLv7 : 1,67% stats/level

And when I wrote this, I was thinking... If there are some spell specialists and if the same calculation is used... It will cause bug if you cast a spell on level 1 creature... But values looked very cool for level 2-6 !
____________
FfuzzyLogik.

If I'm crazy ? Sure, because its madness to be normal...

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


Legendary Hero
Heroes is love, Heroes is life
posted April 14, 2021 08:34 AM
Edited by Phoenix4ever at 08:37, 14 Apr 2021.

BTB do you think it would be possible to give Black Dragons mind spell immunity + 100% spell damage (golem) resistance? (Or 95% like Diamond Golems, if that is max.)

Not sure about Gold Dragons, they do have that nasty Implosion vulnerability, so they should perhaps have a bit lower damage resistance, like 80%.

Not sure if the above would be OP, but it would of course be nice to be able to resurrect them, Dungeon and Rampart heroes being able to use their spell specialties on them and still (mostly) retaining that Armageddon potential.

At the moment I have both of them immune to mind spells + Lightning Bolt, Chain Lightning and Armageddon, but there might be a better solution... (I would also like to add Ice Bolt, Frost Ring and Meteor Shower to the above, but it does'nt seems like it's possible to combine these elemental resistances.)

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


Famous Hero
Moist & Creamy
posted April 14, 2021 02:52 PM
Edited by BTB at 14:56, 14 Apr 2021.

Phoenix4ever said:
BTB do you think it would be possible to give Black Dragons mind spell immunity + 100% spell damage (golem) resistance? (Or 95% like Diamond Golems, if that is max.)


Yeah, that's pretty much exactly what I suggest in the (recently updated) guide. I wouldn't recommend 100% resistance simply because the AI will still attempt to cast spells on something with damage resistance so it would be kinda broken to have them cast completely ineffectual spells.

Phoenix4ever said:
At the moment I have both of them immune to mind spells + Lightning Bolt, Chain Lightning and Armageddon, but there might be a better solution... (I would also like to add Ice Bolt, Frost Ring and Meteor Shower to the above, but it does'nt seems like it's possible to combine these elemental resistances.)


It's certainly possible, it's just a matter of whether or not you can do it inline or not. The code for "check this spell, and then this spell, and then this spell..." is very straightforward, you're just gonna need some free space if you want to move beyond the example the guide gives.

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


Legendary Hero
Heroes is love, Heroes is life
posted April 14, 2021 05:21 PM
Edited by phoenix4ever at 17:23, 14 Apr 2021.

Yeah I thought a bit more about it and 100% or 80% spell damage resistance would also be way too much, especially since Orb of Vulnerability can not remove spell damage resistance, unlike their normal resistances.
If AI will still attempt to cast damaging spells on them, that's also a bit stupid.
Golems have spell damage resistance, but they are also slow, can't get morale, can't be resurrected, does'nt have breath weapon and can't fly, so this feature is probably best left for golems only.

If you have any idea how to make Black and Gold Dragons immmune to mind spells, Lightning Bolt, Chain Lighting, Armageddon + Ice Bolt, Frost Ring and Meteor Shower, that would be great.

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


Famous Hero
Moist & Creamy
posted April 14, 2021 06:15 PM

phoenix4ever said:
If you have any idea how to make Black and Gold Dragons immmune to mind spells, Lightning Bolt, Chain Lighting, Armageddon + Ice Bolt, Frost Ring and Meteor Shower, that would be great.


First you have to decide on which of these you're going to use:

00 = 20% magic resist
01 = 40% magic resist
02 = Immune to lv. 1-3 spells
03 = Immune to lv. 1-4 spells
04 = Immune to ALL spells
05 = Immune to Meteor Shower
06 = Immune to Lightning
07 = Immune to Ice

At least one of them is going to have to be repurposed. And unless you repurpose them ALL, you'll need some free space. So your first step is going to be deciding where to find that space. I make several suggestions in my guide for places to get it; the Armor of the Damned is probably a good bet since I don't imagine you're interesting in nuking Eagle Eye or the Aurora Borealis effect.

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


Legendary Hero
Heroes is love, Heroes is life
posted April 14, 2021 07:35 PM
Edited by Phoenix4ever at 19:36, 14 Apr 2021.

Well actually I don't currently use the grail, so I guess it would be okay to overwrite some of those.
Gold and Black Dragons already have the 06 code for lightning and arma immunity, but I need to add 05 and 07 then.
But how will the game know that former grail data now has to do with dragons resistances?

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


Famous Hero
Moist & Creamy
posted April 14, 2021 08:04 PM
Edited by BTB at 20:09, 14 Apr 2021.

Phoenix4ever said:
But how will the game know that former grail data now has to do with dragons resistances?


By changing the exit pointer for the relevant resistance. Assuming we're using the one or lightning immunity, that would be:

04A64C: 0A A5 44 00 -> 48 E8 5C 00

And then at 1CE842:

0F 84 8E 00 00 00 ; skip Aurora Borealis right-click code block

8B 45 F0 ; move spell ID into EAX

83 F8 1A ; is spell Armageddon?
74 21 ; if yes, jump to immunity

83 F8 17 ; is spell Meteor Shower?
74 1C ; if yes, jump to immunity

83 F8 10 ; is spell Ice Bolt?
74 17 ; if yes, jump to immunity

83 F8 14 ; is spell Frost Ring?
74 12 ; if yes, jump to immunity

83 F8 11 ; is spell Lightning Bolt?
74 0D ; if yes, jump to immunity

83 F8 13 ; is spell Chain Lightning?
74 08 ; if yes, jump to immunity

83 F8 4C ; is spell Thunder (ability)?

E9 XX XX XX XX ; if no, then exit(*)

D9 05 64 AC 63 00 ; immunity
5F ; ""
5E ; ""
5B ; ""
8B E5 ; ""
5D ; ""
C2 08 00 ; return

(*this is a jump and I can't calculate the destination here at work)

---

Dunno how much of the guide you've seen since I updated it, but I specifically talk about exit pointers in the skills section:

Quote:
Another learning point here is how to find the exit pointers on a jump table - in other words, where we
go to depending on what value we find when we look up the spell/creature/whatever we have on the table.
If we look right before this table in the code, we will find 7 DWORD pointers (starting at 0E633C) that
direct us where to go for spell bonuses of 0, 1, 2, 3, 4, 5, and 6, respectively.

Say, for example, that we want to repurpose the Fortune bonus as a secondary static bonus (i.e. type 3).
The fifth DWORD pointer in the list - the exit for the Fortune bonus - is CA 62 4E 00. Remembering that
DWORD pointers are written backwards and runtime will offset all addresses by 400000, this points us to
0E62CA, where we find the code for the Fortune bonus. Looking at the other exits, we see that the next
highest one is actually 00: DB 62 4E 00 (0E62DB). We can thus conclude that the Fortune bonus code ends
just before this, which is confirmed by the C2 OC 00 (Return opcode) at 0E62D8.

Now, we need to get the code for a static bonus by following the fourth exit pointer to 0E62E5:

   B8 02 00 00 00 5E 8B E5 5D C2 0C 00

This code is substantially shorter than the Fortune bonus code, which is good because it means we won't
need to use any extra space for this change. Copy this hex string over to the Fortune bonus routine at
0E62CA, replacing the second byte (02) with the desired value for the new static bonus. Finally, replace
the remainder of the old Fortune bonus code with 90's like so:

0E62CA: B8 XX 00 00 00 5E 8B E5 5D C2 0C 00 90 90 90 90 90

While NOP'ing out the rest of the unused (and now partially-overwritten) code is not strictly necessary,
it's a good habit to get into moving forward as spaghetti code is generally frowned upon.

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


Legendary Hero
Heroes is love, Heroes is life
posted April 14, 2021 08:51 PM

Hmm seems a bit complicated, but thanks so far.

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


Known Hero
posted April 20, 2021 09:31 PM

I cannot get this to work, tried fresh install, everything. Everything else works great.


REDWOOD OBSERVATORY & PILLAR OF FIRE
------------------------------------
Their effective radii (both 20 tiles) are specified at 0A9673 and 0A96EF, respectively.

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


Famous Hero
Moist & Creamy
posted April 20, 2021 11:38 PM

purerogue said:
I cannot get this to work, tried fresh install, everything. Everything else works great.


REDWOOD OBSERVATORY & PILLAR OF FIRE
------------------------------------
Their effective radii (both 20 tiles) are specified at 0A9673 and 0A96EF, respectively.


Is this with HotA?

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


Known Hero
posted April 20, 2021 11:46 PM
Edited by purerogue at 23:49, 20 Apr 2021.

BTB said:
purerogue said:
I cannot get this to work, tried fresh install, everything. Everything else works great.


REDWOOD OBSERVATORY & PILLAR OF FIRE
------------------------------------
Their effective radii (both 20 tiles) are specified at 0A9673 and 0A96EF, respectively.


Is this with HotA?


Regular homm3HDmod(non-official)..

I need to nix them a bit to make scouting in fashion again

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


Famous Hero
Moist & Creamy
posted April 21, 2021 12:12 AM

I'll have look, then. Thanks!

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


Known Hero
posted April 21, 2021 12:25 AM

BTB said:
I'll have look, then. Thanks!


No, thanks is all mine.

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


Famous Hero
Moist & Creamy
posted April 24, 2021 03:36 AM

Stumbled across something while I was looking for something else... the 5% scaling per level for skill specialties look like they can be edited independently at the following addresses:

Mysticism 0E41FE = E4 EA 63 00 (0.05)
Archery 0E4420 = E4 EA 63 00 (0.05)
Logistics 0E4F1E = E4 EA 63 00 (0.05)
Scouting 0E432E = E4 EA 63 00 (0.05)
Diplomacy 0E483C = E4 EA 63 00 (0.05)
Leadership 0E3C81 = E4 EA 63 00 (0.05)
Luck 0E3A2B = E4 EA 63 00 (0.05)
Eagle Eye 0E46E0 = E4 EA 63 00 (0.05)
Necromancy 0E3F92 = E4 EA 63 00 (0.05)
Estates 0E464F = E4 EA 63 00 (0.05)
Learning 0E4AF9 = E4 EA 63 00 (0.05)
Offense 0E4569 = E4 EA 63 00 (0.05)
Armorer 0E45C9 = E4 EA 63 00 (0.05)
Resistance 0E499C = E4 EA 63 00 (0.05)
First Aid 0E4BD9 = E4 EA 63 00 (0.05)

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


Legendary Hero
Heroes is love, Heroes is life
posted April 24, 2021 08:12 AM

Very interesting...
I currently have all skill specialists at 3% per level, but perhaps some of the worst ones could return to 5% or 4% per level.

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


Known Hero
posted April 24, 2021 08:04 PM
Edited by purerogue at 20:28, 24 Apr 2021.

brb going to try the leadership and luck specialities, see if they work

lol it works.. it displays "+1 Temporary until next battle"
It's a lvl3 Sylvia with spec. set to leadership and multiplier given above set to 0.2, with advance leadership only.

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


Legendary Hero
DoR Modder
posted April 24, 2021 08:24 PM

So you finally found them....

@purerogue
They're some of the trashiest specialties in the whole game. IIRC, they boost the skill, but only up to Expert level odds.
____________
"Goblins use pistols because a shotgun recoil would kick them off the ground flying."
The Reckoning.... it's drawing near....

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


Known Hero
posted April 24, 2021 08:30 PM

FirePaladin said:
So you finally found them....

@purerogue
They're some of the trashiest specialties in the whole game. IIRC, they boost the skill, but only up to Expert level odds.


Only if you accept the limit of 3 for each. Just set it to 9 or something like the guide shows you.

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


Famous Hero
Moist & Creamy
posted April 25, 2021 12:53 AM

purerogue said:
brb going to try the leadership and luck specialities, see if they work

lol it works.. it displays "+1 Temporary until next battle"
It's a lvl3 Sylvia with spec. set to leadership and multiplier given above set to 0.2, with advance leadership only.


I'm gonna dig around some more and see if I can maybe change the mult to an add somewhere and make it a static bonus instead.

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


Known Hero
posted April 25, 2021 02:19 AM

@BTB

while you're at it, what do you think about this:
A "Oppression" specialist that acts like the artifact, and a "Evil Hour" hero that kills luck..(also the illusive the negative luck effect) which would work real well as a counter to mega-leadership and luck specialists, while being limited to that.

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
Jump To: Next Thread » This thread is 42 pages long: 1 ... 9 10 11 12 13 ... 20 30 40 42 · «PREV / NEXT»
Post New Poll    Post New Topic    Post New Reply

Page compiled in 0.0639 seconds