Constants

CHANNEL_RELEASE

CHANNEL_RELEASE

CHANNEL_BETA

CHANNEL_BETA

CHANNEL_NIGHTLY

CHANNEL_NIGHTLY

SETTING_ENABLE_UPDATECHECK

SETTING_ENABLE_UPDATECHECK

SETTING_UPDATECHECK_INTERVAL

SETTING_UPDATECHECK_INTERVAL

SETTING_UPDATECHECK_CHANNEL

SETTING_UPDATECHECK_CHANNEL

SETTING_PERFORM_BACKUPS

SETTING_PERFORM_BACKUPS

SETTING_AUTO_UPDATE

SETTING_AUTO_UPDATE

SETTING_PERMISSION_UPDATE

SETTING_PERMISSION_UPDATE

SETTING_PERMISSION_UPDATECHECK

SETTING_PERMISSION_UPDATECHECK

BUILD_DATE_FILE_NAME

BUILD_DATE_FILE_NAME

Properties

$currentBuildDate

$currentBuildDate : 

Type

Methods

__construct()

__construct(\ManiaControl\ManiaControl  $maniaControl) 

Construct a new update manager instance

Parameters

\ManiaControl\ManiaControl $maniaControl

getUpdateChannels()

getUpdateChannels() : array<mixed,string>

Get the possible update channels

Returns

array<mixed,string>

hourlyUpdateCheck()

hourlyUpdateCheck() 

Perform Hourly Update Check

setCoreUpdateData()

setCoreUpdateData(\ManiaControl\Update\UpdateData  $coreUpdateData = null) 

Set Core Update Data

Parameters

\ManiaControl\Update\UpdateData $coreUpdateData

checkUpdate()

checkUpdate() 

Start an Update Check

checkCoreUpdateAsync()

checkCoreUpdateAsync(callable  $function) 

Checks a Core Update asynchronously

Parameters

callable $function

getCurrentUpdateChannelSetting()

getCurrentUpdateChannelSetting() : string

Retrieve the Update Channel Setting

Returns

string

handleUpdateCheck()

handleUpdateCheck(\ManiaControl\Update\UpdateData  $updateData = null) 

Handle the fetched Update Data of the hourly Check

Parameters

\ManiaControl\Update\UpdateData $updateData

checkUpdateData()

checkUpdateData(\ManiaControl\Update\UpdateData  $updateData = null) : boolean

Check if the given Update Data has a new Version and fits for the Server

Parameters

\ManiaControl\Update\UpdateData $updateData

Returns

boolean

isNightlyUpdateChannel()

isNightlyUpdateChannel(string  $updateChannel = null) : boolean

Check if ManiaControl is running the Nightly Update Channel

Parameters

string $updateChannel

Returns

boolean

getBuildDate()

getBuildDate() : string

Get the build date of the local version

Returns

string

checkUpdateDataBuildVersion()

checkUpdateDataBuildVersion(\ManiaControl\Update\UpdateData  $updateData = null) : boolean

Check if the Update Data is compatible with the Server

Parameters

\ManiaControl\Update\UpdateData $updateData

Returns

boolean

checkAutoUpdate()

checkAutoUpdate() 

Check if an automatic Update should be performed

performCoreUpdate()

performCoreUpdate(\ManiaControl\Players\Player  $player = null) : boolean

Perform a Core Update

Parameters

\ManiaControl\Players\Player $player

Returns

boolean

setBuildDate()

setBuildDate(string  $date) : boolean

Set the build date version

Parameters

string $date

Returns

boolean

handlePlayerJoined()

handlePlayerJoined(\ManiaControl\Players\Player  $player) 

Handle ManiaControl PlayerJoined callback

Parameters

\ManiaControl\Players\Player $player

handlePlayerDisconnect()

handlePlayerDisconnect(\ManiaControl\Players\Player  $player) 

Handle Player Disconnect Callback

Parameters

\ManiaControl\Players\Player $player

handle_CheckUpdate()

handle_CheckUpdate(array  $chatCallback, \ManiaControl\Players\Player  $player) 

Handle //checkupdate command

Parameters

array $chatCallback
\ManiaControl\Players\Player $player

handle_CoreUpdate()

handle_CoreUpdate(array  $chatCallback, \ManiaControl\Players\Player  $player) 

Handle //coreupdate command

Parameters

array $chatCallback
\ManiaControl\Players\Player $player