ACFTools (for X-Plane)
The Plane-Maker from X-Plane v7.x is fun and easy to use... Although I found it a bit limited to edit my planes' fuselage. 20 cross-sections aren't enough, sometimes. It would be nice to export the fuselage shape into any 3D-editor and fine-tune it there... This is exactly what my ACFTools are supposed to do. Please note that X-Plane v8.x is unsupported, unless you create & edit a v7 model and then import it to Plane-Maker v8. But I believe this isn't a problem: X-Plane v8 is able to use OBJ format files (which can be imported/exported by AC3D and Blender plugins) as parts of an aircraft, thus, extremely weird shapes are perfectly possible without even touching the ACF file.
Now, what exactly ACFTools does? It is able to process the file that stores all the aircraft data (except the textures), in the binary ACF format, and dump all the data in the human-readable TXT format. It is the same format as for Tony Gondola's ACF2Text utility, which inspirited my ACFTools. Then, ACFTools can extract the 3D model of the aircraft from this data, and export it in the AC3D format. After that you can edit the aircraft's shape as you want using AC3D and make the inverse process: from
.ac to .txt, and then from .txt to .acf. Here comes the brief set of ACFTools features:- Convert from ACF (aircraft) & WPN (weapon) formats to TXT format and vice-versa.
- Extract AC3D model from TXT file, along with wings and propellers (using the real airfoils!).
- Import AC3D model into TXT file (fuselage, nacelles, wheel fairings & external fuel tanks only)
ACFTools was written in Perl, thus it is able to work under Linux, MacOS & Windows. And it is Open-Source & highly modular, so you can modify it as you want, or use my functions for your own needs. When you start ACFTools, this is what you get at your console:
##############################################################################
[ACFTools v0.62a] Set of tools to play with ACF files outside of Plane-Maker
Perl script and modules coded by Stanislaw Pusep
Site of this and another X-Plane projects of mine: http://xplane.sysd.org/
Allows you to:
* export X-Plane (www.x-plane.com) aircraft data files to human-editable
plaintext format and 3D mesh editable in AC3D modeler (www.ac3d.org).
* import plaintext/3D mesh back to ACF file.
##############################################################################
Usage: acftools.exe[parameters]
o Commands:
-extract [DEF] : extract TXT from ACF (opt: using DEF definition)
-generate : generate ACF from TXT
-merge : merge body from AC3D file to TXT
o Parameters:
-acffile FILE : name of ACF file to process
-txtfile FILE : name of TXT file to process
-ac3dfile FILE : name of AC3D file to process
-noorder : DO NOT sort vertices while merging bodies
-noac3d : DO NOT generate AC3D
-(min|max)body N: write all bodies in specified range to AC3D
-force LIST : force extraction of bodies LIST (comma-separated N)
-normalize N : normalize wings to N vert/surface (N>=2 or no wings!)
o Notes:
* You can use abbreviations of commands/parameters (-gen or even -g
instead of -generate).
* The only required parameter for "extract" command is -acffile.
Both -txtfile and -ac3dfile are derivated from it.
* "generate" command and -txtfile has the same relation.
* By default "extract" uses the latest DEF file.
* "generate" doesn't need DEF at all (it is implicit in TXT)
* If file to be created already exists backup is made automatically.
o Examples:
acftools.exe --extract=ACF700 --acffile="F-22 Raptor.acf"
(extract 'F-22 Raptor.txt' from 'F-22 Raptor.acf')
acftools.exe -e -acf "F-22 Raptor.acf"
(same as above)
acftools.exe -me -ac3d ladar.ac -txt "F-22 Raptor.txt"
(merge *single* 3D body from 'ladar.ac' to 'F-22 Raptor.txt')
acftools.exe -g -txt "F-22 Raptor.txt"
(reverse operation; generate 'F-22 Raptor.acf' from 'F-22 Raptor.txt')
defs directory. By default, it is a ACF740.def,
which works for X-Plane v7.40 and later. You can specify any definition
file you want, as shown on the screen above. You can also write your
own definition files, if you have the structure specification. Note
that to convert TXT back to ACF, no definition is necessary, as the TXT
format itself holds all the data necessary to build the binary file.
The second thing is to specify the file that ACFTools should convert.
The name of the converted file and every of the intermediary files will
be generated from this name. When converting from ACF to AC3D formats,
TXT file is generated automatically. Please note that when you want to
put the edited aircraft part back into the .acf file, you must save this part as a .ac
separate file, then merge it into the TXT file, and after that convert
it into ACF! Yes, it would be nice to have a GUI to automate the entire
process, but I'm too lazy to do that! Anyway, may the source be with you

I strongly recommend you to read the
docs\README.txt file contained in the ACFTools package before you start using it!stas » May 10, 2006 » 01:09
5781 reads

