galeforce-tmp-sea
Version:
A customizable, promise-based, and command-oriented TypeScript library for the Riot Games API.
23 lines • 732 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.TakesSpell = void 0;
/**
* A mixin for the `.spell()` method.
* @template TBase The type of the object inside. Inferred from the `Base` parameter.
* @param Base The target class.
*/
function TakesSpell(Base) {
return class extends Base {
/**
* Modifies the **spell** associated with the Action object it is called from.
* @param spell The spell name to update the calling Action object with.
*/
spell(spell) {
this.payload.spell = spell;
this.spell = undefined;
return this;
}
};
}
exports.TakesSpell = TakesSpell;
//# sourceMappingURL=spell.js.map