Skip to content

Instance Variables

absorbable

Type

Bool

Initial Value

false

Description

When true, the hitbox is able to trigger absorb-related events when it connects with an absorb collision box. Absorb events are only receivable by projectiles, and the resulting behavior is determined by the individual projectile receiving the absorb event.

angle

Type

Float

Initial Value

0

Description

The angle of knockback. Expects an angle between 0 and 360, or alternatively a SpecialAngle value. Note that when a foe takes damage this number is modified in the resulting HIT_RECEIVED/HIT_DEALT GameObjectEvents. Use rawAngle if you want the original value.

attackId

Type

Int

Initial Value

0

Description

Attack identfier for the stats

attackRatio

Type

Float

Initial Value

1

Description

A multiplier that is applied to knockback after the final knockback calculation has been done.

attackStrength

Type

Int

Initial Value

null

Description

Use this alongside the element to determine the hit sound and hit effect. @see AttackStrength

baseKnockback

Type

Float

Initial Value

0

Description

Base power.

bodyX

Type

Float

Initial Value

0

Description

X location of the owner GameObject. Generally this is auto-populated to match the position of the owner, except in cases HitboxStats were generated by hand in which case an owning object may not exist.

bodyY

Type

Float

Initial Value

0

Description

Y location of the owner GameObject. Generally this is auto-populated to match the position of the owner, except in cases HitboxStats were generated by hand in which case an owning object may not exist.

buryTimeBase

Type

Int

Initial Value

0

Description

Base amount of frames a buried target will stay buried for.

buryTimeScaling

Type

Float

Initial Value

1.0

Description

Amount of extra frames a buried target will stay buried for; a scaling applied to the target's percent.

buryType

Type

Int

Initial Value

null

Description

Bury settings. Only affects Characters. @see BuryType

cameraShakeType

Type

Float

Initial Value

null

Description

Specifies the camera shake behavior for the hit.

damage

Type

Float

Initial Value

0

Description

The amount of damage that the hitbox deals to foes.

directionalInfluence

Type

Bool

Initial Value

true

Description

Setting to false will disable post-hitstop directional influence among hit foes.

disabled

Type

Bool

Initial Value

false

Description

If true, the hitbox will behave as though it did not exist (it will not interact with other boxes).

element

Type

Int

Initial Value

null

Description

What element the attack is @see AttackElement

flinch

Type

Bool

Initial Value

true

Description

Setting to false will make the move not break grabs nor send the foe into the hurt animation.

forceTumbleFall

Type

Bool

Initial Value

false

Description

@deprecated When true, the attack will always cause foes to go into their tumble state when hit. This stat has been deprecated, please use tumbleType stat instead

hitEffectOverride

Type

String

Initial Value

null

Description

Use a custom hit Vfx. By default, the engine assumes this is an animation name from from the GlobalVfx sprite (See GlobalVfx constnats). You can however use other Vfx animations by specifying the full content id of the Vfx sprite followed by a hash "#" specifying the animation you want to play. (e.g. "namespace::resource.spriteId#animationId")

hitSoundOverride

Type

String

Initial Value

null

Description

Instead of using the automatic hitsound calc (uses element and hitstrength).

hitSoundOverrideArray

Type

Array<String>

Initial Value

null

Description

Instead of using the automatic hitsound calc or sound override, plays random sound id from array.

hitstop

Type

Int

Initial Value

-1

Description

Determines how many frames the victim will be held in place before knockback is applied. When negative this value is automatically calculated.

hitstopMultiplier

Type

Float

Initial Value

1.0

Description

Multiplier that affects both hitstop and selfHitstop.

hitstopNudgeMultiplier

Type

Float

Initial Value

1

Description

Multiplier for how far foes can nudge while in hitstop.

hitstopOffset

Type

Int

Initial Value

0

Description

Used in conjunction with a negative hitstop stat, adds a flat amount of hitstop independent of how hitstop is calculated.

hitstun

Type

Float

Initial Value

-1

Description

How long the foe will be unable to attack after knockback is applied. When positive, this is the number of frames the foe will remain in hitstun. When negative, this works like a multiplier against the automatically calculated hitstun value. For example, a value of -0.5 would result in a multiplier of 0.5 against the calculated hitstun. By leaving it at its default of -1, you will get 100% of the calculated hitstun.

index

Type

Int

Initial Value

-1

Description

The numerical index of the hitbox that can be used to identify which hitbox was involved in a hit.

jabResetType

Type

Int

Initial Value

null

Description

Jab reset settings @see JabResetType

knockbackCap

Type

Float

Initial Value

-1

Description

When greater than or equal to zero, prevents an attack from dealing more knockback than this value. When negative, knockback is unlimited.

knockbackCapDelay

Type

Int

Initial Value

0

Description

Number of frames to delay the application of knockbackCap. When negative or zero, knockbackCap is immediately applied. When 1, the cap will be applied on the next frame.

knockbackGrowth

Type

Float

Initial Value

0

Description

Growth of the power correlated to damage.

limb

Type

Int

Initial Value

null

Description

What the attacker is attacking with. @see AttackLimb

maxChargeDamageMultiplier

Type

Float

Initial Value

null

Description

Multiplier used for maximum charge if the move is chargeable

metadata

Type

Dynamic

Initial Value

null

Description

Additional metadata.

owner

Type

GameObject

Initial Value

null

Description

The GameObjectApi instance that owns the hitbox.

rawAngle

Type

Float

Initial Value

0

Description

The raw angle value of the hitbox that always starts equal to the "angle" stat. Cannot be assigned, but you can use it to determine the original angle of the hitbox in cases where the actual trajectory of the foe isn't desired.

rawDamage

Type

Float

Initial Value

0

Description

The raw damage value of the hitbox. Is unaffected by staling and cannot be assigned.

reflectable

Type

Bool

Initial Value

false

Description

When true, the hitbox is able to trigger reflect-related events when it connects with a reflect box. Reflect events are only receivable by projectiles and items, and the resulting behavior is determined by the individual object receiving the reflect event.

reverse

Type

Bool

Initial Value

false

Description

When true, the hitbox will automatically reverse and flip most other object types objects upon a successful hit.

reversibleAngle

Type

Bool

Initial Value

true

Description

When true, if the hitbox connects behind the origin of the attacker then the resulting angle will be flipped horizontally.

selfHitstop

Type

Int

Initial Value

-1

Description

Determines how many frames the attacker will be held in place before knockback is applied. When negative this value is automatically calculated.

selfHitstopOffset

Type

Int

Initial Value

0

Description

Used in conjunction with a negative selfHitstop stat, adds a flat amount of hitstop independent of how selfHitstop is calculated.

shieldDamageMultiplier

Type

Float

Initial Value

1

Description

Multiplier for shield damage.

shieldable

Type

Bool

Initial Value

true

Description

When true, the hitbox is able to be shielded by foes.

shieldstunMultiplier

Type

Float

Initial Value

1

Description

Multiplier for shieldstun.

stackKnockback

Type

Bool

Initial Value

true

Description

Setting to false will disable knockback stacking.

tumbleType

Type

Int

Initial Value

null

Description

Tumble settings @see TumbleType

Instance Functions

afterImportJSON(data:Dynamic):Void

Description

updateMetadata(data:Dynamic):Void

Description

Utility function for updating the metadata object of the stats without changing the metadata object's reference. Performs a shallow merge of all fields from the input data Parameters:

  • data - The data to merge into the metadata