I have some new errors with Enhanced Economy.esp and a ctd with a BEX error.
I downloaded it, and will look at where in EE the error occured (thanks to scruggsy for the ScriptViewer which has helped me several times already).
Also thanks for the array updates. I'm an old C/C++ programmer so the * notation seems simpler to me.
Then onto some problems that I would appreciate help with:
There have been a few bug reports from users of Enhanced Economy that leads me to think that the errors used by EE has been messed up a bit, and I've started to suspect that the problem is related to your known issue about OBSE when loading a savegame. EE has a two-dimensional array, and just after savegame load (when GetGameLoaded returns true), I loop through the array and removes some of the entries. Is it possible that OBSE's issue could lead to problems with this?
Then I've got a bug report for Real Sleep Extended. The mod uses several arrays and one of them is an array of references to objects (bedrolls) that have been placed in the world using PlaceAtMe, but later been disabled. I thought PlaceAtMe'd objects would never be removed even after a disable, but one user reports a CTD when such an object is re-used (ref.MoveTo + ref.Enable), and the conscribe log shows that the reference is 0. This leads me to two questions:
1. Is it possible that such an object is cleaned out by Oblivion when its cell is reset, or is it a bug that one array entry of a reference suddenly is 0?
2. How is it best to check for it? I added what I thought was a fix, with the following code:
let realBedroll := RSE.unusedBedrolls[i] ar_Erase RSE.unusedBedrolls i if realBedroll realBedroll.moveTo player DebugPrint "RSE:placed unused bedroll %i at index %.0f", realBedroll, i else let realBedroll := player.placeAtMe BedrollSideEntry, 1, 0, 0 DebugPrint "RSE:Added new bedroll %i and remove illegal unused at index %.0f", realBedroll, i endif
But the code still ends up writing "RSE:placed unused bedroll 00000000 at index 0", thus indicating that "if realBedroll" is true even with realBedroll equal 0. I thought that was not possible, but I guess I can add a second test: "if IsFormValid realBedroll" too. Is this assumption correct?