Class: CameraFlash

rune.camera.CameraFlash()

The CameraFlash class is a subsystem for applying a flash effect to a Camera object.

Constructor

new CameraFlash()

Creates a new instance of the CameraFlash class.
Source:

Extends

Members

(readonly) color :rune.color.Color24

24-bit tint color.
Type:
Inherited From:
Source:

opacity :number

Tint color opacity. This value can vary between 0.0 and 1.0.
Type:
  • number
Inherited From:
Source:

Methods

start(durationopt, callbackopt, scopeopt) → {undefined}

Fills the screen with color that gradually fades away. The flash color can be changed via the object's color property.
Parameters:
Name Type Attributes Default Description
duration number <optional>
750 How long it takes for the flash to fade.
callback function <optional>
null A function you want to run when the flash finishes.
scope Object <optional>
null Scope of callback function.
Source:
Returns:
Type
undefined

toString() → {string}

Returns an RGBA representation of the object.
Inherited From:
Source:
Returns:
Type
string