pinoilpenno Posted June 7, 2021 Share Posted June 7, 2021 Hello everyone, i'm a total noob at scripting, but i want to change one thing from the Beeing Female mod (I use Vortex). Before changing something though, i wanted to try to recompile one of the mod's script without changing anything.So i tried to recompile it with PCA SE, but i was a getting a lot of errors, to which i realized i needed the other scripts (not all the psc equivalent of the pex files are in the source folder of the mod, some are missing). I downloaded Champollion and converted them to psc. So far so good.I tried compiling again, and got errors. I realized i had to unzip the Scripts zip, activate Racemenu, skse scripts extender (which overwrote the original scripts) and papyrus util (which also overwrote a few of the original scripts).So i did. Still had errors, related to SkyUI: unable to locate script sky_widgetbase and a lot of errors. Searched a few minutes on the web, found the SDK. Downloaded the 5.1 version and activated it, still couldn't locate sky_widgetbase.Decided to deactivate SDK and use Champollion on the SkyUI's pex scripts, converted them and activated them. Was still getting a load of errors, but no more "Unable to locate script sky_widgetbase", only a lot of argument effectid not specified and no default value, argument a_noupdate not specified and no default value, ecc...So, i also activated SkyUI SDK 5.1 (Which was obviously in conflict with the scripts i converted from the normal SkyUI 5.2) and gave priority to it. Tried recompiling, and got a LOT less errors, but i don't know what to do from here on. I tried using older SDK versions, but no luck. Here are the few errors i get now with the original SkyUI scripts i converted with Champollion + SkyUI SDK 5.1 and all the other scripts i need: FWSystem.psc C:\Program Files (x86)\Steam\steamapps\common\Skyrim Special Edition\Data\Scripts\Source\FWSystemConfig.psc(4556,14): argument bplayer is not specified and has no default valueC:\Program Files (x86)\Steam\steamapps\common\Skyrim Special Edition\Data\Scripts\Source\FWSystemConfig.psc(4750,6): argument amount is not specified and has no default valueC:\Program Files (x86)\Steam\steamapps\common\Skyrim Special Edition\Data\Scripts\Source\FWChildActor.psc(328,0): the parameter defaults of function hasfamilyrelationship in the empty state on script fwchildactor do not match the parent script actor I still haven't touched a single line of code. Can someone help me get through these last errors? Link to comment Share on other sites More sharing options...
dizietemblesssma Posted June 7, 2021 Share Posted June 7, 2021 For the latest:) go here:https://github.com/schlangster/skyuidownload the master zip - the green code button.Look in dist>Data>Scripts>SourceNo need to decompile Skyui diziet edit: on second thoughts, maybe stick with the decompilng, some of the files from above say they are ver 4.1! The filedates look ok though, so I'm unsure now.The downloaded files certainly seem to have the same contents as my decompiled versions but whi knows? Link to comment Share on other sites More sharing options...
dizietemblesssma Posted June 7, 2021 Share Posted June 7, 2021 A follow up post on the subject of decompiling SkyUI scripts with champollion: It seems that I have been working with downloaded SkyUI 5.1 .psc files,I have discovered that when using decompied 5.2 .psc files I can no longer compile some of my mod files that compiled fine before, I would get errors like:D:\SteamLibrary\steamapps\common\Skyrim Special Edition\Data\Scripts\Source\dz_outfits_mcm_menu.psc(1956,3): argument a_cancellabel is not specified and has no default value upon investigation of the SKI_ConfigBase.psc file that I have downloaded from 5.1 you see that the function defintions are as such:Bool function ShowMessage(String a_message, Bool a_withCancel, String a_acceptLabel = "", String a_cancelLabel = "") where the two parameters a_acceptlable and a_cancelLabel are given defaults,in the decompiled 5.2 version of SKI_ConfigBase.psc that function definition reads:Bool function ShowMessage(String a_message, Bool a_withCancel, String a_acceptLabel, String a_cancelLabel)where the paramaters have no defaults. When I edited the 5.2 version of the file to match the 5.1 with the parameters given defaults, then the error message above no longer appeared; however there were a lot of error messages like that!I compiled my new SKI_ConfigBase.psc and then decompiled the resultant .pex,sure enough, whereas the .psc file that was compiled had the line:Bool function ShowMessage(String a_message, Bool a_withCancel, String a_acceptLabel = "", String a_cancelLabel = "")the decompiled version read:Bool function ShowMessage(String a_message, Bool a_withCancel, String a_acceptLabel, String a_cancelLabel) from which I conclude that champollion (at least for me) does not properly decompile (or that parameters like String a_cancelLabel = "" don't get compiled)either way, since you need that parameter defined in the .psc files you cannot use the decompiled files as is.Indeed from the SkyUI page of API reference:https://github.com/schlangster/skyui/wiki/MCM-API-Reference#ShowMessageyou see that the parameters a_cancellabel and a_acceptLabel are optional, meaning that the SKI_ConfigBase.psc file used when compiling this function almost certainly have the:String a_acceptLabel = "", String a_cancelLabel = "")in it. So now I have a quandary, all this time I have been using SkyUI 5.1 source and making it work (apparently) with the SkyUI5.2 mod installed, so do I leave things as they are, or edit all the functions in the decompiled SKI_Configbase.psc that have the default paramter assignments missing? diziet Link to comment Share on other sites More sharing options...
IsharaMeradin Posted June 8, 2021 Share Posted June 8, 2021 No need to decompile SkyUI scripts. Use the SDK. It was designed specifically to allow one to compile their MCM script. MCM aspects have not changed and so the "older" SDK files are just fine to use. Link to comment Share on other sites More sharing options...
pinoilpenno Posted June 8, 2021 Author Share Posted June 8, 2021 But when i try to compile with SDK 5.1 only, i get an "unable to locate script sky_widgetbase" error. Link to comment Share on other sites More sharing options...
IsharaMeradin Posted June 8, 2021 Share Posted June 8, 2021 But when i try to compile with SDK 5.1 only, i get an "unable to locate script sky_widgetbase" error.dizietemblessma was confused about which to use. I replied that for MCM creation use the SDK. Your situation deals with widgets which is something additional to MCM. I would recommend asking the author of the mod you are wanting to edit, what needs to be done and what files are necessary to do that. Also, giving this a read may shed some light, though only the part at the end might be relevant: https://www.nexusmods.com/skyrimspecialedition/articles/1013 Link to comment Share on other sites More sharing options...
pinoilpenno Posted June 8, 2021 Author Share Posted June 8, 2021 I managed to make it compile. It seems 2 of the errors were about a function call without the required values, hence the "not specified" and "no default value".As for the other error, i simply eliminated that line (i couldn't understand what to do), compiled the script i wanted to change, and restored the old scripts for the other ones. Link to comment Share on other sites More sharing options...
Recommended Posts