Instant Max Nemesis Option
I've enjoyed using fantomas's "Get Total Player Faction Points" (friendly factions set instantly to revered when encountered) option, so if this might be of use to anyone I've adjusted fantomas's "Get Total Player Faction Points" option slightly into two other options - one only sets enemies instantly to Nemesis status separately from the friendly faction, the other sets enemies Nemesis in combination with his friendly factions being made Revered option.
I had altered his option's code in the past to change the status of any NPCs nearby to me between friendly and enemy on the fly and finally looked to see if it could just be made to turn all enemies instantly to Nemesis status at the same time as setting friendly to Revered.
After finally looking more into and now properly understanding how the "je" (jump if equal), "jl" (jump if lower) and "jg" (jump if greater) work with jumping to and executing the code in other label sections based on the results of the compare function, I saw it was only a single letter in his code (and the value to set the faction to) that needed to be changed to turn all enemies to Nemesis.
However, then I realized that the same address seemed to control both so I made the changes to affect both friendly and enemy factions in one option and then also split off the enemies set to Nemesis as its own option (still only one option can be selected as active at a time).
- First option is fantomas's same option. It is unchanged other than its option name (I just renamed it to better denote what it does compared to the names I gave these other options).
Code: Select all
//Game: Grim Dawn + All DLC's
//Version: v1.1.7.2-v1.1.9.1 (x64)
//Original code by "fantomas", altered slightly by "StinVec"
//NOTE: "Eldritch Horrors" faction
// If you encounter "Eldritch Horrors" for the first time in The Forgotten Gods map then they will
// most likely be properly set to Nemesis when they are added to your faction list.
//
// However, if you encounter them prior to going into the FG expansion map and instead encounter them first
// at the "Forsaken Eldritch Totem" in the end dungeon of the secret "The Hidden Path" quest line, they MAY
// get mistakenly set to Revered when they are added to your faction list and become unable to be attacked.
//
// If this happens and you cannot attack the spawned totem monsters, to force them to be Nemesis:
// - Pause the game while you are near the Eldritch Horror enemies and disable the faction option
// - Edit this code and add // at the far left of the "jg code" line below (line 35) and hit OK
// - Re-enable the option, return in-game, unpause and hit 'J' to see your faction reputations
// If they are now set properly to Nemesis status:
// - Hit pause again and disable the faction option
// - Remove the added // marks and re-enable the option
// - Continue playing as normal
[ENABLE]
aobscanmodule(isFriend,Game.dll,F3 0F 10 44 82 08 0F 2E C6 75 * 8B D1)
alloc(newmem,$100,isFriend)
alloc(factionIndex,8)
registersymbol(factionIndex)
label(code)
label(return)
newmem:
movss xmm0,[rdx+rax*4+08]
movss [factionIndex],xmm0
cmp [factionIndex],0
jg code
mov [rdx+rax*4+08],(float)-20000
movss xmm0,[rdx+rax*4+08]
jmp return
code:
movss xmm0,[rdx+rax*4+08]
jmp return
isFriend:
jmp newmem
nop
return:
registersymbol(isFriend)
[DISABLE]
isFriend:
db F3 0F 10 44 82 08
unregistersymbol(isFriend)
unregistersymbol(factionIndex)
dealloc(factionIndex)
dealloc(newmem)
Code: Select all
//Game: Grim Dawn + All DLC's
//Version: v1.1.7.2-v1.1.9.1 (x64)
//Original code by "fantomas", altered slightly by "StinVec"
//NOTE: "Eldritch Horrors" faction
// If you encounter "Eldritch Horrors" for the first time in The Forgotten Gods map then they will
// most likely be properly set to Nemesis when they are added to your faction list.
//
// However, if you encounter them prior to going into the FG expansion map and instead encounter them first
// at the "Forsaken Eldritch Totem" in the end dungeon of the secret "The Hidden Path" quest line, they MAY
// get mistakenly set to Revered when they are added to your faction list and become unable to be attacked.
//
// If this happens and you cannot attack the spawned totem monsters, to force them to be enemies/Nemesis:
// - Pause the game while you are near the Eldritch Horror enemies and disable the faction option
// - Edit this code and change "25000" on line 36 below to "-20000" and hit OK
// - Re-enable the option, return in-game, unpause and hit 'J' to see your faction reputations
// If they are now set properly to Nemesis status:
// - Hit pause again and disable the faction option
// - Change "-20000" back to "25000" and re-enable the option
// - Continue playing as normal
[ENABLE]
aobscanmodule(isFriend,Game.dll,F3 0F 10 44 82 08 0F 2E C6 75 * 8B D1)
alloc(newmem,$100,isFriend)
alloc(factionIndex,8)
registersymbol(factionIndex)
label(code)
label(return)
newmem:
movss xmm0,[rdx+rax*4+08]
movss [factionIndex],xmm0
cmp [factionIndex],0
jl code
mov [rdx+rax*4+08],(float)25000
movss xmm0,[rdx+rax*4+08]
jmp return
code:
mov [rdx+rax*4+08],(float)-20000
movss xmm0,[rdx+rax*4+08]
jmp return
isFriend:
jmp newmem
nop
return:
registersymbol(isFriend)
[DISABLE]
isFriend:
db F3 0F 10 44 82 08
unregistersymbol(isFriend)
unregistersymbol(factionIndex)
dealloc(factionIndex)
dealloc(newmem)
I also updated the 'option framework' in this attached table version of these options to what I'm currently using with nested Activate All groups and then a "Master" Activate All group if this might also be of use to anyone. fantomas's options can just be copied/pasted or dragged/dropped into the different sections as you would like.
_____
One Possible Issue:
As noted in my script notes in the codes above, an odd situation could result with the Eldritch Horrors enemy where they could be mistakenly set to Revered if they are encountered and added to your faction list via a lone Forsaken Eldritch Totem in a dungeon at the end of the "Hidden Path" secret quest line prior to going to the Forgotten Gods map. It is easily corrected via the notes I include in the code scripts.
On one of my save games some months ago I had encountered this issue while using fantomas's faction option. I managed to alter them back to being enemies (which started my working to understand how to do these options in this post), but I wanted to see why that had happened in the first place as it shouldn't have.
I think I found the likely cause. As it was a fresh Ultimate save game that did not play through the Forgotten Gods expansion on an earlier difficulty, Eldritch Horrors had not been encountered on it and they were not in my faction list. However, instead of encountering them for the first time when I eventually went into the Forgotten Gods expansion, I instead encountered that enemy for the first time on that save game via a Totem spawn at the end of the "The Hidden Path" quest line.
Because that enemy seems to get set to -1 automatically when you start that FG map area and they are added to your faction list, they are automatically set to being designated as an enemy. As their faction value will not be equal to or greater than zero (as it is a negative number) they will not be made Revered status at that time by fantomas's option.
However, I think my encountering them via the "Forsaken Eldritch Horrors" totem spawn long before going to the FG map area, they were not auto-added to my faction list as -1 and set as enemies, so they technically had "0" experience and thus met the comparison check in fantomas's script as qualifying as friendly due to not being a negative number.
So the best thing to do on a new game with no factions in your list would be to not trigger the Forsaken Eldritch Totem in the Temple of the Three dungeon area at the end of the Hidden Path quest line before you start the Forgotten Gods expansion. Otherwise, if you do encounter them early via that totem and they get set to Revered, one little character change that I note in the scripts above can be used to correct them back to being enemies.