Skip to content

A class containing parameters that configures the default settings of a Match. Any player-affecting parameters will be overridden by the PlayerConfig.

Static Variables

NETCODE_DELAY

Type

Int

Initial Value

1

Description

netcodeType value: Delay-based netcode is enabled

NETCODE_NONE

Type

Int

Initial Value

0

Description

netcodeType value: No netcode is enabled

NETCODE_ROLLBACK

Type

Int

Initial Value

2

Description

netcodeType value: Rollback netcode is enabled

NETCODE_ROLLBACK_SIMULATED

Type

Int

Initial Value

3

Description

netcodeType value: Rollback netcode is simualted offline

Instance Variables

damageDisplay

Type

Bool

Initial Value

true

Description

Set to true to display player damage on the HUD. Set to false to hide it.

damageMode

Type

Bool

Initial Value

true

Description

Damage mode for the players.

  • true for damage
  • false for stamina

damageRatio

Type

Float

Initial Value

1

Description

This value is applied to the global knockback formula when a game object takes damage.

  • Do note that as the damage scales, so does the distance a foe goes upon being hit.

entrances

Type

Bool

Initial Value

true

Description

When true, character entrance animations will be shown at the start of a match. Set to false to disable this behavior.

hazards

Type

Bool

Initial Value

false

Description

Controls whether stage hazards are enabled. The definition of 'hazard' varies by stage.

  • When set to true, stages' hazardous elements are enabled.
  • When set to false, they are disabled.

lives

Type

Int

Initial Value

-1

Description

Number of 'stocks' each player has by default within this Match. Note that this can be overridden by playerConfigs.

  • Set to -1 to disable.

matchRules

Type

Array<ResourceIdentifier>

Initial Value

null

Description

The content/resource ID of the match rules for this match.

metadata

Type

Dynamic

Initial Value

null

Description

Dynamic metadata - use this for anything else not covered by existing variables.

music

Type

ResourceIdentifier

Initial Value

null

Description

This setting specifies the music resource id and content id to be loaded and played at match start

netcodeInputBuffer

Type

Int

Initial Value

null

Description

The input delay setting of the match host. For delay-based matches, all players will use the same input delay. For rollback-based matches, the settings are determined at an individual player level.

netcodeType

Type

Int

Initial Value

0

Description

Netcode setting. This determines the type of Match instance to instantiate.

pauseMenuId

Type

String

Initial Value

null

Description

The pause config for this match.

playerIDs

Type

Bool

Initial Value

false

Description

Set to true to make player ID numbers display above each player at all times. If player tags are available will display that instead.

randSeed

Type

String

Initial Value

null

Description

This is the random seed that was set at match start.
You may retrieve this value if desired butthis should not be set manually.

sizeRatio

Type

Float

Initial Value

1

Description

A multiplier for the default scale of sprites within this Match.
Generally this should be left alone, as it does not have additional effects like scaling physics or damage.

specialModes

Type

Int

Initial Value

0

Description

This is a bit mapping of the enabled special modes for a match.
In order to combine special modes together, you need to perform a bitwise OR on the special modes you would like to enable.

stage

Type

ResourceIdentifier

Initial Value

null

Description

The content/resource ID of the Stage that the Match takes place on.

startDamage

Type

Float

Initial Value

0

Description

Starting damage for players.

  • Set to negative to give players stamina instead of racking up damage. @see stamina

teamAttack

Type

Bool

Initial Value

false

Description

Controls whether friendly fire is enabled.

  • When set to true, teammates can hurt each other.
  • This has no effect outside of team battles.

teams

Type

Bool

Initial Value

false

Description

Set to true to make the match a team battle. Set to false for a free-for-all.

  • When having a team battle make sure to assign each player (via PlayerConfig) to a team.

time

Type

Float

Initial Value

0

Description

Match game timer IN SECONDS.

  • Set negative to count up from 0 to value.
  • Set positive to count down from value.
  • Set to 0 to disable.