-
Notifications
You must be signed in to change notification settings - Fork 4
Scripting Language
Hyper edited this page May 20, 2020
·
19 revisions
-
BeginBlock(archive)
- Unpacks an archive to a temporary location. This should be used before modifying files inside archives. -
Rename(old|new)
- Renames a file. -
RenameByExtension(location|old|new)
- Renames all files with the specified extension to the new extension (must specify a directory, rather than a file). -
Delete(location)
- Deletes a file or folder.¹ -
Copy(location|new|overwrite)
- Copies a file to a new location, with an overwrite function. -
EndBlock(archive)
- Repacks an archive from the temporary location created by BeginBlock().
-
DecryptExecutable()
- Decrypts the game's XEX/EBOOT (Xbox 360/PlayStation 3 executable respectively). -
DecompressExecutable()
- Decompresses the game's XEX (Xbox 360 executable). -
WriteByte(file|offset|byte)
- Writes a byte to the specified offset in the file. -
WriteNullBytes(file|offset|count)
- Writes null bytes to the specified offset in the file. -
WriteBase64(file|data)
- Writes Base64 data to a binary file. -
WriteNopPPC(file|offset)
- Writes a NOP value to the specified offset at the file path. -
WriteTextBytes(file|offset|text)
- Writes ASCII text in bytes to the specified offset in the file. -
ParameterAdd(file|parameter|value)
- Adds a Lua parameter.¹ -
ParameterEdit(file|parameter|value)
- Edits a Lua parameter.¹ -
ParameterRename(file|old|new)
- Renames a Lua parameter.¹ -
ParameterErase(file|parameter)
- Removes all instances of a parameter from a Lua file.¹ -
PackageAdd(file|key|event|reference)
- Adds a PKG event.¹ -
PackageEdit(file|key|event|reference)
- Edits a PKG event.¹ -
TextAdd(file|name|placeholder|text)
- Adds an MST entry.¹ -
TextEdit(file|name|placeholder|text)
- Edits an MST entry.¹ -
StringReplace(file|old|new)
- Replaces a string.¹
1 - works recursively (if no file name is specified and the path exists, it will process the function for every file in the directory).
-
All Systems:
- Specifies that the below code is for All Systems. -
Xbox 360:
- Specifies that the below code is only for the Xbox 360. -
PlayStation 3:
- Specifies that the below code is only for the PlayStation 3.
NOTE: core
is automatically replaced with the detected system (xenon
/ps3
).
BeginBlock("core\archives\player.arc")
Rename("core\sound\HD_SEGA.wmv"|"core\sound\bruh.wav")
RenameByExtension("core\sound"|"*.xma"|".xma_back")
Delete("core\sound\stg_twn_shop.xma")
Copy("core\sound\shadow_theme.xma"|"core\sound\theme_shadow.xma"|true)
EndBlock("core\archives\player.arc")
DecryptExecutable()
DecompressExecutable()
WriteByte(Executable|0xB10DB3|0x29)
WriteNullBytes(Executable|0x6852A|57)
WriteTextBytes(Executable|0x365AA|"csc/scene_csc_a.lua")
WriteBase64("core\shader\std\BurnoutBlurFilter.fxo"|"soMEBasE64stRINgtHAtIsTOoLoNGtOfiTINThIsexAMPLe==")
WriteNopPPC(Executable|0x217710)
ParameterAdd("core\player\snow_board.lub"|"c_hair"|"{ "SomeHairBone" }")
ParameterEdit("core\player\amy.lub"|"c_jump_run"|"9 * (meter / sec)")
ParameterRename("core\player\silver.lub"|"c_jump_run"|"c_jump_banana")
ParameterErase("core\player\silver.lub"|"c_jump_banana")
TextAdd("core\text\english\msg_mainmenu.e.mst"|"banana"|"picture(button_a)"|"$ this is pointless")
TextEdit("core\text\english\msg_mainmenu.e.mst"|"kingdomvalley"|""|"TOTALLY A LEGIT STAGE")
PackageAdd("core\player\sonic_new.pkg"|"motion"|"thing"|"player/sonic_new/blah.xnm")
PackageEdit("core\player\snow_board.pkg"|"motion"|"against"|"player/sonic_new/so_brd_collision_Root.xnm")
StringReplace("core\player\sonic_new.lub"|"other_module_sonic_homing"|"other_module_blaze_homing")
All Systems:
DecryptExecutable()
Xbox 360:
WriteByte(Executable|0xB10DB3|0x29)
PlayStation 3:
WriteByte(Executable|0xC1837A|0x32)
- Setup and Usage
- For Mod Developers
- For Patch Developers