StartPackage

From Onset Developer Wiki
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.
StartPackage

Type: Function
Context: Server
Introduced: v1.0

Description

Starts a package at runtime. The game will automatically handle downloads for new client files.

Notice: StartPackage will first look into the autostart folder before looking in the packages folder.

Syntax

StartPackage(PackageName)

Parameters

  • PackageName
    The name of the package.

Return Value

  • Returns true on success.

Example

function cmd_restartpack(player, package_)
	StopPackage(package_)

	Delay(500, function()
		StartPackage(package_)
	end)
end
AddCommand("restartpack", cmd_restartpack)

See also