• Type Parameters

    • T

    • M

    Parameters

    • target: ProtoObject<T>

      Object on which to add or modify properties

    • mixin: ProtoObject<M>

      Object with additional properties

    Returns void

    Example

    class CreepMixin extends Creep {
    hasBodyparts(type: BodyPartConstant) {
    return this.body.some((b) => b.type == type)
    }
    }
    applyMixin(Creep, CreepMixin)

Generated using TypeDoc