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 5 - Modders Workshop > Thread: Week 2, Day 4 - AI Pondering
Thread: Week 2, Day 4 - AI Pondering
Gidoza
Gidoza


Famous Hero
posted June 04, 2020 07:19 PM

Week 2, Day 4 - AI Pondering

So here's a curious thing.

The game was working well for me for ages (H5.5) and now, suddenly...it isn't.  Consistently, on Week 2, Day 4 of the game, the AI begins pondering and doing nothing at all.

I'm not sure what is special about this day.  Here is the only information that might be pertinent to why this happened.


1.  My computer crashed at one point and weirded itself out even more than just a crash, so maybe something got corrupted?

I completely re-installed everything after this - but I saved the data files in the data folder because I had made some of my own adjustments, and the AI was still pondering.  So if there was corruption - would the data files themselves have become corrupted somehow?


2.  I did some creature adjustments the day before.  This amounted to nothing more than stats changes, so I'm not sure why this would cause it - but I'm noting it because it's something I did.



That's all I got.  Any thoughts at all?

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


Famous Hero
posted June 04, 2020 11:32 PM

Hi everyone - I found the problem.  You'll find this really interesting.

I went through the creature files and narrowed the problem down to one file - Imp.xdb.  Just to be clear - in the files, Imp and Familiar are inverted, so this file actually refers to the upgraded Imp, which is the Familiar.

I went through line by line and found nothing wrong, so I reverted some values back until I un-broke the AI and got the answer.

Here's what's causing the AI to break: if Imp.xdb is given a Gold value of 36, it breaks the game.  I'm not joking.  A value of 37, or 35, or seemingly any other value will work fine - but a value of 36 kills the AI.  What's curious about this is that the same value of 36 Gold used in Quasit.xdb works perfectly fine.

(if you want to know why I was using 36, I was thematically making Inferno have lots of values that end in 6, just for fun)

Can anyone do a test themselves and changing the Gold value of Imp.xdb to 36 and see what happens?  It ALWAYS kills the AI on precisely Week 2, Day 4, after you end your turn.


Any theories on what the heck is happening are most welcome.  I'm not a programmer to be sure, but I know enough programming to say that this doesn't make any intuitive sense to me at all.

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


Hired Hero
posted June 12, 2020 08:52 AM

Heroes 5

Itself was quite buggy, although lots of updates came out since 2006
(guess Nival? was in quite a hurry to finish) I guess this still holds true to this day.

Some speculations that I guess could explain some of the behavior
- low effort pseudo-random generator implementation
- some odd memory storage and type declarations and
- buggy calculations made during function calls
I guess some pointer arithmetic errors are left in the codebase as well.

Not to badmouth the game, but I guess the game had a pretty rough release schedule.

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
Jump To: « Prev Thread . . . Next Thread »
Post New Poll    Post New Topic    Post New Reply

Page compiled in 0.0250 seconds