UNPKG

@petkoneo/phaser3-rex-plugins

Version:
38 lines (30 loc) 646 B
import Decorator from '../Decorator.js'; import { FAILURE, SUCCESS, ERROR } from '../../constants.js'; class Bypass extends Decorator { constructor( { child = null, title, name = 'Bypass' } = {}, nodePool ) { super( { child, title, name, }, nodePool ); } tick(tick) { if (!this.child) { return ERROR; } // Won't abort child var status = this.child._execute(tick); return status; } }; export default Bypass;