Description
The REL ID database may not be ready for mods in PostLoad. But this behavior is random.
As reported on discord:
CommonlLibSF mod is now reporting missing IDs that were confirmed in addresslib database. Code had previously worked before SF 1.8.86. Workaround was to load the mod later:
"I've changed kPostLoad to kPostDataLoad in my listener that starts everything and now things are ok. "
This was previously seen in fo4 and fixed by testing for actual data instead of an init boolean.
alandtse/CommonLibF4@667490a and prior discord [discussion] (https://discord.com/channels/535508975626747927/541414634117398536/1129919975327535104)
Nukem's thoughts on seeing commonlibf4 commit:
wtf
it should've just used std::call_once and been done with it
but even then, it's not going to be a threading issue and the atomics are irrelevant
which leaves _instance._filename != L""
someone create a repro of this on github and I'll debug it
Initial analysis of SF code vs fo4:
The same older code in iddatabase
CommonLibSF/CommonLibSF/include/REL/ID.h
Lines 192 to 193 in f2ea130
As no repro case was available, we're just logging the issue for anyone else.
This can be avoided with other workarounds as described here.