π Usage#
Quick Start#
- π₯οΈ GUI
Launch
scfile.exewithout arguments to open the graphical interface. Use Converter for standalone assets, Animation for model and animation pairs, Map cache for region caches, and 2D Map for map tiles.- π₯ Drag & Drop
Drag files or folders directly onto
scfile.exein File Explorer. Supported files are converted to default formats and saved alongside the source file.- π±οΈ Open With
Set
scfile.exeas the default program for opening supported file types. Double-clicking any such file in Explorer will convert it and save output alongside the source file.To set up: right-click a file β Open With β choose
scfile.exeand check Always use this app.- π Command Line
Run
scfile.exe --helpto see all available arguments and options. Paths are routed automatically to commands by context.scfile.exe model.mcsb -F fbx --skeleton # convert to fbx with skeleton scfile.exe clips.mcvd model.mcsb # convert animation clips scfile.exe path/to/map_cache/5.0 # convert map cache
- π Python Library
- Install the package from PyPI:
pip install sc-file -U.Usescfilepackage from your Python scripts.Example#from scfile import Options, convert convert.mcsb_to_glb("model.mcsb", options=Options(skeleton=True))
Command Line Interface#
General#
COMMAND- Available commands:
convert,animate,mapcache, andmaptiles.When paths are supplied without a command, the CLI selects one from their names and formats. --versionShow the program version and exit.
scfile --version--updatesCheck for available updates on GitHub Releases and exit. Requires internet connection.
scfile --updates
convert#
Default command. Converts game assets to standard formats.
PATHSOne or more files or directories. Accepts absolute and relative paths. Only supported files are processed.
Example#scfile convert "model.mcsb" scfile convert "model.mcsb" "texture.ol" scfile convert "C:/assets"
-O, --outputOutput directory for converted files. If not specified, output files are saved alongside the source file.
Example#scfile convert "model.mcsb" --output "D:/output"
-F, --model-format- Preferred output format for models.Accepted values:
obj,glb,fbx.Default isobj.When--skeletonor--animationis used, default isglb.Example#scfile convert "model.mcsb" -F glb
-I, --includeProcess only the specified source formats. May be repeated.
Example#scfile convert "C:/assets" --include mcsb scfile convert "C:/assets" -I mcsb -I ol
--skeleton- Export model skeleton (armature).Supported by:
glb,fbx.Example#scfile convert "model.mcsb" --skeleton scfile convert "model.mcsb" -F glb --skeleton scfile convert "model.mcsb" -F fbx --skeleton
--animation- Export embedded animation clips. Implies
--skeleton.Supported by:glb,fbx.Example#scfile convert "model.mcsb" --animation scfile convert "model.mcsb" -F glb --animation
--on-conflict- What to do when an output file already exists in output directory.Accepted values:
replace,rename,skip.Default isreplace.replace: Replace existing file.rename: Add numeric suffix:model (1).obj,model (2).obj.skip: Keep existing file.
Example#scfile convert "C:/assets/model.mcsb" "C:/assets/sub/model.mcsb" --on-conflict rename
--layout- Output layout inside
--output. Defaults torooted.Example#scfile convert "C:/assets" --output "D:/output" --layout relative
-W, --workers- Number of worker threads. Default: CPU count.Set to
0for sequential execution.Example#scfile convert "C:/assets" --workers 4
-v, --verboseShow the result of every processed file.
Output Structure#
Examples of how --layout changes output layout.
./assets/
βββ armor/albatros.mcsb
βββ items/vodka.ol
rooted(default)scfile convert "./assets" --output "./output"
Output#./output/ βββ assets/armor/albatros.obj βββ assets/items/vodka.dds
relativescfile convert "./assets" --output "./output" --layout relative
Output#./output/ βββ armor/albatros.obj βββ items/vodka.dds
dumpscfile convert "./assets" --output "./output" --layout dump
Output#./output/ βββ albatros.obj βββ vodka.dds
animate#
.mcsb models and exports a .glb file. Each subcommand accepts -O, --output for a GLB file or directory. Without it, the GLB is saved next to the animation source.arms ANIMATION MODEL [HANDS]Apply a first-person
.mcvdanimation to a weapon.mcsbmodel. Add an optional hands model.Example#scfile animate arms "wpn_fp_akm.mcvd" "akm.mcsb" "hands.mcsb" scfile animate arms "wpn_fp_akm.mcvd" "akm.mcsb" scfile animate arms "wpn_fp_walkcycles.mcvd" "hands.mcsb"
face ANIMATION MODELApply a facial
.mcvdanimation to a head.mcsbmodel.Example#scfile animate face "shaman.mcvd" "unique_shaman.mcsb"
body ANIMATION MODELApply an
.mcalskeletal animation library to an.mcsbmodel.--rawKeep technical and duplicate clips.
Example#scfile animate body "pack.mcal" "origin.mcsb" scfile animate body "pack.mcal" "origin.mcsb" --raw
mapcache#
.mdat region caches into .mca region files.map_cache to auto-detect.SOURCEDirectory containing
.mdatfiles.Example#scfile "C:/map_cache/5.0" scfile mapcache "C:/map_cache/5.0"
-O, --outputOutput directory for
.mcafiles. If not specified, creates a folder alongsideSOURCEwith_mcasuffix.Example#scfile mapcache "C:/map_cache/5.0" --output "D:/output"
-W, --workers- Number of worker threads. Default: CPU count.Set to
0for sequential execution.Example#scfile mapcache "C:/map_cache/5.0" --workers 4
--biomes / --no-biomesExport biome data. Enabled by default. Use
--no-biomesto omit it.Example#scfile mapcache "C:/map_cache/5.0" --no-biomes
--backup / --no-backupKeep the first original
.mcaregion as.mca.bckbefore replacement. Enabled by default. Existing backups are kept unchanged.-v, --verboseShow the result of every processed region.
maptiles#
r.<x>.<z>.ol map tiles into one JPEG or PNG image.SOURCE OUTPUT- Assemble tiles directly from one flat folder.
OUTPUTmust be an image file ending in.jpg,.jpeg, or.png.Example#scfile maptiles "C:/tiles" "D:/zone.jpg"
SOURCE TARGET OUTPUT- Assemble a named map from game asset layers.
--regionoptionally selects localization region. Otherwise system language is preferred.Example#scfile maptiles "C:/Steam/steamapps/common/STALCRAFT" "global_map" "D:/global.jpg" --region ru
--jpeg-quality- JPEG quality from
0through100.Default:92. --png-compression- PNG compression level from
0through9.Default:6.