5. [Sympathy]
Sympathy = 0 if there are no creatures of the same kind as neutrals in hero's army;
Sympathy = 1 if there is at least one creature (or upgrade/downgrade) of the same kind as neutrals in hero's army;
Sympathy = 2 if total number of creatures (or their upgrades/downgrades) of the same kind as neutrals in hero's army are strictly bigger than number of all the other beings in the army;

The notes below are for join calculations only!Note: earth, water and fire elementals don't have upgrades while air ones do!
Note: magma, ice and energy elementals don't have downgrades while storm ones do!

Note: for friendly, aggressive and hostile neutrals Õ is a pseudo-random value which is generated at creation of new game. You can see it when using LM Oracle 3.72 program.

8. if Ch < X neutrals will fight;

9. if Ch >= X there are two cases:
a) if Sympathy + Diplomacy_Level + 1 >= X neutrals will join for free;
b) Only if the first condition is false: if Sympathy + 2 * Diplomacy_Level + 1 >= X neutrals will join for gold provided you have enough money to buy them all (no resources are needed).

Note: if you reject an offer to join monsters:
a) flee (if Ch > X and they CAN flee i.e. they are not set to never flee);
b) take offence and attack (if Ch = X).

Note: on Easy difficult all heroes have a hidden Diplomacy level which is used for join calculations (only?). For example, if your hero has Basic Diplomacy then Diplomacy_Level is two instead of one. Nevertheless, Diplomacy_Level cannot exceed three

Now try to make the same test with 20 AA's of yours vs 10 AA's!
Power_Factor = 2, Ch = 2 + 3 + 2 = 7.
In this case you will never join neutrals with X > 7.
If X = 7, for example, you will never join them for free as well (6 >= 7 is false) but you easily join them for gold (9 >= 7 is true)!

Monster aggression can be set from 0 to 10 in the editor.
--------------------------------------------------------------------------------

Interesting:

First the Heroes Strengh will be Calculated. Primary Skills Attack and Defense do have a slight influence to the outcome (While people thought Diplomancy on a MAIN hero is a lost skill, let a scout do it).

The Calculated Heroes Strengh raise the Army Strength. The Army Strengh will be compared with Monster Army Strengh by dividing it.

The Comparison will leed to penalties:

50% =-1 33%=-2 even weaker -3

I assume that diplomcy skill is plus 2 per level. I assume that The UniteBonus (for the same alignment) is plus 1.

The if else routine shows the decision calculation. If the agression setting is higher then AmryStrenghPenalty + Diplo +Alignment the result is Join().

Other options are Attack, MoneyJoin or Flee.

The creatures can be set from 0 to 10. I assume that the creature settings can vary between two points (like 2 or 3).
____________

--------------------------------------------------------------------------------
...well its an "unconfirmed information from an unknown source"...thats why i put it in question marks - open for discussion.

If you go through the lines it looks all logic and suits to game experiences.

I thought it would be interesting, thats why i posted it here.

Xarfax1

Maybe the aggression level vary between two number per level on a random basis. Like 0-1 2-3 4-5 5-6 7-8 9-10. Plus if aggression is 0, it wont be calculated = always join.

Which other influences do you think are involved? Maybe we can test that.

@Dimis: Thanks for your comment, wouldve been nice to see results of a hardcore tester. You are one of the few peeps -like Maretti, Binabik and Angelito -why im still visiting this site.

@Demarest: There is a txt-file for AI calculations extracted from the lod files of H3. There is a list of all creature points. When i remember correct its called CreatureTraits.txt. Maybe someone can publish it here. Would be cool to see some testings from you.

If you are interested in diplomacy internal, you might also like this program (x64 only).

Start the HoMM III (3.2, 4.0 and HotA 1.3.3 are supported so far), load a savegame or start a new game. Start the program, choose your game version (Options -> Version), press the "Start" button, right-click on the grid and add some heroes. Double-click on a hero's name to start the "Adventure Oracle" and hover the mouse over monsters to see if they would like to join your army (all the variables are desribed in this thread). You can also double-click on a hero's number to see his level-up tree. To change depth of calculations choose "Options -> Skill Tree Depth". Have fun

About Sympathy: I had an hero with just 75 giants and was trying to get a stack of Titans, on the way 118 cerberi joined (so way less then the strength of giants...).
Without the cerberi they would join for money, with them they flee. So there is a forth degree of sympathy, to have only those creatures in army.

In the above case with 75 giants you had the "army consists mostly of giants" bonus. When you took dogs, your army didn't consist mostly of giants any more, because only the number of units matter. The strength doesn't matter. If you took 76 peasants you would lose the bonus.