Skip to content

feat: Environment #6

@TechHog8984

Description

@TechHog8984

Some extra environment functions I want:

  • environment library:
    • registeralias(string) - for example, environment.registeralias("replaceclosure"); now replaceclosure will point to hookfunction
    • registerall - register all aliases
    • many of the below names are aliases and will not show up as-is in the environment by default
  • bytecode stuff:
    • dumpfunction - returns a proto's Luau bytecode
    • deserializebytecode - deserialize Luau bytecode to a Proto object
    • serializeproto - serialize Proto object to Luau bytecode
    • writefunctioncode - set a proto's Luau bytecode (note that this is super unsafe and thus should either have extensive safety checks or be under a define or flag or option)
  • setclipboard & getclipboard, both under "allow clipboard" window option and each separately toggleable themselves
  • identifyexecutor
  • hookfunction, restorefunction, isfunctionhooked
  • hookmetamethod
  • gethui
  • islclosure, iscclosure
  • newcclosure, isnewcclosure, getcclosureoriginal
  • newlclosure, isnewlclosure
  • getgc
  • filtergc
  • getthreadidentity, setthreadidentity, printidentity
  • getallthreads
  • getreg
  • SEE feat: debug library #3
  • getconnections (returns a list of the below wrapper), firesignal, [hooksignal, issignalhooked, and unhooksignal (from wave) ]
  • connection wrapper:
    • wrapconnection(rbxscriptconnection)
    • Enabled bool, Enable(), Disable(), Fire(...), Disconnect(), Signal rbxscriptsignal, Function closure
  • getcallbackvalue
  • isscriptable, setscriptable
  • gethiddenproperty, sethiddenproperty
  • getinstances, getnilinstances
  • iswindowactive - is the window focused
  • getnamecallmethod, setnamecallmethod
  • getrawmetatable, setrawmetatable
  • setsafeenv, issafeenv
    • aliases: setuntouched, isuntouched
  • getgenv, getrenv, gettenv
  • isreadonly, setreadonly (aliases; scripts should use table.isfrozen, table.freeze, (CUSTOM) table.unfreeze, and (CUSTOM) table.setfrozen)
  • setfpscap, getfpscap
  • cloneref, compareinstances
  • cache:
    • invalidate
    • iscached
    • replace

The best general reference is probably https://docs.potassium.pro/api-reference/

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions