@woosh/meep-engine
Version:
Pure JavaScript game engine. Fully featured and production ready.
26 lines (19 loc) • 608 B
JavaScript
import { returnTrue } from "../../../../core/function/returnTrue.js";
import { GridCellAction } from "../../../placement/action/GridCellAction.js";
export class GridCellActionDebugBreak extends GridCellAction {
/**
*
* @type {function():boolean}
*/
condition = returnTrue;
static from({ condition = returnTrue }) {
const r = new GridCellActionDebugBreak();
r.condition = condition;
return r;
}
execute(data, x, y, rotation) {
if (this.condition(data, x, y, rotation)) {
debugger;
}
}
}