Jump to content

fireundubh

Members
  • Content Count

    342
  • Joined

  • Last visited


Reputation Activity

  1. Like
    fireundubh got a reaction from Thenryb in [RELz] fireundubh's Skyrim Mods   
    I've put up a simple website with brief descriptions and download links for all of my Skyrim mods.
     
    http://fireundubh.github.io/skyrim/
     
    All mods have been updated to support USLEEP, excluding King of Thieves and Master of Disguise, which have some bugs I need to work out before re-releasing them.
  2. Like
    fireundubh got a reaction from Utumno in Wrye Bash - All Games   
    @Utumno Did you see my earlier posts? I already looked.
  3. Thanks
    fireundubh got a reaction from alt3rn1ty in Kingdom Come Scripting/Modding Documentation Wiki   
    I'm working on comprehensive scripting/modding documentation for Kingdom Come: Deliverance.
    Not sure if anyone here made it over to that game, but if you're interested, here's the link: wiki.fireundubh.com/kingdomcome.
     
  4. Like
    fireundubh got a reaction from Utumno in Wrye Bash - All Games   
    No, don't expect parity; the Form Version can differ between records. The TES4 header record is really just another record.
    I wrote a rough Python script for how to read the Form Version for records in groups: find_form_version.py. It does not iterate through records or groups, so you'll need to implement that yourself however you want to do that in Wrye Bash.
    edit: Updated the script to iterate through groups and records, except CELL and WRLD, which I skipped simply because they require a bit more work than I intended to put into this. CELL and WRLD groups contain multiple levels of groups, so the script currently fails to parse those records. On the plus side, the script now logs the Form ID for each record, in addition to the Signature and Form Version, so you can open up a plugin in a hex editor and see the data structures yourself.
    edit 2: Wrote a third version that exports record metadata from all ESM/ESP files in a directory to JSON. It also uses struct.unpack and skips DIAL records, too.
    https://gist.github.com/fireundubh/af0994cb65ffb26d0810ee213a3b46fb
    Game: Tested on only SSE plugins Version: Tested on Python 3.6.4 Libraries: io, json, os, pathlib, struct, collections.defaultdict Helpful Resources:
    https://docs.python.org/3/library/struct.html https://docs.python.org/3/library/io.html https://www.devdungeon.com/content/working-binary-data-python
  5. Thanks
    fireundubh got a reaction from Beermotor in Wrye Bash - All Games   
    No, don't expect parity; the Form Version can differ between records. The TES4 header record is really just another record.
    I wrote a rough Python script for how to read the Form Version for records in groups: find_form_version.py. It does not iterate through records or groups, so you'll need to implement that yourself however you want to do that in Wrye Bash.
    edit: Updated the script to iterate through groups and records, except CELL and WRLD, which I skipped simply because they require a bit more work than I intended to put into this. CELL and WRLD groups contain multiple levels of groups, so the script currently fails to parse those records. On the plus side, the script now logs the Form ID for each record, in addition to the Signature and Form Version, so you can open up a plugin in a hex editor and see the data structures yourself.
    edit 2: Wrote a third version that exports record metadata from all ESM/ESP files in a directory to JSON. It also uses struct.unpack and skips DIAL records, too.
    https://gist.github.com/fireundubh/af0994cb65ffb26d0810ee213a3b46fb
    Game: Tested on only SSE plugins Version: Tested on Python 3.6.4 Libraries: io, json, os, pathlib, struct, collections.defaultdict Helpful Resources:
    https://docs.python.org/3/library/struct.html https://docs.python.org/3/library/io.html https://www.devdungeon.com/content/working-binary-data-python
  6. Thanks
    fireundubh got a reaction from Beermotor in Searching Github   
    I recommend SmartGit. It's free for personal use. Steeper learning curve than SourceTree but far more polished and flexible. All Git clients are lightweight relative to Git itself.
    AstroGrep and Agent Ransack are excellent in-file search programs. AstroGrep is less featureful but open source. I use both.
    RegEx101 is the best visual RegEx debugger I've used.
  7. Thanks
    fireundubh got a reaction from Dragonblood in [WIPz] TES5Edit   
    I know the difference between a FormID string and a record with a FormID. That's the problem: they're different and they're treated differently. LOL.
     
    Run this script on a TERM record with a VMAD subrecord that has two or more object properties, one of which contains the string "Player [00000014]" in the FormID field.
    unit UserScript; const PropertyRefPath = 'Value\Object Union\Object v2\FormID'; function Process(e: IInterface): Integer; var i: Integer; properties, p, ref: IInterface; begin properties := ElementByPath(e, 'VMAD\Script Fragments\Script\Properties'); for i := 0 to Pred(ElementCount(properties)) do begin p := ElementByIndex(properties, i); ref := LinksTo(ElementByPath(p, PropertyRefPath)); AddMessage(EditorID(ref)); end; end; end. That script will return results similar to:
    Applying script... AutoLoot_Perks [Apply Script done] Processed Records: 1, Elapsed Time: 00:00 Change EditorID to Signature and:
    Applying script... FLST [Apply Script done] Processed Records: 1, Elapsed Time: 00:00 This is bad. Either EditorID and Signature need to return values, or they need to raise exceptions. Right now, they return zero-length strings.
    You can't even use try-except here because the zero-length string is a valid result.
     
    So, instead of the above loop, you have to do something wonky create a unique EditorID function that takes two parameters:
    unit UserScript; const PropertyRefPath = 'Value\Object Union\Object v2\FormID'; function GetEditorID(mainRec, linkedRec: IInterface): String; begin Result := IfThen(GetNativeValue(mainRec) = $14, 'Player', EditorID(linkedRec)); end; function Process(e: IInterface): Integer; var i: Integer; properties, p, ref: IInterface; begin properties := ElementByPath(e, 'VMAD\Script Fragments\Script\Properties'); for i := 0 to Pred(ElementCount(properties)) do begin p := ElementByIndex(properties, i); ref := ElementByPath(p, PropertyRefPath); AddMessage(GetEditorID(ref, LinksTo(ref))); end; end; end.  
    But what if you want to return a linked element from the loop? Well, if you want to also handle the Player, you can't do that directly. You have to do something like this:
    unit UserScript; const MatchingID = 'Player'; PropertyRefPath = 'Value\Object Union\Object v2\FormID'; function GetEditorID(mainRec, linkedRec: IInterface): String; begin Result := IfThen(GetNativeValue(mainRec) = $14, 'Player', EditorID(linkedRec)); end; function GetMatchingProperty(properties: IInterface; MatchingID: String): IInterface; var i: Integer; p, ref, linkedRef: IInterface; begin for i := 0 to Pred(ElementCount(properties)) do begin p := ElementByIndex(properties, i); ref := ElementByPath(p, PropertyRefPath); linkedRef := LinksTo(ref); if GetEditorID(ref, linkedRef) = MatchingID then break; end; if GetEditorID(ref, linkedRef) <> MatchingID then raise Exception.Create('Could not find matching property'); Result := ref; end; function Process(e: IInterface): Integer; var properties, ref: IInterface; begin properties := ElementByPath(e, 'VMAD\Script Fragments\Script\Properties'); ref := GetMatchingProperty(properties, MatchingID); AddMessage(GetEditorID(ref, LinksTo(ref))); end; end.  
    If you didn't need to handle the Player differently, this script would be fine:
    unit UserScript; const MatchingId = 'AutoLoot_Perks'; PropertyRefPath = 'Value\Object Union\Object v2\FormID'; function Process(e: IInterface): Integer; var i: Integer; properties, p, ref: IInterface; edid: String; begin properties := ElementByPath(e, 'VMAD\Script Fragments\Script\Properties'); for i := 0 to Pred(ElementCount(properties)) do begin p := ElementByIndex(properties, i); ref := LinksTo(ElementByPath(p, PropertyRefPath)); edid := EditorID(ref); if edid = MatchingId then break; end; if edid <> MatchingId then raise Exception.Create('Could not find matching property'); // do something with the linked ref or edid AddMessage(Signature(ref)); end; end.  
    So, I hope where words have failed, the code shows you what I'm talking about.
    In theory, EditorID, Signature, and LinksTo require an IInterface parameter, but the internal handling of $14 tricks these functions into treating a string as a record...
    ...as a record with no data, hence the fake record in my original post about this issue.
     
    TLDR:
    You can pass in a string to functions that require an IInterface parameter via LinksTo if that string is the $14 non-record record in a FormID field. Those functions that return a string will return a zero-length string.
  8. Like
    fireundubh got a reaction from Beermotor in [FO4/WIP] SourceCraft - Papyrus Script Generator   
    Some of you may know I created a mod called Auto Loot for Fallout 4. Well, Auto Loot has a crazy holotape system for configuring the mod in-game, and that system involves 89 terminal scripts, 1,250 menu items, 55 global variables, 21 form lists, and 11 perks, spells, effects, actors, and actor references, and 1 cell. So, I wrote a script for xEdit to help me keep this mess under control.
    Here's what SourceCraft currently features:
    Automatically generates complete, ready-to-compile terminal scripts in Papyrus (.psc files) Support for GetGlobalValue and HasPerk menu items Uses tokenized templates (.txt files) for the overall script structure, terminal fragment functions, and code snippets Determines whether menu items are toggles or settings If menu items are toggles, determines whether menu items toggle "on" or "off" (0 or 1, AddPerk or RemovePerk) If menu items are settings, generates code that sets a GlobalVariable to the expected value If menu items are toggles or settings that should toggle or set multiple properties, generates code that uses a while loop to set those properties If menu items are settings that run on a reference, generates appropriate code (e.g., Player.AddPerk) Generates all required terminal fragment functions (no redundant code) Generates all required property declarations (no unused properties) Adds comments to terminal fragment functions with the menu item text Once I enhance, expand, and refactor the terminal script generator a bit more, I plan to break the script into modules and support other script types - where applicable.
    No screenshots - because this is all code - but here's a script I generated after getting while loop generation working.
  9. Like
    fireundubh got a reaction from Beermotor in [REL] Pyro - Papyrus Project Compiler for FO4, SSE, and TESV   
    Pyro is a Python wrapper for the Papyrus Compiler that assists with quickly compiling scripts and placing them where they need to be.
    Pyro also supports the use of Papyrus Project files, introduced with FO4, for compiling FO4, SSE, and TESV projects.
     
    Requirements
    Tested and working on Python 2.7.13 and Python 3.6.3 Downloads and installs lxml via pip on first run
    Downloads
    GitHub GitHub Raw
    Arguments
    usage: pyro.py [-g {sse,fo4,tesv}] [-i INPUT] [-o OUTPUT] [-q] [-s] [-t] [--help] [--version] required arguments: -g {sse,fo4,tesv} set compiler version -i INPUT set absolute path to input file or folder optional arguments: -o OUTPUT set absolute path to output folder (default: ..) -q report only compiler failures -s skip output validation -t show time elapsed during compilation program arguments: --help show help and exit --version show program's version number and exit
    Usage
    File: > python pyro.py -g sse -i "[...]\Scripts\Source\ExampleScript.psc" -o "[...]\Scripts" Project: > python pyro.py -g fo4 -i "[...]\Scripts\Source\User\Projects\ExampleProject.ppj"
    Game
    When the game is switched, all paths are generated using the "Installed Path" key in the Windows Registry for the respective games.
     
    File/Folder Support
    The wrapper can compile single .psc files and folders recursively. Scripts are compiled with either -op[timize] (SSE/TESV) or -op[timize], -release, and -final (FO4).
    If you want to use different flags for compiling individual files and folders, you might as well just use the compiler directly.
     
    PPJ Support
    Compiles each script individually in parallel (at least as fast as FO4's multithreaded PPJ compiler) Generates imports from both the input path and <Scripts> No changes to script names in scripts or plugins are needed The <Imports> and <Scripts> tags are required; however, you need only add the User and Base/Scripts folders as imports. In a future update, the <Imports> tag will be required only for third-party libraries, like SKSE, etc.
    The <Folders> tag is not supported.
     
    PPJ Support: Release/Final/Optimize
    Release and Final are supported only by the FO4 compiler, but Optimize is supported for all games. The PPJ parser will ignore unsupported attributes.
     
    UltraEdit Tool Configuration
     
  10. Like
    fireundubh got a reaction from lmstearn in [REL] Pyro - Papyrus Project Compiler for FO4, SSE, and TESV   
    Pyro is a Python wrapper for the Papyrus Compiler that assists with quickly compiling scripts and placing them where they need to be.
    Pyro also supports the use of Papyrus Project files, introduced with FO4, for compiling FO4, SSE, and TESV projects.
     
    Requirements
    Tested and working on Python 2.7.13 and Python 3.6.3 Downloads and installs lxml via pip on first run
    Downloads
    GitHub GitHub Raw
    Arguments
    usage: pyro.py [-g {sse,fo4,tesv}] [-i INPUT] [-o OUTPUT] [-q] [-s] [-t] [--help] [--version] required arguments: -g {sse,fo4,tesv} set compiler version -i INPUT set absolute path to input file or folder optional arguments: -o OUTPUT set absolute path to output folder (default: ..) -q report only compiler failures -s skip output validation -t show time elapsed during compilation program arguments: --help show help and exit --version show program's version number and exit
    Usage
    File: > python pyro.py -g sse -i "[...]\Scripts\Source\ExampleScript.psc" -o "[...]\Scripts" Project: > python pyro.py -g fo4 -i "[...]\Scripts\Source\User\Projects\ExampleProject.ppj"
    Game
    When the game is switched, all paths are generated using the "Installed Path" key in the Windows Registry for the respective games.
     
    File/Folder Support
    The wrapper can compile single .psc files and folders recursively. Scripts are compiled with either -op[timize] (SSE/TESV) or -op[timize], -release, and -final (FO4).
    If you want to use different flags for compiling individual files and folders, you might as well just use the compiler directly.
     
    PPJ Support
    Compiles each script individually in parallel (at least as fast as FO4's multithreaded PPJ compiler) Generates imports from both the input path and <Scripts> No changes to script names in scripts or plugins are needed The <Imports> and <Scripts> tags are required; however, you need only add the User and Base/Scripts folders as imports. In a future update, the <Imports> tag will be required only for third-party libraries, like SKSE, etc.
    The <Folders> tag is not supported.
     
    PPJ Support: Release/Final/Optimize
    Release and Final are supported only by the FO4 compiler, but Optimize is supported for all games. The PPJ parser will ignore unsupported attributes.
     
    UltraEdit Tool Configuration
     
  11. Like
    fireundubh got a reaction from RavenMind in Bethesda.net is now live, new forums coming soon   
    I am so so happy that Jive makes ignoring users so easy with Tampermonkey. I can completely hide posts by username!
    // ==UserScript== // @name Bethesda.net // @include https://community.bethesda.net/community/* // @require https://ajax.googleapis.com/ajax/libs/jquery/2.2.2/jquery.min.js // @require https://gist.github.com/raw/2625891/waitForKeyElements.js // @grant GM_addStyle // ==/UserScript== waitForKeyElements("a", removeUserPosts); function removeUserPosts(jNode) { jNode.each(function() { var ignoreUsers = ["username1", "username2"]; var userNode = $(this).attr("data-username"); if (ignoreUsers.indexOf(userNode) > -1) { $(this).parent().parent().parent().remove(); } }); } You're welcome!
  12. Like
    fireundubh got a reaction from RavenMind in [SITE] Buddah - A modding tools registry   
    The "xEditScripts" link near the bottom links to Sharlikran's repo, but I just wanted to say those are my scripts. I deleted my repo, I guess (???), so Sharlikran's fork lost the fork relationship.
    Some of my more polished xEdit scripts are here. I think I had planned to rework my entire repo (400-500 scripts) but never got around to it.
    My fork of xEdit, xEdit Pro, is not there, but it's severely behind xEdit right now. I have too many other distractions.
    Orvid's Caprica compiler for Fallout 4 Papyrus should be added.
    For non-Bethesda games:
    lslib for Divinity: Original Sin, Divinity: Original Sin Enhanced Edition, and Divinity: Original Sin 2
  13. Like
    fireundubh got a reaction from Beermotor in [SITE] Buddah - A modding tools registry   
    The "xEditScripts" link near the bottom links to Sharlikran's repo, but I just wanted to say those are my scripts. I deleted my repo, I guess (???), so Sharlikran's fork lost the fork relationship.
    Some of my more polished xEdit scripts are here. I think I had planned to rework my entire repo (400-500 scripts) but never got around to it.
    My fork of xEdit, xEdit Pro, is not there, but it's severely behind xEdit right now. I have too many other distractions.
    Orvid's Caprica compiler for Fallout 4 Papyrus should be added.
    For non-Bethesda games:
    lslib for Divinity: Original Sin, Divinity: Original Sin Enhanced Edition, and Divinity: Original Sin 2
  14. Thanks
    fireundubh got a reaction from Dragonblood in [WIPz] TES5Edit   
    Yeah, zilav has told me before that ElementByPath works for signatures, but that hasn't been my experience, so I wrote a helper function so I didn't need to think about it.
    // -------------------------------------------------------------------- // Returns any element from a string // -------------------------------------------------------------------- function GetElement(const x: IInterface; const s: String): IInterface; begin if Length(s) > 0 then begin if Pos('[', s) > 0 then Result := ElementByIP(x, s) // ElementByIP requires matortheeternal's mteFunctions library else if Pos('\', s) > 0 then Result := ElementByPath(x, s) else if s = Uppercase(s) then Result := ElementBySignature(x, s) else Result := ElementByName(x, s); end; end; You can use my dubhFunctions library (which requires mteFunctions), or add this to your own projects without the ElementByIP condition (assuming you're not using mteFunctions).
    I also implemented a similar helper function in my xEdit Pro fork (xEdit is 200-300 commits ahead of my fork now) that supports all core ElementBy* functions:
    procedure IwbContainer_GetElement(var Value: Variant; Args: TJvInterpreterArgs); var Container: IwbContainerElementRef; Signature: TwbSignature; vElement: Variant; sElement: String; basicType: Integer; begin if Supports(IInterface(Args.Values[0]), IwbContainerElementRef, Container) then begin vElement := Variant(Args.Values[1]); basicType := VarType(vElement) and VarTypeMask; if (basicType = varString) or (basicType = varUString) then begin sElement := String(Args.Values[1]); // ElementByPath if Pos('\', sElement) > 0 then Value := Container.ElementByPath[sElement] // ElementBySignature else if sElement = Uppercase(sElement) then begin Signature := StrToSignature(sElement); Value := Container.ElementBySignature[Signature]; // ElementByName end else Value := Container.ElementByName[sElement]; // ElementByIndex end else Value := Container.Elements[Integer(Args.Values[1])]; end; end; VarType and VarTypeMask aren't supported in xEdit scripts by default, so unfortunately, you'd have to add this procedure to wbScriptAdapter.pas and compile xEdit yourself to use this.
    However, when I was modding and writing xEdit scripts, I actually began to prefer using the ElementBy* functions explicitly and directly for the clarity they provided.
  15. Like
    fireundubh got a reaction from Dragonblood in [WIPz] TES5Edit   
    This is better done in Papyrus. In fact, there are mods that already achieve what you want.
  16. Like
    fireundubh got a reaction from Dragonblood in [WIPz] TES5Edit   
    http://www.delphibasics.co.uk/RTL.asp?Name=Random
    http://www.delphibasics.co.uk/RTL.asp?Name=RandomRange
    http://www.delphibasics.co.uk/RTL.asp?Name=Randomize
    I don't remember if the main branch of xEdit has these functions implemented. Just try them.
  17. Like
    fireundubh got a reaction from Dragonblood in [WIPz] TES5Edit   
    AddMessage takes a string argument and outputs that string to the information tab/console.
    See the link I posted for tables of functions and their return types.
    Also, looking at the xEdit source:
    ElementByPath will call ElementByName if the value is not a path. Neither ElementByPath nor ElementByName call ElementBySignature, so I don't see how they'd be able to get elements by signatures.  
  18. Like
    fireundubh got a reaction from Dragonblood in [WIPz] TES5Edit   
    You need to learn to debug your own scripts.
    Simplest way is to store any value retrieved with a function in a variable and print the values of those variables with AddMessage immediately after they're set.
    You also need more error handling. For example, if ElementBySignature(la, 'TPLT') gets an unassigned element, LinksTo will fail, and tpl will be null. LinksTo might throw an exception as well. So, you need to be sure to validate any data you pass forward.
    Also, keep this reference handy: https://www.creationkit.com/index.php?title=TES5Edit_Scripting_Functions
    In my experience, the ElementBy* functions are sensitive to the value type, so for example, you should be using ElementBySignature(la, 'TPLT') because 'TPLT' is a signature and not a path.
  19. Like
    fireundubh reacted to Nebulous112 in [WIPz] TES5Edit   
    Lol you ask for help to make a script to update your mod. Someone takes the time to write a script for you to do what you need.
    Then you tell the person to test it themselves because you are not familiar with scripting.

    *Facepalm*
  20. Like
    fireundubh reacted to Kesta in [RELz] Just Do It   
    "A few times ago, I came back home from work and was a bit hungry. There was an apple on the table. So I ate the apple.
    Then, I started to play Skyrim, as per usual. iNeed made my character hungry, just like I was a moment ago. There was an apple on the table. But I couldn't just eat the apple, I had to put it in my inventory first... Pretty dumb heh ?
    Well, I decided to make a mod about that."
    And that's about it. 
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
    ...
     
     
    Ok, some details
     
    The mod allow you to press a hotkey that act as modifier for interactions with items founds directly in the world (foods, potions, weapons, outfits, ...). When the hotkey is down, the interaction with the item is modified to something that allow you to use it directly (equipping a weapon, eating an onion, ...) instead of having to put it in your inventory first.
     
    Works for :
     - Weapons / armors / clothing /accessories -> Equip
     - Potions -> Drink
     - Food/Beverages -> Food/Drink
     - Poisons -> Apply
     
    With proper support for crime events (Except that since you already consumed items, NPCs won't take them back from you... that would be disgusting. brrr)
     
    That's obviously not as fully featured as real life could be, where you could also eat your weapons (you still can't roleplay as a sword swallower...), but hey, it's not that bad  
    AFKMods linky : http://www.afkmods.com/index.php?/files/file/1844-just-do-it/
  21. Like
    fireundubh got a reaction from Sclerocephalus in [HOW-TO] FO4: Papyrus: Sharing Code Between Scripts and Fragments   
    I've been reworking Auto Loot to dynamically support DLC while not actually requiring DLC.
     
    I've learned some things that might be useful to you if you want to share code between your scripts. I'll use examples from my scripts.


    Create a quest
     
    In order to share code between scripts, you need to:
    Create a quest that starts enabled. Attach a library script that will contain all of your shareable code to that quest. Make note of the Form ID of the quest record. The load order (first two digits) does not matter.  
    Your library script
     
    In your library script, add a GetScript() function like this:
    dubhAutoLootLibraryQuestScript Function GetScript() Global Return Game.GetFormFromFile(0x00019FB7, "Auto Loot.esp") as dubhAutoLootLibraryQuestScript EndFunction The GetFormFromFile() function uses the name of a plugin to retrieve the load order to be used with the Form ID, so make sure you do not include the load order in the Form ID.


     
    Update your scripts
     
    In the scripts with which you want to share code from your library, create a locally scoped variable. For example:
    dubhAutoLootLibraryQuestScript AutoLoot = None The data type should be the name of your library quest script, and the reason why we set the value of the variable to None is simply to instantiate the variable.
     
    We want the variable to be scoped outside of any events or functions because we don't want to declare the variable in every function or event where we want to use code from the library.
     
    In the entry point to your script, such as OnEffectStart() in an ActiveMagicEffect script, assign the library script to that variable using the GetScript() function.
    Event OnEffectStart(Actor akTarget, Actor akCaster) AutoLoot = AutoLoot:dubhAutoLootLibraryQuestScript.GetScript() If AutoLoot StartTimer(dubhAutoLootDelay.Value, dubhAutoLootTimer) Else Debug.Trace(Self + " Could not find 0x00019FB7 in file: Auto Loot.esp") EndIf EndEvent
    Using library code

    Now, you can use functions, properties, etc., from the library script wherever you want in your ActiveMagicEffect script.
    Event OnTimer(Int aiTimerID) ;...snip... If LootArray.Length > 0 LootArray = FilterArray(LootArray) AutoLoot.LootContainerArray("Container", LootArray, dubhAutoLootPerk) EndIf ;...snip... If AutoLoot StartTimer(dubhAutoLootDelay.Value, dubhAutoLootTimer) Else Debug.Trace(Self + " Could not find 0x00019FB7 in file: Auto Loot.esp") EndIf EndEvent Ta-da! You'll need to do this for every script in which you want to share code from your library.


     
    Sharing code with fragment scripts
     
    You can also do something similar with fragment scripts. Here's a straightforward example:
    ScriptName AutoLoot:Fragments:Terminals:TERM_dubhAutoLootMenuContain_010026F4 Extends Terminal Hidden Const ;...snip...; ;BEGIN FRAGMENT Fragment_Terminal_06 Function Fragment_Terminal_06(ObjectReference akTerminalRef) ;BEGIN CODE AutoLoot:dubhAutoLootLibraryQuestScript AutoLoot = Game.GetFormFromFile(0x00019FB7, "Auto Loot.esp") as AutoLoot:dubhAutoLootLibraryQuestScript AutoLoot.ConfigureSupportForDLC() ;END CODE EndFunction ;END FRAGMENT ;...snip...; If you're new to Papyrus in Fallout 4, this probably doesn't look that straightforward, right?
     
    You'll note from the ScriptName that I'm using project folders (Scripts\User\AutoLoot\Fragments\Terminals).
     
    In order to declare the library script variable in a script contained in a different folder, you need to declare the variable's data type using the path to the library script.
     
    In Papyrus, colons are backslashes. These are equivalent:
    System path: AutoLoot\dubhAutoLootLibraryQuestScript[.psc|.pex] Papyrus path: AutoLoot:dubhAutoLootLibraryQuestScript So, remember that the data type is also the path to the script.
     
    In fact, this is true for every data type, excluding perhaps the standard data types like Bool, Int, Float, and String.
     
    You just don't notice this at first because Bethesda placed scripts like Actor.psc, Formlist.psc, etc. in the root Scripts folder to make things easier on everyone.
     
    I hope that helps.
  22. Like
    fireundubh got a reaction from Kesta in [RELz] Locky Bas***d / Locky You   
    Did you deliberately exclude XP rewards? If not, I have a function you can use.
     
    Bool Function UnlockForXP(ObjectReference objContainer)
  23. Like
    fireundubh got a reaction from Drakemasta in Downvotes as a Systematic Method of Discrimination and Oppression   
    1 link karma (LOL)
    2,249 comment karma
    https://www.reddit.com/user/Arthmoor
     
     

    Don't dismiss the allure of preaching to the choir, yes men, and groupthink. #narcissism
  24. Like
    fireundubh got a reaction from lmstearn in [RELz] fireundubh's Skyrim Mods   
    I've put up a simple website with brief descriptions and download links for all of my Skyrim mods.
     
    http://fireundubh.github.io/skyrim/
     
    All mods have been updated to support USLEEP, excluding King of Thieves and Master of Disguise, which have some bugs I need to work out before re-releasing them.
  25. Like
    fireundubh got a reaction from Kesta in The Big Fallout 4 Thread   
    Hai, guys! Why do I have to keep re-enabling my mods!? Should I search the forum for an answer? Could the answer be in one of the many threads on the first page named "disabling" something? I don't think I'll find the answer here or anywhere. Nobody had this problem before me. Please just help me. I don't know what to do. Tell me what to do. Why is this so hard? Why did they make this so hard? Is it intentional? I think it's intentional, guys. They want to make mods harder to use so they can sell more DLC, which are just mods anyone can make. Bethesda... Grrr!! Gamebryo! Can you make me a mod? It's really easy. Here's five paragraphs on what I want it to do. Can you make it now? Please? Oh, can you change Survival Mode back, too? And overhaul Workshop Mode? I'm not going to buy any more Bethesda games until I get Survival Mode back. What do you mean all I need to do is make plugins.txt not read only? That's stupid. You're stupid. I made it read only. I made all the files read only! The game should work! That's what I was told. Not by Bethesda, but I won't name who. Bethesda doesn't know anything about modding. They're awful, terrible people who can't make a game that works. Why would I listen to them anyway? Look what they did to Survival Mode. Guys, I can't connect to Bethesda.net anymore. It's broken! Oh, look, the people at the Nexus gave me the solution before any of you losers did. Big surprise there. Can you make me a mod? This is really hard. #TheVoices #Halp

Support us on Patreon!

Patreon
×
×
  • Create New...