Bug with cult relation changes from policy decision

Moderator: Vic

Post Reply
Lockreed
Posts: 7
Joined: Tue Apr 06, 2021 8:44 pm

Bug with cult relation changes from policy decision

Post by Lockreed »

I've found a bug regarding relation with cults.

For all decisions that arise from the "discuss cult policy" stratagems, the relation for that cult does not change regardless of the decision. All of the other random event decisions appear to be working correctly for individual cult relation.

This behavior was confirmed with another player on discord by monitoring the REGKEY.cultx_relation value via the in-game debugger in table 146. (Thanks for your help, Magirot!)

It also appears that REGKEY.cultx_strength does not change as a result of random event decisions.

I dug into the S&S editor and found that REGKEY.cultx_relation gets assigned to <TEMP2>, <TEMP2> is then modified based on the selection, and then <TEMP2> is mapped back to REGKEY.cultx_relation in the 2nd "AFTER_DEC_ALL_LOGIC_SET" column (CZ in excel). Interestingly, this same column is used to map REGKEY.cultx_strength for random event cult decisions (also not working correctly).

As a test, I moved this assignment to "AFTER_DEC_ALL_LOGIC_SET" column CW. It still didn't work, so I checked the <TEMP2> value - lo and behold it had not changed after making a decision that should have changed it.

I then was able to create a mod that fixed this bug by moving all TEMP2 variable calculations (changes to cult relation) from "RESULT_IF_SET" (column BW) to "RESULT_SET". It appears TEMP2 was never actually getting adjusted, and just mapped back in to .cultx_relation, hence no change to cult relation.

According to S&S documentation, that column SHOULD have worked, but it didn't, so I'm assuming the bug is deeper than just something being in the wrong column :D
Magirot
Posts: 141
Joined: Thu Dec 09, 2021 9:01 pm

Re: Bug with cult relation changes from policy decision

Post by Magirot »

Lockreed wrote: Wed May 03, 2023 5:50 pmAccording to S&S documentation, that column SHOULD have worked, but it didn't, so I'm assuming the bug is deeper than just something being in the wrong column :D
I realised I was looking at the wrong part: according to the documentation, After Decision Logic allows a blank logic check, but the Result Logic doesn't.

Image

Image


So the bug in the cult policy decisions might be caused by the RESULT_IF column being blank, and because of that RESULT_IF_SET never modifies TEMP2?


Forgetting the cause, screenshots that show the bug:

Image
On turn start, my Eternity movement relation is 100.

Image
I choose "Decrease policy in favor of Cult". Per columns 68 and 97, this should set relation to 80% of current relation.

Image
However, as seen in Regime Keys, relation is unchanged. Only policy key has changed.
Post Reply

Return to “Tech Support”