mwg API
    Preparing search index...

    Interface HasColorAdd

    Carries the additive colour for one renderable.

    Anything drawn through this batcher may set colorAdd on itself; anything that does not is packed with zero and renders exactly as it would have with the default batcher.

    import type { HasColorAdd } from '@datamoc/mw_games/two-d/render';
    import { packColorAdd } from '@datamoc/mw_games/two-d/render';

    function tintTowardsWhite(renderable: HasColorAdd, strength: number): void {
    renderable.colorAdd = packColorAdd(strength, strength, strength);
    }
    interface HasColorAdd {
        colorAdd?: number;
    }
    Index
    colorAdd?: number

    additive colour, packed as 0xAABBGGRR to match the attribute's byte order