Auto-translated
Ballista Killer for Heroes of Might & Magic III, version 2.0
Let's consider the following situation in battle mode: the player has 1 fairy in their army. They also have a ballista. They attack 100 zombies.
Theoretically, it is possible to win this battle. But in practice, it will take too much time.
A program designed to help solve this problem will be described and released below. The program description will be based on the example above.
This program can move the mouse cursor to the desired location on the battlefield and also click on the battlefield at the desired time.
Description.
Buttons:
Test - allows you to run 1 iteration for testing.
Exit - immediately exits the program.
Fight - starts the battle with the specified number of rounds (Rounds to pause).
Screenshots of the battle are created in the program's location after a specified number of rounds
(to enable screenshot creation, check the box in the CopyScreen after field).
A screenshot is also created during testing.
At the bottom, below the buttons, there are fields CurrentX and CurrentY.
They will help you quickly determine the desired screen coordinates (cursor position).
The Rounds to pause field indicates the number of battle rounds
during which the mouse will be controlled by the program.
After this number of rounds, the program will stop.
Pay attention when setting delays: the time is specified in milliseconds (1 s = 1000 ms).
Let's say we have a fairy + peasant + ballista vs. zombies. Let's assume our game cycle starts with the fairy.
Turn 1. The fairies will presumably run away from the zombies, after which the turn will pass to the zombies, and they will rush towards the fairies. And only then will the turn pass to the peasants. But before the turn reaches the peasants, you need to have time to move the fairies and zombies, which will take about 1-3 seconds.
Therefore, it is recommended to initially set all delays to at least 3000 ms during the testing phase.
After successful testing, the delays can be reduced.
Updates:
1) Now screenshots are only made of the Heroes window (in windowed mode).
2) The "Settings" and "?" buttons have appeared.
The "Settings" button currently only contains the version of Heroes you are running (H3 Rus/Eng, H4 Rus/Eng+, default is H3 Rus).
3) Another attempt has been made to prevent the program from "freezing". When you press the Esc key, the program will complete the current cycle and offer to stop. To stop prematurely, it is recommended to press and hold the Esc key until the corresponding message appears.
4) A hotkey has been added to immediately terminate the application: +Q.
5) Before starting, a message is displayed about the estimated program execution time.
6) A window has been added that displays the program's performance statistics.
7) The number of steps for one cycle has been increased to 14!
Attention!
It is not recommended to use the mouse while the program is running.
You can turn off the monitor during the battle; screenshots will be created!
In the current version of the program, you can perform 14 cursor movements:
1-6, followed by 7 - clicking the left mouse button (MoveTo + Click);
The 7th movement does not perform a mouse button click (only MoveTo);
It was developed to view the number of shots of the ballista, but, as it turned out later,
the number of shots of the ballista can only be viewed by clicking the right mouse button;
8-13 movements, similar to 1-6;
The 14th movement is similar to the 7th.
P.S. The program only works in Heroes windowed mode (F4 key in the game).
If you are going to allow the program to take screenshots,
remember that there must be enough free space on the disk.
For a resolution of 800 x 600 (and the Heroes window has exactly this resolution), a *.bmp file takes up about 1 MB.
For a battle of 5000 rounds and one screenshot every 100 rounds
you will need about 50 MB of free disk space.
Let's consider the following situation in battle mode: the player has 1 fairy in their army. They also have a ballista. They attack 100 zombies.
Theoretically, it is possible to win this battle. But in practice, it will take too much time.
A program designed to help solve this problem will be described and released below. The program description will be based on the example above.
This program can move the mouse cursor to the desired location on the battlefield and also click on the battlefield at the desired time.
Description.
Buttons:
Test - allows you to run 1 iteration for testing.
Exit - immediately exits the program.
Fight - starts the battle with the specified number of rounds (Rounds to pause).
Screenshots of the battle are created in the program's location after a specified number of rounds
(to enable screenshot creation, check the box in the CopyScreen after field).
A screenshot is also created during testing.
At the bottom, below the buttons, there are fields CurrentX and CurrentY.
They will help you quickly determine the desired screen coordinates (cursor position).
The Rounds to pause field indicates the number of battle rounds
during which the mouse will be controlled by the program.
After this number of rounds, the program will stop.
Pay attention when setting delays: the time is specified in milliseconds (1 s = 1000 ms).
Let's say we have a fairy + peasant + ballista vs. zombies. Let's assume our game cycle starts with the fairy.
Turn 1. The fairies will presumably run away from the zombies, after which the turn will pass to the zombies, and they will rush towards the fairies. And only then will the turn pass to the peasants. But before the turn reaches the peasants, you need to have time to move the fairies and zombies, which will take about 1-3 seconds.
Therefore, it is recommended to initially set all delays to at least 3000 ms during the testing phase.
After successful testing, the delays can be reduced.
Updates:
1) Now screenshots are only made of the Heroes window (in windowed mode).
2) The "Settings" and "?" buttons have appeared.
The "Settings" button currently only contains the version of Heroes you are running (H3 Rus/Eng, H4 Rus/Eng+, default is H3 Rus).
3) Another attempt has been made to prevent the program from "freezing". When you press the Esc key, the program will complete the current cycle and offer to stop. To stop prematurely, it is recommended to press and hold the Esc key until the corresponding message appears.
4) A hotkey has been added to immediately terminate the application: +Q.
5) Before starting, a message is displayed about the estimated program execution time.
6) A window has been added that displays the program's performance statistics.
7) The number of steps for one cycle has been increased to 14!
Attention!
It is not recommended to use the mouse while the program is running.
You can turn off the monitor during the battle; screenshots will be created!
In the current version of the program, you can perform 14 cursor movements:
1-6, followed by 7 - clicking the left mouse button (MoveTo + Click);
The 7th movement does not perform a mouse button click (only MoveTo);
It was developed to view the number of shots of the ballista, but, as it turned out later,
the number of shots of the ballista can only be viewed by clicking the right mouse button;
8-13 movements, similar to 1-6;
The 14th movement is similar to the 7th.
P.S. The program only works in Heroes windowed mode (F4 key in the game).
If you are going to allow the program to take screenshots,
remember that there must be enough free space on the disk.
For a resolution of 800 x 600 (and the Heroes window has exactly this resolution), a *.bmp file takes up about 1 MB.
For a battle of 5000 rounds and one screenshot every 100 rounds
you will need about 50 MB of free disk space.