Commandlet

From Oldunreal-Wiki
Revision as of 00:02, 6 April 2021 by Neon Knight (talk | contribs) (Created page with "{{Stub}} In this page we're going to see what Commandlets are and what function does each one perform. __TOC__ == Overview == According to the Unreal Engine documentation, '...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
Article stub
The following is an article stub. You can help us by expanding it.

In this page we're going to see what Commandlets are and what function does each one perform.

Overview

According to the Unreal Engine documentation, "Commandlets are command line programs that run inside of the Unreal Engine environment. They are most often used to make bulk changes to content, iterate over content to get information about it, or as a unit testing mechanism. They are basically little applets that have the engine initialized but are mostly just confined to Windows console output. The engine automatically tries to see whether a command you passed on the commandline is a commandlet, and if it matches, executes the associated code."<ref>"How to Make a Commandlet" @ UnrealEngine.com</ref>

Commandlets are executed from the ucc.exe command line utility, using the following syntax: ucc.exe package_name.commandlet_class_name [parm=value].... Each of these commandlets have their syntax and a brief explanation of what each option does. If a user tries to run a commandlet and the exact name he types isn't found, then ucc.exe appends the text "commandlet" to the name and tries again.

Commandlets can also be simplified, provided they're properly defined in Editor.int (or the respective language's version). This allows users to just type ucc server ... instead of ucc Engine.ServerCommandlet ....

Commandlets shared between Unreal v227* and UT v469*

BatchExport

  • Package: Editor
  • Syntax: batchexport package.ext classname export_ext [path]

Exports resources from Unreal packages in bulk.

  • package.ext: Package whose objects you wish to export. Extension and directory are optional: (e.g. Botpack.u, ..\Maps\CTF-Face.unr or just CTF-Face)
  • classname: The type of objects to export from the package. It can be one of class, texture, sound, music, level, model, polys or textbuffer.
  • export_ext: Extension used for the exported files. The accepted file extensions per class are as follows:
  • class: uc, h.
  • texture: bmp, pcx.
  • sound: wav.
  • music: s3m, xm, it or any other tracker format.
  • level, model and polys: t3d. level exports the complete map with all actors and brushes; model exports all the brushes used in a map (with the red builder being Brush.t3d while the other brushes being Model##.t3d); and polys exports polygons (?) to files named Polys#.t3d.
  • textbuffer: txt. Exports all kinds of text sources in the package. Script code is exported as ScriptCode.txt for each class, so the files will instantly overwrite each other. Maps have an additional text buffer with camera settings for UnrealEd.
  • path: Path to export files to, like C:\MyPath.

ChecksumPackage

  • Package: Editor
  • Syntax: checksumpackage packagename

Displays the checksum for the selected package file.

  • packagename: The name of the package to checksum.

CheckUnicode

  • Package: Editor
  • Syntax:

CompareInt

  • Package: Editor
  • Syntax: compareint packageint miscint

Compare 2 language files and delete/remove language entries that you compare with.

  • packageint: Main language file.
  • miscint: Secondary language file (to edit).

Compress

  • Package: IpDrv
  • Syntax: compress File1 [File2 [File3 ...]]

Compresses an Unreal package for autodownloading. A file with extension .uz will be created.

  • Files: The wildcard or file names to compress.

Conform

  • Package: Editor
  • Syntax: conform existing_file.ext old_file.ext

Generates conforming binary files. Used to make Unreal packages network-compatible.

  • existingfile.ext: Existing binary file to load, conform, and save.
  • oldfile.ext: Old file to make source file binary compatible with.

DataRip

  • Package: Editor
  • Syntax: datarip srcpackage.ext dstpackage.ext

Creates a package with Texture, Music and Sound data ripped out.

  • srcpackage.ext: Source Package.
  • dstpackage.ext: Destination Package.

Decompress

  • Package: IpDrv
  • Syntax: decompress CompressedFile

Decompress a file compressed with ucc compress.

  • CompressedFile: The .uz file to decompress.

DumpInt

  • Package: Editor
  • Syntax: dumpint packagename

Dumps the language text contents out of a file.

  • packagename: The name of the package to dump language text of.

ExportPackage

  • Package: Editor
  • Syntax: exportpackage packagename

Simply exports a package contents to .uc files in prior directory.

  • packagename: The name of the package to export UC files of.

ListObjects

  • Package: Editor
  • Syntax: listobjects [-switch1 [-switch2 [...]]] <package> [<baseclass>]

Lists Objects in a package.

  • -switch1, -switch2...: Option switches, can be one or more of the following:
  • -cp: Prints pathname instead of name for Class.
  • -op: Prints pathname instead of name for Object.
  • -na: Do not align output.
  • -ni: Do not indent object hierarchy.
  • -nc: Do not display class.
  • -co: Just display Object Classes instead of each Object.
  • pkg: Package file.
  • baseclass: Optional base class of listed objects.

Make

  • Package: Editor
  • Syntax: make [-option...] [parm=value]...

Rebuilds UnrealScript packages. Used to compile UnrealScript packages, mainly.

  • Silent: No prompts; assume 'yes' to all questions.
  • NoBind: Don't force native functions to be bound to DLLs.
  • All: Clean rebuild (otherwise rebuild is incremental).

Master

  • Package: Editor
  • Syntax: master [-option...] [parm=value]...

Builds master installer files, also known as .umod files. These files allow you to install and uninstall Unreal/UT addons in a clean way without having to worry about paths.

  • MasterPath: Root directory to copy source files from.
  • SrcPath: Root directory to copy source (release) files to.
  • RefPath: Path for delta-compressed path reference.

MasterServer

  • Package: IpDrv
  • Syntax: masterserver [-option...] [parm=value]

Maintains a master list of servers.

  • ConfigFile: Configuration file to use. Default: MasterServer.ini.

PackageFlag

  • Package: Editor
  • Syntax: packageflag src.ext [<+|->flag [<+|->flag] ...]

Sets package flags in package files. Normally, clients connecting to a game server will download all the packages currently in use by the server. If you don't want that because it's unnecessary, you can set certain package flags to specify how the server should handle this package.

  • src.ext: Existing package file to load.
  • flag: + to set a flag, or - to remove a flag, followed by one of:
  • AllowDownload: Clients are allowed to download this package from the server.
  • ClientOptional: Clients can choose whether or not to download this package from server.
  • ServerSideOnly: The package has no network relevancy on a server.
  • BrokenLinks: Allows the package to load with missing links.
  • Unsecure: Unused.

Server

  • Package: Engine
  • Syntax: server map.unr[?game=gametype] [-option...] [parm=value]...

Starts a network game server.

  • Log: Specifies the log file to generate.
  • AllAdmin: Gives all players admin privileges.

StripSource

  • Package: Editor
  • Syntax: stripsource packagename

Strips the script buffers from a package.

  • packagename: The name of the package to strip sources from.

UpdateServer

  • Package: IpDrv
  • Syntax: updateserver [-option...] [parm=value]

Service Unreal Engine auto update requests.

  • ConfigFile: Configuration file to use. Default: UpdateServer.ini.

UpdateUMOD

  • Package: Editor
  • Syntax: updateumod UmodFile Command [Filename]

Adds, deletes, replaces or extracts files from an .umod file created with the master commandlet.

  • UmodFile: The umod file to change or view.
  • Command: Can be one of the following:
  • EXTRACT: File extraction
  • ADD: File addition
  • DELETE: File deletion
  • REPLACE: File replacement
  • LIST: File listing
  • Filename: The file where to perform EXTRACT, ADD, DELETE or REPLACE.

Commandlets exclusive to Unreal v227*

AudioPackage

  • Package: Editor
  • Syntax: audiopackage <input directory>

Creates an audio package out of a directory.

DumpTextureInfo

  • Package: Editor
  • Syntax: dumptextureinfo <pkg>

Dumps information about textures.

FontPageDiff

  • Package: Editor
  • Syntax: fontpagediff <left font> <right font>

Compares font pages.

FullBatchExport

  • Package: Editor
  • Syntax: fullbatchexport <pkg> <outpath>

Extracts package with directory structure.

  • -DefaultFontExtension: Optional, to define export format.
  • -DefaultMusicExtension: Optional, to define export format.
  • -DefaultSoundExtension: Optional, to define export format.
  • -DefaultTextureExtension: Optional, to define export format.

LinkerUpdate

  • Package: Engine
  • Syntax:

MusicPackages

  • Package: Editor
  • Syntax: musicpackages <input directory>

Creates music packages out of a directory.

ProdigiosumInParvo

  • Package: Editor
  • Syntax: prodigiosuminparvo <pkg> <format> <outpath>

Batch exports all mip map levels.

PS2Convert

  • Package: Editor
  • Syntax:

RebuildImports

  • Package: Editor
  • Syntax: rebuildimports <pkg> [-upkg]

Rebuilds import script for a package.

  • -upkg: Switches output to upkg format. Default is uc.

ReduceTextures

  • Package: Editor
  • Syntax: reducetextures <inpkg> <outpkg>

Purges unneeded uncompressed mipmaps.

RipAndTear

  • Package: Editor
  • Syntax:

SaveEmbedded

  • Package: Editor
  • Syntax: saveembedded <pkg> <embpkg> <outfile>

Saves an embedded package to a separate file.

SHAUpdate

  • Package: Editor
  • Syntax:

TextureMerger

  • Package: Editor
  • Syntax:

Commandlets exclusive to UT v469*

CheckSum

  • Package: Engine
  • Syntax: checksum packagename.u

Calculates package checksum for stat logging.

  • packagename.u: Filename to calculate checksum from.

Exec

  • Package: Editor
  • Syntax: exec filename

Executes a command file in a minimal editor environment.

MD5

  • Package: Editor
  • Syntax: md5 [-option Filename|Wildcard]

Manage the Packages.md5 checksums list.

  • -a Wildcard: Adds all files matching the wildcard to the Packages.md5 list.
  • -l [Filename]: Prints the current contents of the specified Packages.md5 file. If no Filename is given, Packages.md5 will be used.
  • -m Filename: Merges the contents of two Packages.md5 files. Filename should point to a valid Packages.md5 file.
  • -p Wildcard: Removes the checksum for the all files matching the wildcard from the Packages.md5 list.

MergeDXT

  • Package: Editor
  • Syntax: mergedxt srcpath oldpath destpath

Merges DXT textures with standard textures.

  • srcpath: Path containing source files.
  • oldpath: Path containing old files.
  • destpath: Path for destination files.

PackageDump

  • Package: Editor
  • Syntax: packagedump [Filename]

Dumps the structure of an Unreal Package to stdout.

ResRays

  • Package: Editor
  • Syntax:

ScriptRays

  • Package: Editor
  • Syntax: scriptrays <pkg>[.<cls>] <out_d> [-disassemble|-mugshot]

Rebuilds script source for a package or class.

  • pkg[.cls]: Package or class to rebuild.
  • out_d: Output directory.
  • -disassemble: Output disassembly instead of code.
  • -mugshot: Output declarations instead of code.

External links and resources

<reference />