local Params = {
RepoURL = "https://raw.githubusercontent.com/luau/SynSaveInstance/main/",
SSI = "saveinstance",
}
local synsaveinstance = loadstring(game:HttpGet(Params.RepoURL .. Params.SSI .. ".luau", true), Params.SSI)()
local Options = {} -- Documentation here https://luau.github.io/UniversalSynSaveInstance/api/SynSaveInstance
synsaveinstance(Options)
Or shortly USSI, a project aimed at resurrecting saveinstance function from Synapse X Source 2019 & Other Executor Source leaks :trollface:.
Reason: Many Executors fail miserably at providing good user experience when it comes to tinkering with saving instances.
[!WARNING] As stated under the Section 7 (b) in the LICENSE:
- You MUST always include the following Credit string:
UniversalSynSaveInstance https://discord.gg/wx4ThpAsmw
- You are NOT allowed to claim authorship of the source code provided in this repository
- You MUST always include the following License
[!TIP] Important part about this saveinstance is that it doesn't modify anything, therefore reduces the amount of detection vectors by a lot.
You can also enable theSafeMode
option to completely bypass any detections and save ANY game!
If this script is helpful to you, please click⭐ Star
in the upper right corner of the page to support it, thank you!
https://discord.com/invite/wx4ThpAsmw / https://discord.gg/wx4ThpAsmw
[ ] Look into adding support for Binary Format Output (rbxl/rbxm)
[x] Add custom decompiler in case executor doesn't have one but has getscriptbytecode (UMF)
[x] Add custom timeout logic for decompiler instead of relying on executor to have one
[x] Add continue
where needed
[ ] Add Documentation similar to KRNL Docs or Synapse X Docs / Synapse X Docs Old
[ ] Merge SharedStrings and sharedstrings tables
[x] Add fallback function for appendfile (whether through storing current xml as string or with use of readfile) Removed Appendfile entirely
[x] Add getproperties as fallback for specialinfo
[x] Add Redirects to some special (in a bad way 😡) values, more info @ PropertyPatches v1,PropertyPatches v2+PropertyPatches v3, otherwise they will fallback to default when file is opened Relying on CanSave instead
[ ] Add more Fixes for Errors that can pop up during opening process
[x] Add Optional tags support
[ ] Add readbinarystring or readbinarystringpropertyvalue/readbspval/getbspval (elysian) as fallback for gethiddenproperty
[ ] Add table.clone instead {} in some cases if possible
[ ] Avoid scanning for default values of properties if those properties won't get serialized anyway (e.g. don't have a Descriptor)
[x] Add --!native tag just in case
[x] Auto-Detect DataTypes/ValueType Categories of Properties (CFrame, UDim2 so on) Full API Dump Solves this ?
[x] Bring said DataType serializer into an outside function
[-] Bypass NotCreatable by hardcoding links/references/indexes to said Classes Should be Solved by IsPropertyModified
[x] Check if table.concat is actually the fastest way as compared to other alternatives (IT'S NOT)
[x] Do clean-up in inheritor & (API Dumps solve this, illogical) automatically assume the top-most class that owns the property, while also cleaning up said property from classes that inherit from it
[x] Fix indexes being mixed up after table.remove shifting
[x] Hidden properties
[ ] Support for Model files:
[x] Possibly convert to non-Name tables & use instance references instead (Perhaps make a config Bool Toggle for this, false by default), ex. DecompileIgnore = {game.CoreGui}
[x] Remove Useless tables & functions of specialinfo Repurposed
[x] Implement Luau Syntax (important for performance!):
next
, ipairs
& pairs
if-then-else
expressions[ ] Speed things up as much as possible
[x] Support for NotScriptable Properties
[ ] Support for as many KRNL-like saveinstance Options & UNC:
[ ] Support for as many Executors as possible (🤢🤮)
[x] Use getspecialinfo fallback function carefully as it's hardcoded Useless because there's no way to tell if the Property Values of those instances are default or not
[x] Isolators must clear
[-] Store all functions outside that are used during saveinstancing for sake of performance Arguable
[ ] Remove buffersize, savebuffer & so on for sake of performance by concatenating table.concat proved faster in the case of huge amount of concatenations
[ ] Make sure BinaryStrings are compared to Defaults properly (aka in same format)
[ ] Add Option to restart saveinstance from the point that it crashed on (perhaps by skipping)
[ ] Check out DataType Exceptions
[x] Add README Similar to current Synapse
[x] Ignore all properties of instances that aren't Local or Module Scripts except Name if mode is set to "scripts" IgnorePropertiesOfNotScriptsOnScriptsMode
[ ] Maybe modes should do more than just determining the list of instances to save, like changing IgnoreDefaultProperties to false if mode is "full" for example
[x] Add Support for SharedStrings
SharedString
, this behavior is not documented anywhere but makes sense (Could create issues though, due to potential ValueType mix-up). By replacing <BinaryString name="Tags">Base64EncodedValue</BinaryString>
with <SharedString name="Tags">UniqueIdentifierForSharedString</SharedString>
& putting <SharedString md5="UniqueIdentifierForSharedString">Base64EncodedValue</SharedString>
into SharedStrings container you can achieve this amazing behaviour. This should be only enabled using an optional setting[x] Add Lua & Luau versions instead of merged (WARNING: LUAU WILL ALWAYS BE MORE UPDATED THAN LUA VERSION, lua version exists just for the sake of old & bad executors, ask devs of your executors to support luau as its latest & greatest)
[x] Add Support for multiple Instances to be saved as a model IsModel = true & ExtraInstances
[x] Do something about devs renaming Services therefore bypassing Ignore lists (CoreGui/CorePackages are not affected)
[ ] Custom fallback Decompiler for ModuleScripts using require and then iterating through it, gathering all info about functions using getupvals/getprotos/getconsts, converting all DataTypes using tostring or Descriptors, and then perhaps converting to JSON. (Make use of op-codes from Dex?) !!!
[ ] Check out varios Leaked Executors (Especially their Init / Lua scripts) to expand knowledge on the whole subject of saveinstance
[ ] Fix Player's Characters not being visible (must Refresh MeshId)
[ ] Be able to exclude / blacklist any mentions of certain string in other strings
[ ] Force disable ParticleEmitters in case something like IgnorePropertiesOfNotScriptsOnScriptsMode is enabled (they stack in one place and create huge lag)
[ ] Be able to specify which special properties you want saved (to avoid saving all)
[!IMPORTANT] This document is based largely on the efforts of @Anaminus & @Dekkonot, authors of the Roblox Format Specifications. Additional resources include:
- Syngp Synapse X Source code 2019 for base saveinstance code (extended by @mblouka & @Acrillis)
- Moon/LorekeeperZinnia for being the original creator of saveinstance that was used in Synapse X, Elysian and many others. As well as being an inspiration for this project.
- Rojo Rbx Dom Xml for being a fallback documentation in case something wasn't clear in the Roblox Format Specifications
- Roblox File Format for a list of redirects of old/deprecated xml properties that still use the old tag values
- Roblox Client Tracker for an extended & close to full JSON Api Dump (with hidden properties & default values)
*** View source code of this file for more credits