mulrich wrote: ↑Tue Dec 07, 2021 8:34 am
Lololmaorofl wrote: ↑Mon Dec 06, 2021 6:10 pm
Is there any chance you could possibly make Decisions complete in 1 day? There is no console command for that.
Sadly, those are all determined by their own individual variables and would require extensive modding of game files.
For example, the variable for time to complete for merging Soviet manufacturing plants is called "sov_merge_designers_time".
If you are aiming to get the pointers for every decision you have a problem. As you say, that would require a lot of entries (either modded, or pointers). However, most (if not all) games are object oriented, which might make things a bit easier. So you can find out where it handles ALL decisions, and finish them, either by adding up to a level, or subtracting down to a level.
For decisions, when you start one, you can see in the decisions screen (or the tooltip) how many days are left. If you search for this, you can narrow it down to one value. You now have the "days left until done" for one decision. If you then select it and choose "See what accesses this address" you will get a list of a few entries when the day ends. Among them is this (this is from the 1.11.4 open beta):
Code: Select all
hoi4.exe+4E1547 - FF 4E 18 - dec [rsi+18]
This is the one that decreases the "day left" counter for the decisions.
Just below it is a compare and a jump:
Code: Select all
hoi4.exe+4E1547 - FF 4E 18 - dec [rsi+18]
hoi4.exe+4E154A - 83 7E 18 01 - cmp dword ptr [rsi+18],01 { 1 }
hoi4.exe+4E154E - 0F8D 5E020000 - jnl hoi4.exe+4E17B2
The compare checks if it is 1, and the jump is a "jump if not less", so we can assume we want the [rsi+18] to be less than one. If we change the value to 1 in cheat engine, on the next day it will be 0 and the decision finishes.
Since changing the "dec [rsi+18]" to "set [rsi+18] to 0" would finish all decisions for all countries in a day, we probably want to only do this for the player.
If we check the other register values in that method, we can find that R15 contains the CDecisionStatus structure ("Dissect structure" is our friend), and [R15+10] contains the pointer to the CCountry struct. If [R15+10] is the same as the player ([pPlayer] in Recifenses table) we are probably good to change the "days left" to 0, and decisions are done in a day.