As a French person I feel like it's my duty to explain strikes to you. - AdrienIer

Create an account  

 
ds:-76F8

Th array at ds:-76F8 seems to be where the AI stores the selected action for stacks of units it has.
Problem is I have no idea which value means what action.
Anyone knows?
Reply

We did some investigation on action codes.
See for instance: http://realmsbeyond.net/forums/showthrea...#pid284476
You mean those?

I think I have a more expansive listing somewhere.
--I like ILSe
Reply

(October 22nd, 2015, 11:07)I like Serena Wrote: We did some investigation on action codes.
See for instance: http://realmsbeyond.net/forums/showthrea...#pid284476
You mean those?

Nope, this is overland and I assume it is for stacks of units, not individual units. It's an array of 3Ch(60) elements per wizard.
Valid values seem to be 0-6 or something around that.
An example where it is used is E9756h.

It comes with several other related arrays of same structure at different addresses, 7734h and 7770h being X and Y coordinates, probably the location of the unit stack. There might be more but there are so many variables and arrays related to overland movement that it's really hard to make progress.

I still try to figure out how to make those units stuck guarding a node actually participate in the game. Sky Drakes and heroes carrying 3 artifacts being locked to a node doing nothing no matter what is just wrong.


btw, about those combat ones you mention, I've added 0x99h for "stay idle" in my mod because there wasn't one for that and I really needed sprites to not melee my 10 times stronger troops smile
Sadly it still gets overruled by the AI every once in a blue moon but 90% of the time flying units now avoid getting themselves hurt if the other side has an overwhelming advantage.

oh, and a question do you know if Kryub had any good reason for the changes I found and posted here?
http://realmsbeyond.net/forums/showthread.php?tid=7846

He actually lowered the priority of "War" targets compared to "nonwar" ones and also made the AI consider player units 4 times weaker than units of any other possible target...at least that's how I interpret the code, but still haven't found where and how those priorities are used.

Also, if you are interested, one thing I did find out.
[bx-636Ch] refers to a matrix which contains the calculated army strength on every map cell, encounter zones included (and the topmost two bits are flags which I assume are "Need to defend this location" and "controlled by ally" or something similar)
Reply

I guess you mean ds:8908, but no, I have no information about what's there, nor about those X and Y coordinates.
As for Kyrub's changes, I have no idea either.
--I like ILSe
Reply

(October 22nd, 2015, 12:36)I like Serena Wrote: I guess you mean ds:8908, but no, I have no information about what's there, nor about those X and Y coordinates.
As for Kyrub's changes, I have no idea either.

yep +8909 or -76F8, I prefer the negative as it appears many times more often that way in the code.
Too bad, he really is keeping everything a secret frown

I've started a new game with some changes, most importantly removing the 0.25 multiplier for human player army strength, I wonder if it'll have any noticeable effect.
Not very lucky for testing purpose, but at turn 50 I'm yet to make contact with any wizard. Maybe they're all on Myrror or something, I wonder. I even had to go to the new game menu to check if I properly selected 4 opponents.
Reply



Forum Jump: