Skip to main content
Using Deno in production at your company? Earn free Deno merch.
Give us feedback
Go to Latest
class LightRemapperInternals.BaseLightRemapper
import { LightRemapperInternals } from "https://deno.land/x/remapper@3.0.0/src/light_remapper.ts";
const { BaseLightRemapper } = LightRemapperInternals;

Constructors

new
BaseLightRemapper(condition?: Condition)

Class used to iterate through every event in the map. Has various tools to transform the events.

Properties

conditions: Condition[]

Conditions that each event needs to pass.

multiplyColor: (rgb: number, alpha?) => unknown

Multiplies the colors of the event.

processes: Process[]

Function to run on each event.

run: (log?) => unknown

Run the algorithm.

setType: (type: number) => unknown

Sets the type of the event.

Methods

addCondition(condition: Condition)

Add a condition that events must pass.

addProcess(process: Process)

Add a function to edit the event.

processEvents(events: EventInternals.AbstractEvent[], log?)

Process events through the algorithm.

test(ids: number[])

Test the algorithm with some lightIDs which will be logged.