Provides a common set of tools to be used with Papyrus. Includes temporary global variables, 2D-arrays, maps, extensive file management, console interaction and more.
For PCL Version Of "Reset Armor" Optional File & Adjustable Tesla Coil Damage Option In FOMOD
Permissions and credits
Credits and distribution permission
Other user's assetsAll the assets in this file belong to the author, or are from free-to-use modder's resources
Upload permissionYou are not allowed to upload this file to other sites under any circumstances
Modification permissionYou must get permission from me before you are allowed to modify my files to improve it
Conversion permissionYou are not allowed to convert this file to work on other games under any circumstances
Asset use permissionYou must get permission from me before you are allowed to use any of the assets in this file
Asset use permission in mods/files that are being soldYou are not allowed to use assets from this file in any mods/files that are being sold, for money, on Steam Workshop or other platforms
Asset use permission in mods/files that earn donation pointsYou are not allowed to earn Donation Points for your mods if they use my assets
Console modding permissionThis mod won't work on consoles or would not be acceptable on Bethesda.net according to their rules
Author notes
This author has not provided any additional notes regarding file permissions
Please log in to find out whether this mod is receiving Donation Points
Changelogs
Version 1.4.3
Fixed a crash when filtering by form lists in any of the events
Added more null-pointer checks in general :Pain:
Version 1.4.2
Fixed a crash when calling System:Projectile.GetData with a null MuzzleFlashLight
Version 1.4.1
Fixed a crash due to compatibility problems with Magic Effect and Spell Engine Fixes
Version 1.4.0
Completely overhauled the event system - events will now persist for the entire game session, if not unregistered, and they can be registered for both local and global callback functions
Added the OnUserEvent, OnDeleteGame, OnPostLoadGame, OnPostSaveGame, OnPreLoadGame, OnPreSaveGame, OnActorDeath, OnActorEquipUnequip, OnFurnitureEnterExit, OnCellAttachDetach, OnContainerChange, OnMagicEffectApply, OnObjectActivate, OnObjectHit, OnObjectLoadUnload, OnHUDColorUpdate, OnMenuOpenClose, OnTutorialTrigger, OnLockPick, OnPerkPointIncrease, OnTerminalHack, OnPipBoyLightChange and OnPowerArmorLightChange events to System:Events
Added all of the game's Encounter Zone, Faction and MagicEffect functions
Added GetNthEntryType and GetNthEntryFunctionType to System:Perk
Added Get-, SetProperties and Get-, SetMaterialSwapModel to System:Form
Added Get- and SetPairs to System:MemVar
Added Get-, SetEntries and SetPairs to System:IO:INI
Added Escape and Unescape to System:Regex
Added some integer equivalent functions for previously float-based functions in System:Math, like Abs, Min and Max
Changed Get-, SetPickupSound, Get-, SetPutdownSound to Get-, SetPickupPutdownSounds in System:Form
Changed System:Form.GetAllByTypes to use only one form type filter and renamed the function to GetAllByType
Changed System:Cell.GetRefsByTypes to use only one form type filter and renamed the function to GetRefsByType
Changed the return value of the System:Internal.GetVersion function from a float to a struct
Updated the custom message box functions in System:Message to allow for unlimited buttons
Split the seeded and non-seeded number randomizer functions in System:Math
Moved the System:IO:INI:Pair struct to their own script, so that it can be better shared by others
Moved GetCurrentCrosshairRef from System:ObjectReference to System:Game
Renamed the script System:GlobalEvents to System:Events
Removed System:Random for the meantime, since the outputs weren't truly based on the provided seed
Fixed null arrays causing CTDs for any of the array parameters
Fixed Get- and SetNthEntrySpell in System:Perk not working
Tons of other changes, improvements and optimizations
Version 1.3.1
Fixed unbound actor value functions in System:Perk
Version 1.3.0
Remade most form scripts to use a struct to represent their values - this should greatly improve performance and simplify internal function definitions
Added a Message script that allows for the creation of custom message boxes with up to four buttons and a callback
Added all of the game's AimModel, Component, Enchantment, Explosion, Message and MiscObject functions
Added some of the game's WorldSpace functions
Added functional IsLower, IsUpper, ToLower and ToUpper to System:Strings and removed the similar ones from System:Char
Added GetCurrentCrosshairRef, GetDroppedItemSource and GetAshPileSource to System:ObjectReference
Added GetPairs to System:IO:INI
Added a CrosshairRefChange event to System:GlobalEvents
Added OnPostGameStart as an event to the script runner
Moved Get- and SetCraftSound from System:Potion to System:Form
Removed Get-, SetIsDeleted, Get-, SetIsPlayable Get- and SetIsObstacle from System:Form
Removed the form functions from System:IO:JSON, since the var ones can do the same
Fixed System:Form.GetByEditorID returning none if the form was not bound already
Fixed Get- and SetNthEntryValue in System:Perk not working
Fixed GetDirectories and GetFiles in System:IO:Directory only returning the file/folder name instead of the name plus the relative path
Fixed the IO write functions failing if the target file does not exist
Version 1.2.0
Added a JSON script that can serialize and deserialize any type, including forms, arrays and structs
Added all of the game's Activator, Book, Container, Door and Holotape functions
Added GetIsDeleted, SetIsDeleted, GetIsPlayable, SetIsPlayable, GetIsObstacle and SetIsObstacle to System:Form
Added AddEditorForms and AddScriptedForms to System:FormList
Added HasPart, AddPart and RemovePart to System:Outfit
Added locks to all filesystem related functions to provide internal thread-safety
Added an optional is set parameter to System:Form.FindAllByFlag
Added optional default value parameters to all get functions in System:IO:INI
Also added these parameters to all TryParse methods
Changed GetBool and SetBool in System:IO:INI to use their respective integer value instead of a boolean string conversion
Moved the regex functions from System:Strings to their own script
Renamed System:Form.IsGenerated to IsCreated
Removed System:Form.Delete
Removed the EditorID loading of some redundant types, like for ingredients and soul gems
Fixed two unbound functions in System:Potion
Version 1.1.2
Fixed certain VATS sounds being muted - Removed loading of more sound EditorIDs for this
Version 1.1.1
Fixed a CTD when opening the Pip-Boy - Removed loading of sound EditorIDs for this
Version 1.1.0
Added a command runner
Added all of SKSE's Ammo, Cell, Flora, Outfit, Perk, Potion, Projectile and Spell functions, with many additions
Added IsGenerated, IsInMod, GetModName, FindAllByFlags, HasKeywordString, GetKeywordCount, GetNthKeyword, GetKeywords, GetEquipType, SetEquipType, GetPickupSound, SetPickupSound, GetPutdownSound and SetPutdownSound to System:Form
Added GetEditorSize and GetTotalSize to System:FormList
Added an optional trim string parameter to Trim, TrimStart and TrimEnd in System:Strings
Added the prefix "aui" to most unsigned integer parameters
Changed the parameters of the "GetAll*" functions in System:Form to white- and blacklists
Renamed System:FormList.GetForms to GetEditorForms
Renamed System:Console.ReadLine to GetLine
Renamed "*TypeID*" to just "*Type*" in System:Form
Renamed "*TypeID*" to "*RawType*" under System:Reflection
Removed GetSelectableRefs, GetSelectedRef, SetSelectedRef and ClearSelectedRef from System:Console because they only work if the menu was opened once and made the remaining functions all work from the start
Expanded the loading of EditorIDs to also include references and sounds
Fixed the filter by keywords functions in System:Form not working on references
Version 1.0.0
Initial release
Donations
No donations accepted
Features
Offers over 1000 common functions to be used with Papyrus, the game's scripting language, with the goal of making it feel less like a language from the last century and enhancing its functionality
Filesystem management within the game's root folder and its subdirectories
Reflection to modify scripts at runtime
Restoration of EditorIDs - They can now be used in-game, via script commands, in the console, and with mods that require this feature, like Base Object Swapper and Spell Perk Item Distributor
A simple function runner is also included
Spoiler:
Show
Create a file with a ".ini" extension under "Data/PCL/Functions".
Use the following template: [MyScript.OnGameStart] sEventName = OnGameStart sScriptName = MyScript sFunctionName = OnGameStart
Change the values to your needs and be sure that the function in Papyrus has no arguments. You can have multiple function calls by adding new sections. Each section has to be unique and they are sorted alphabetically.
Events:
OnGameStart: Runs once on game start
OnGameLoad: Runs on every game load
OnPostGameStart: Runs on every game load after game start
And a command runner too
Spoiler:
Show
Create a file with a ".txt" extension under "Data/PCL/Commands". In there, you can write any commands that the console would normally support and they get executed once the main menu is opened. To run multiple commands per file, separate them with a new line.
Included Scripts
IO
Directory - Read from and write to directories
File - Read from and write to files
INI - Read from and write to INI files
JSON - Serialize and deserialize any kind of data using the JSON format
Path - Queue paths: GetRelative, GetFileName, GetDirectoryName and more
Activator - Contains all of the game's activator functions
AimModel - Contains all of the game's aim model functions
Array - Includes Create, Copy, Repeat and modifications without the 127 size limit