long-war-2 / lwotc

Port of Long War 2 to XCOM 2's War of the Chosen expansion
345 stars 91 forks source link

M4 Warlock prematurely shows up in lair #1338

Closed allenhu0912 closed 3 years ago

allenhu0912 commented 3 years ago

At FL14, m4 Warlock spawned in his lair. Strategy save from before infiltration and tactical save before he spawns attached.

Warlock.zip

allenhu0912 commented 3 years ago

This did not occur for FL15 Hunter lair assault.

pledbrook commented 3 years ago

I can see why this is happening, but I don't understand why it's not happening for the Hunter. I started an infiltration of the Hunter's Stronghold at FL14 (when the Chosen Level increases) and the M4 Hunter was added to the mission.

pledbrook commented 3 years ago

I think the bug is in the code that adjusts the Chosen level when you load a strategy save. It uses AlienHQ.GetForceLevel() which is apparently not the same as the regional force level that LWOTC uses for most things.

I loaded one of my old strategy saves where the displayed FL on the geoscape was 8, but AlienHQ.GetForceLevel() was returning 9. This meant the Chosen got a bump up to level 1, and then when FL ticked over to 9 from a schedule offworld reinforcement UFO, the level got bumped further to 2. I'm assuming the same happened with you where you loaded a strategy save that had a LW force level of 13, but an alien HQ force level of 14.