Lightpath 0.79 | MajiroArc v1 & v2 This model will process MjArc files and show you file names, offsets, data and will even let you extract them! It supports both version 1 and version 2 formats and will automatically choose one based on the file's signature. This script is lpx-ready and can be embedded to extract data by users with no special knowledge of Lightpath. == Options == lpx.DataPath = *\files\file\data\bytes$start lpx.DataExpr = lpx.NamePath = ..name lpx.NameExpr = 'shift-jis' charset lpx.DefaultFiles = scenario*.arc == Model == ; 32-bit value. (dword) % ANY ANY ANY ANY ; End Of File entry for v1. (endRec) . dword "hash" x 00 00 00 00 . dword "offset" ; Version 1 of MajiroArc "v1" % MajiroArcV1.000 \0 ; -- Archive Header -- . dword "fileCount" . dword "nameOffset" . dword "dataOffset" ; -- File Table (hash, offset, size) -- . "files" = "file"? iteration .fileCount$start toint < . dword "hash" . dword "offset" END . endRec "+files\file" .? ? offset nameOffset$start toint <> WARN "File table ended on wrong offset!" ; -- File Name List -- . names = "+files\file[n]\name"? iteration fileCount$start toint < % [^\0]+ END x 00 END .? ? offset dataOffset$start toint <> WARN "Name table ended on wrong offset!" ; -- Data Section -- . data = END? iteration fileCount$start toint = "+files\file[n]\data" = . ? .offset$start toint tooffset . "bytes"? ..file[.n+1]\offset$start toint skipto ; Version 2 of MajiroArc @v1 "v2" % MajiroArcV2.000 \0 files file . "size" % ANY ANY ANY ANY (@endRec) ; Clearing End Of File entry - v2 has none. data @data @bytes? .size$start toint skip ; Suppressing "input left" warning. . ? length skip === Supported == % MajiroArcV [12] .000 \0