Omnishade Posted August 7, 2024 Posted August 7, 2024 I just want to add an image to an MCM menu, nothing big, but editing scripts seems to be more problematic than I thought. I've tried SSEScript but it can't even compile a source script from a released mod. In the CK the "edit source" is greyed out even if the source is included. I'm starting the CK from MO2 so is that the problem or is it something else? What do you need to do?
blank_v Posted August 7, 2024 Posted August 7, 2024 (edited) You don't need anything except Creation Kit... Tho some Text editor could help... First, there are two types of files, PEX -> Papyrus Executable PSC -> Papyrus Source You can edit only PSC files, those are getting compiled into PEX via Papyrus Compiler that You can find in Your Skyrim folder or via Creation Kit. It's recommended to use CK for compiling as using Copiler via Shell can cause some troubles with linking scripts together, unless You don't extend behavior... if You have grayed "Edit Source" like You said, it means that YOU DO NOT have PSC file with coresponding PEX file in such case You will have to decompile PEX into PSC or download PSC ( Not all authors share Source Code ) //Edit: { "You do not have PSC" OR CK DOES NOT SEE PSC... because You use CK via MO2 ... } You can decompile Scripts via -> https://www.nexusmods.com/skyrim/mods/35307/ Once You have scripts decompiled ( only those You really want to edit ) You can then open them in any text editor ( or directly in CK ) and edit them Then You can just compile them again... YOU DONT WANT TO START CREATION KIT VIA MODORGANIZER 2 OR ANY MOD MANAGER!!! THIS WILL LEAD YOU TO ISSUES ITS POSSIBLE THAT YOU HAVE SOURCE SCRIPTS BUT MO2 IS MESSING IT ALL AROUND!! NEVER USE CK WITH MOD MANAGERS!!! If You want You can download Papyrus Styles I made for N++ -> https://www.nexusmods.com/skyrimspecialedition/mods/65345 I don't remember what version on Nexus supports but lastest Version of QLG Papyrus is supporting pretty much everything Including PapyrusUtil, MCM and even some of SexLab... tho it's just SyntaxHighlighting... Edited August 7, 2024 by ̖̪. 1
traison Posted August 8, 2024 Posted August 8, 2024 (edited) 9 hours ago, RoninDog said: editing scripts seems to be more problematic than I thought. If you already have a modded setup then yes, the first time will be problematic. You'll have to get the sources for all relevant scripts. Since you're dealing with an MCM: You'll probably need the vanilla game sources provided by the CK. You'll need the SKSE source scripts. You'll need the SDK for a compatible SkyUI version. The sources for whichever mod that MCM belongs to. Most likely you'll need the sources for all mods that mod depends on, or otherwise references. 9 hours ago, RoninDog said: In the CK the "edit source" is greyed out even if the source is included. There's 2 different standards for where script sources should be. You will have to normalize all mods to whichever standard you use. It doesn't matter which one you pick really, because the split between standards is about 50-50. Check your CreationKit.ini for where its configured on your system. If there is no value, assume its the *new* standard. I use the *old* standard because it makes more sense to me: [Papyrus] sScriptSourceFolder = ".\Data\Scripts\Source" 9 hours ago, RoninDog said: I've tried SSEScript but it can't even compile a source script from a released mod. I don't know about these 3rd party compiler UIs. For now I'd suggest you stick with the CK. Get the basics working. Eventually yes, you should get a separate UI for running the papyrus compiler because launching the CK just for this is like starting another OS just because you like the way its calculator app looks - it's horribly bloated for this purpose. I made my own UI (because of course I did) for the compiler when I got tired of how clumsy the CK is. As for script writing and editing, Notepad++ I'd say. Free, fast, reasonably advanced even though its showing its age slightly. VS Code might work as well, but I'm not sure about its support for custom languages. --- 8 hours ago, ̖̪. said: YOU DONT WANT TO START CREATION KIT VIA MODORGANIZER 2 OR ANY MOD MANAGER!!! This seems like a horrible idea. Don't know about Vortex but you really don't want to be running the CK outside of MO2 unless you have a thing for manually managing your mods, in which case my next question would be, why did you even install MO2 then? If you don't run the CK through MO2 it won't see any file thats within a mod - no scripts, no plugins, no bsa files, no textures or meshes, ... Edited August 8, 2024 by traison
blank_v Posted August 8, 2024 Posted August 8, 2024 14 hours ago, traison said: This seems like a horrible idea. Don't know about Vortex but you really don't want to be running the CK outside of MO2 unless you have a thing for manually managing your mods, in which case my next question would be, why did you even install MO2 then? If you don't run the CK through MO2 it won't see any file thats within a mod - no scripts, no plugins, no bsa files, no textures or meshes, ... Well... I'm not gonna stop all of You from having issues due to Your own decisions... CK and MO are not compatible and running CK via MO only confuses CK as to where to search for files... You may even have all the required files... does CK know where they are?... well... CK is shitty program and Your Process Instance on Windows can have only one directory... I think MS could change that that every HANDLE could have it's own Directory... but as for now they are linked to process root direectory, because of MO using virtual drives it's simply making CK confused and unable to find required files... MO is made for a game not for the engine... Tho if for editing one mod You need to load every single other mod that You have installed for Your game... go for it... Your problem is not my problem really... How about ENB? Are You gonna run ENB in CK too? Because it can be done... tho ENB also rapes CK and makes it work badly, markers and Render View sub interface can be not displayed properly...
traison Posted August 8, 2024 Posted August 8, 2024 38 minutes ago, ̖̪. said: CK and MO are not compatible and running CK via MO only confuses CK as to where to search for files... Works for me just fine. 38 minutes ago, ̖̪. said: does CK know where they are? The CK will look for the files in the exact same location it does without usvfs (MO2). It does not need to be aware of MO2's mod structure. 39 minutes ago, ̖̪. said: Your Process Instance on Windows can have only one directory.. The working directory, yes. An old concept that's entirely up to every application to decide whether its going to honor it or not, I'd say most applications don't these days, in favor of storing their installation directory in the registry, or loading configuration files from the depths of appdata. 41 minutes ago, ̖̪. said: that every HANDLE could have it's own Directory IO handles have no directories associated with them. You specify which file you want to open in the parameters to the CreateFile API and it returns a handle you can use. The file you open can be anywhere, on any drive, in memory, local or remote. The "file" doesn't even have to be what most people consider a file; it could be a pipe for instance. 42 minutes ago, ̖̪. said: MO is made for a game not for the engine... Well the game runs on an engine, it's called a "game engine" afterall. The usvfs can handle practically any process these days: cmd, powershell, explorer++, bodyslide, nifskope, creationkit, python, xedit, fnis, pandora, nemesis, c# applications and bsa browser; and that's just the list of applications I have in its launch menu. 45 minutes ago, ̖̪. said: Tho if for editing one mod You need to load every single other mod that You have installed for Your game... go for it... Your problem is not my problem really... The usvfs doesn't actually load anything in this sense. Much like deploying mods through vortex, the CK will see mod files just like they were actually there, even though when viewed from outside of the usvfs they're not. You can see it in action with a program called Process Monitor from Sysinternals (Microsoft). Note the first call to CreateFile failing, followed by a successful call to the same file in one of the mod directories. That's the usvfs checking if the file exists at the default path, followed by its redirection to the mod directories.
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