Re: [Release] Mu Skiner (3 languages supported and open function inplemented)
OZT/OZJ conversion is actually quite simple. It only requires several lines of code. If you have Perl installed, you can even do it straight off command line without using a program.
So, if you've got Perl installed on your computer, just open up a command prompt window, browse to the folder, and type in any one of the following 4 lines to convert every file of a certain type in that folder.
So here's your batch conversion :
Convert OZJ=>JPG:
for %f in (*.ozj) do perl -e "$f=shift;open I,$f;binmode I;read I,$_,-s$f;s/^.{24}//s;open O,'>%f.jpg';binmode O;print O" %f
Convert OZT=>TGA:
for %f in (*.ozt) do perl -e "$f=shift;open I,$f;binmode I;read I,$_,-s$f;s/^.{4}//s;open O,'>%f.tga';binmode O;print O" %f
Convert JPG=>OZJ:
for %f in (*.jpg) do perl -e "$f=shift;open I,$f;binmode I;read I,$_,-s$f;s/^(.{24})/\1\1/s;open O,'>%f.ozj';binmode O;print O" %f
Convert TGA=>OZT:
for %f in (*.tga) do perl -e "$f=shift;open I,$f;binmode I;read I,$_,-s$f;s/^(.{4})/\1\1/s;open O,'>%f.ozt';binmode O;print O" %f
And if you only want to convert a single file, remove the "for %f in (*.xxx) do" part, and replace %f with the file name. That, or replace the (*.ext) with (file_to_convert.ext).
OZT/OZJ conversion is actually quite simple. It only requires several lines of code. If you have Perl installed, you can even do it straight off command line without using a program.
So, if you've got Perl installed on your computer, just open up a command prompt window, browse to the folder, and type in any one of the following 4 lines to convert every file of a certain type in that folder.
So here's your batch conversion :
Convert OZJ=>JPG:
for %f in (*.ozj) do perl -e "$f=shift;open I,$f;binmode I;read I,$_,-s$f;s/^.{24}//s;open O,'>%f.jpg';binmode O;print O" %f
Convert OZT=>TGA:
for %f in (*.ozt) do perl -e "$f=shift;open I,$f;binmode I;read I,$_,-s$f;s/^.{4}//s;open O,'>%f.tga';binmode O;print O" %f
Convert JPG=>OZJ:
for %f in (*.jpg) do perl -e "$f=shift;open I,$f;binmode I;read I,$_,-s$f;s/^(.{24})/\1\1/s;open O,'>%f.ozj';binmode O;print O" %f
Convert TGA=>OZT:
for %f in (*.tga) do perl -e "$f=shift;open I,$f;binmode I;read I,$_,-s$f;s/^(.{4})/\1\1/s;open O,'>%f.ozt';binmode O;print O" %f
And if you only want to convert a single file, remove the "for %f in (*.xxx) do" part, and replace %f with the file name. That, or replace the (*.ext) with (file_to_convert.ext).