h38fh2mf Posted May 30, 2014 Posted May 30, 2014 If this is a frequent thing then there must be a mistake somewhere. I tried google "ofstream null write" and similar but nothing relevant really came up so it may be my code problem but I didn't see anything wrong when I looked over. One way to fix all crashes related to loading this file is use exception handling and if there is an exception just treat that as file not found however this is not a real solution because data shouldn't be lost like that. Luckily I think no mods currently use this feature.
Scardust Posted May 31, 2014 Posted May 31, 2014 This is really strange. I saw several times the hint to delete the .save file but even when I do so and start a brand new game I get this error message. The funny thing is that this started just today on an brand new game with just 6 hours of gameplay. I have attached my storageutil file, maybe it helps you guys. Maybe if someone who is not affected by this could upload his file then other who have the problems can start and when it happens again take a look at both files to see what has changed. I am not a programmer or so so sorry if I am talking nonsense. Edit: Ok, after reading the whole thread I have reinstalled SKSE, papyrusutil v22 (before that I deleted the .save file) and also installed the MS redistributeable some pages before it still showed the error. Only after re-starting the PC it finally stopped. StorageUtil.rar
b3lisario Posted May 31, 2014 Posted May 31, 2014 This is really strange. I saw several times the hint to delete the .save file but even when I do so and start a brand new game I get this error message.What error message exactly?
Scardust Posted May 31, 2014 Posted May 31, 2014 Oh stupid me, sorry. The error message is or was the same other have with the "wrong installed papyrusutil".
b3lisario Posted May 31, 2014 Posted May 31, 2014 If it says missing vcomp90.dll, install this http://www.microsoft.com/en-us/download/confirmation.aspx?id=10015
Scardust Posted May 31, 2014 Posted May 31, 2014 Well, it was not asking for this specific file it just said that the papyrusutil was not installed correctly. I have installed it anyways but only after a PC restart the util worked again. Pretty strange that is stopped working without changing anything but finally I was able to solve it. Thanks for your support b3lisario.
h38fh2mf Posted June 1, 2014 Posted June 1, 2014 This might happen if UAC is on and skse_loader is not started in admin mode. It relies on memory edit to register papyrus functions and if there is no access then there is no registration of any functions.
Earen Posted June 2, 2014 Posted June 2, 2014 all-in-one package (sources, projects, skse sources and etc), modified settings so it won't require any ms redistributable runtime PU.7z
h38fh2mf Posted June 3, 2014 Posted June 3, 2014 Nice, what was wrong with it that it required redistributable?
Earen Posted June 3, 2014 Posted June 3, 2014 Nice, what was wrong with it that it required redistributable? nothing, actually it's ok when application requires redistributable as MS will be able to patch it later, apply security fixes and etc. the only issue it that we have to explain it to users .. So, i just switched one compile flag from /MD to /MT and now plugin bundles that redistributable
Vargrivi the Wild Posted June 4, 2014 Posted June 4, 2014 all-in-one package (sources, projects, skse sources and etc), modified settings so it won't require any ms redistributable runtime im srry i do not quite understand, do we put this in our skyim\data folder? im really newbish at modding and ive no a clue on what to do with those files, p.s. srry if this was a stupid question. Respectfully asked by MissLaughingWolf
gooser Posted June 4, 2014 Posted June 4, 2014 MissLaughingWolf, the post by Earendil was for the benefit of the author of PapyrusUtil, mainly to help track a dependency issue that has caused some users grief. I would wait for an official release on the main page.
h38fh2mf Posted June 4, 2014 Posted June 4, 2014 For me /MT did not remove dependency. So I just removed usage of OpenMP and replaced it with same method I use in IFPV, no more dependency I checked. Made new version, it's 2.3 now.
b3lisario Posted June 4, 2014 Posted June 4, 2014 Glad to see the mod has been updated. Thanks! In regards to "corrupted" save issue. Do you know of any mod that uses that save feature? I'd like to try to reproduce the problem. I did more of my silly tests and I've verified that reading NULLs from a stream and doing this thing: stream >> int variable puts "dirt" on the int variable. I am not sure why this should crash, I guess it enters in any of the for loops that follow. I think something like if (contents[0] = '\0') return; while doesn't fix the issue, maybe will save users from some trouble, and also to us from support them. Just a thought for the next update...
Werdle777 Posted June 5, 2014 Posted June 5, 2014 Could someone help me? I installed version 2.3 and I keep getting this error: checking plugin C:\Program Files\Steam\SteamApps\common\skyrim\Data\SKSE\Plugins\\StorageUtil dllplugin C:\Program Files\Steam\SteamApps\common\skyrim\Data\SKSE\Plugins\\StorageUtil dll (00000001 papyrusutil plugin 00000001) disabled, fatal error occurred while loading plugin The menu loads but it crashes when I load my save. I have the latest version of sexlab installed, using the papyrusutil included in that causes skse to crash on startup.
Uriel Posted June 7, 2014 Posted June 7, 2014 Do you have a StorageUtil.save in your "Skyrim\Data\SKSE\Plugins\"? 1) post this file here 2) remove it and check if Skyrim works now.
Ashal Posted July 2, 2014 Author Posted July 2, 2014 Since releasing SexLab 1.58 which includes the newest PapyrusUtil with the fixed dependency; I've had a couple people report being unable to start Skyrim unless they downgrade PapyrusUtil back down to 2.2, citing the same skse.log error as Werdle777 above. Wild shot in the dark, as I have no idea if it'd help, but it may be to the benefit of this problem to switch the SKSE plugin hooking PapyrusUtil is using with sub_8F7E10() to the native method now enabled by SKSE 1.7: SKSEPapyrusInterface * g_papyrus = NULL; extern "C" { bool SKSEPlugin_Query(const SKSEInterface * skse, PluginInfo * info) { // ... g_papyrus = (SKSEPapyrusInterface *)skse->QueryInterface(kInterface_Papyrus); if(!g_papyrus) { _MESSAGE("couldn't get papyrus interface"); return false; } // ... return true; } bool SKSEPlugin_Load(const SKSEInterface * skse) { // ... g_papyrus->Register(RegisterFuncs); // ... return true; } } bool RegisterFuncs(VMClassRegistry* registry) { // Register all papyrus function implementations here. registry->RegisterFunction(new NativeFunction3<StaticFunctionTag, UInt32, TESForm*, BSFixedString, UInt32>("SetIntValue", "StorageUtil", i_SetIntValue, registry)); registry->SetFunctionFlags("StorageUtil", "SetIntValue", VMClassRegistry::kFunctionFlag_NoWait); // ... return true; } I can update it myself if need be and you post the updated source for 2.3
b3lisario Posted July 2, 2014 Posted July 2, 2014 You get this message when the StorageUtil.save file is filled with nulls (corrupted). This is my suggestion: File main.cpp, function LoadFileValues replace: std::stringstream ss(contents); with std::stringstream ss(contents); if (contents[0] = '\0') return; This won't fix the real cause of the "corrupted StorageUtil.save" issue (I don't think this is caused by PapyrusUtil BTW), it's just a workaround.
Ashal Posted July 2, 2014 Author Posted July 2, 2014 Alternatively the file values could be switched to using the existing json file system, which currently seems much more stable than the StorageUtil.save system, just connect all the former .save functions to to a single json file to serve the same purpose as the StorageUtil.save. This could even be implemented by just switching the existing file storage functions to serve as papyrus based adaptation to the json functions, rather than having to mess around with the dll files code (except maybe to delete the then unused native functions).
h38fh2mf Posted July 3, 2014 Posted July 3, 2014 Here is the source of latest version if you want to make the changes. plugin_example2.zip
Srende Posted July 5, 2014 Posted July 5, 2014 I'm getting crashes with 2.3. Specifically, I can reproduce it consistently with Deviously Helpless, at the end of the Draugr scene. Downgrading to 2.2 solved the problem, I've also had others confirm the same thing. After a bit of tinkering, I've narrowed it down to this bit: function SandBoxCreatures() int num = FormListCount(none, creatureList) RemoveAllPackageOverride(gatherPackage) while num > 0 num -= 1 Actor creature = FormListGet(none, creatureList, num) as Actor AddPackageOverride(creature, sandboxPackage, 100) creature.EvaluatePackage() endWhile endFunction Commenting that out from my code prevented the crash with 2.3. Currently I'm thinking the problem might be RemoveAllPackageOverride, as the other functions I've used elsewhere as well and they seem to be working fine.
Ashal Posted July 5, 2014 Author Posted July 5, 2014 You get this message when the StorageUtil.save file is filled with nulls (corrupted). This is my suggestion: File main.cpp, function LoadFileValues replace: std::stringstream ss(contents); with std::stringstream ss(contents); if (contents[0] = '\0') return; This won't fix the real cause of the "corrupted StorageUtil.save" issue (I don't think this is caused by PapyrusUtil BTW), it's just a workaround. Ultimately while it might fix it, it's definitely just a workaround, as it just prevents the crashing and does nothing to to actually stop the file from corrupting itself. I can update it and add the fix in, but as one of the main people making heavy use of PapyrusUtil though, I'd like to hear your opinion on the json replacement idea I mentioned in my previous post, or other ideas in general.
h38fh2mf Posted July 6, 2014 Posted July 6, 2014 JSON might corrupt the same way, I think corruption happens if game crashes during file saving or some OS file access problem. Maybe workaround would be to save to a new file, then when saving is done, delete old file and rename new file to old file. If game has crashed in between then nothing really is lost. Srende I looked over package code and it seems ok. Do you think you can get the memory address where game exception occurred?
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now