Author Topic: FF7Tools lzss unclear syntax.  (Read 1266 times)

NERV Agent

  • Cool newbie
  • *
  • Posts: 91
  • Karma: 4
  • GOD'S IN HIS HEAVEN. ALL'S RIGHT WITH THE WORLD.
    • View Profile
FF7Tools lzss unclear syntax.
« on: 2016-04-24 23:33:21 »
I extracted "MOVIE/OPENING.BIN" from an FF7 PSX disc. I used "unbinlz" to decompress it, and managed to edit one of the ".data" files that came out to my liking.

But how exactly do I compress all those data files back into "OPENING.BIN"?

The README says this:

Quote
lzss / unlzss
-------------

Usage: lzss [OPTION...] <fromfile> <tofile>
  -V, --version                   Display version information and exit
  -?, --help                      Show this help message

Usage: unlzss [OPTION...] <fromfile> <tofile>
  -V, --version                   Display version information and exit
  -?, --help                      Show this help message

The 'lzss' and 'unlzss' tools compress and decompress individual files
compressed with the game's version of the LZSS algorithm.

Examples for such files are the field maps (FIELD/*.DAT) and all files
having the .LZS extension.

The command line seems to specify a single file, and not a bunch of files (or a whole directory). How do I compress all the ".data" files back into "OPENING.BIN"?

I tried doing this, but got this:

>python lzss OPENING_00.data + OPENING_01.data + OPENING_02.data + OPENING_03
.data + OPENING_04.data + OPENING_05.data + OPENING_06.data + OPENING_07.data +
OPENING_08.data + OPENING_09.data + OPENING_10.data + OPENING_11.data + OPENING_
12.data + OPENING_13.data + OPENING_14.data + OPENING_15.data + OPENING_16.data
+ OPENING_17.data + OPENING_18.data + OPENING_19.data + OPENING_20.data + OPENIN
G_21.data + OPENING_22.data + OPENING_7472_0.data OPENING.BIN
Usage: lzss [OPTION...] <fromfile> <tofile>
  -V, --version                   Display version information and exit
  -?, --help                      Show this help message

Error: Unexpected extra argument 'OPENING_01.data'

So I try putting it in brackets, and got this:

>python lzss <OPENING_00.data + OPENING_01.data + OPENING_02.data + OPENING_0
3.data + OPENING_04.data + OPENING_05.data + OPENING_06.data + OPENING_07.data +
 OPENING_08.data + OPENING_09.data + OPENING_10.data + OPENING_11.data + OPENING
_12.data + OPENING_13.data + OPENING_14.data + OPENING_15.data + OPENING_16.data
 + OPENING_17.data + OPENING_18.data + OPENING_19.data + OPENING_20.data + OPENI
NG_21.data + OPENING_22.data + OPENING_7472_0.data> <OPENING.BIN>
< was unexpected at this time.

I scoured Google and there is no information on the command line syntax for this program. It can't be unknown. How do you use this thing?!?
« Last Edit: 2016-04-24 23:38:46 by NERV Agent »

NFITC1

  • No life
  • *
  • Posts: 2758
  • Karma: 61
  • I just don't know what went wrong.
    • View Profile
    • WM/PrC Blog
Re: FF7Tools lzss unclear syntax.
« Reply #1 on: 2016-04-25 02:04:12 »
try:

Code: [Select]
python lzss OPENING*.data OPENING.BIN

sithlord48

  • No life
  • *
  • Posts: 1427
  • Karma: 33
  • Dark Lord of the Savegame
    • View Profile
    • Blackchocobo
Re: FF7Tools lzss unclear syntax.
« Reply #2 on: 2016-04-25 11:57:24 »
seams very strightfoward to me..

1. when you see <INFILE> <OUT> that a place holder you replace with what your doing.. so NO < or >
2. why did you use a + thats not going to work  with any cli program.
3. the error clearly states that the second file is unexpected input  . if your gonna use cli programs learn to read the errors.

NERV Agent

  • Cool newbie
  • *
  • Posts: 91
  • Karma: 4
  • GOD'S IN HIS HEAVEN. ALL'S RIGHT WITH THE WORLD.
    • View Profile
Re: FF7Tools lzss unclear syntax.
« Reply #3 on: 2016-04-27 02:32:36 »
try:

Code: [Select]
python lzss OPENING*.data OPENING.BIN

Didn't work either. This is what happens:

>python lzss OPENING_*.data OPENING.BIN
Error opening file 'OPENING_*.data': invalid mode ('rb') or filename

I also just realized that I should of posted this in the Troubleshooting forum. Will the mods move this thread?

seams very strightfoward to me..

1. when you see <INFILE> <OUT> that a place holder you replace with what your doing.. so NO < or >
2. why did you use a + thats not going to work  with any cli program.
3. the error clearly states that the second file is unexpected input  . if your gonna use cli programs learn to read the errors.

Have you ever heard of this trick?

cd [dir]
copy /b my_pic.jpg + my_song.mp3 mynewpic.jpg

I'm not gonna explain to you what it does. The point is, it involves a plus sign.
« Last Edit: 2016-04-27 02:54:53 by NERV Agent »

sithlord48

  • No life
  • *
  • Posts: 1427
  • Karma: 33
  • Dark Lord of the Savegame
    • View Profile
    • Blackchocobo
Re: FF7Tools lzss unclear syntax.
« Reply #4 on: 2016-04-27 14:58:45 »
In your example its the copy command that is allowing the use of the plus sign. I see some other windows Cli programs also support using a + sign (like dir) . I never knew that  however i wouldn't assume that all programs allow for this .