ECMAScript-Language module

Note that this module is still under development, so there is no gurantee that methods will work without any errors.

Products with the Venice 8 module have a different directory archive structure compared to the common modules Venice 6 or Venice X. Notably, the stored files in Venice 8 modules primarily consist of graphical resources and script files written in ECMAScript, also known as ecma.

To extract and uncompress the stored files, you can utilize the ISUTool tool or directly execute the fsapi.isu module. The files that can be used within this module have the .es.bin suffix, where es refers to ECMAScript.

Although there is no available binary structure definition for ECMAScript files, this module attempts to read and extract data from the input files. Decompilation of .es.bin files back to ECMAScript code might be considered as a potential feature for future releases.

Module Contents:

Basic usage (>=0.3.0)

from fsapi import ecmascript

# decompile the byte code from the given file
decompiler_path = 'decompiler/ecma-decompiler'
with ecmascript.Decompiler(decompiler_path, '<file>') as dc:
  # retrieve the source code as a string with
  code = str(dc)
  # or directly with
  code = dc.code