var t = require; var e = module; var i = exports; Object.defineProperty(i, "__esModule", {value: !0}); const s = t("Actions"), a = t("constants"), o = t("Composite"); class n extends o.default { constructor(t = {}) { super({name: "MemParallel", children: t.children, properties: t.properties, title: t.title || t.name}); } open(t) { t.blackboard.set("runningChild", 0, t.tree.id, this.id); } tick(t) { let e = !1, i = !1; for (var s = t.blackboard.get("runningChild", t.tree.id, this.id); s < this.children.length; s++) { var o = this.children[s]._execute(t); if (o === a.SUCCESS) e = !0; else { if (o !== a.FAILURE) return t.blackboard.set("runningChild", s, t.tree.id, this.id), o; i = !0; } } return 0 === this.properties.type ? (e ? a.SUCCESS : a.FAILURE) : i ? a.FAILURE : a.SUCCESS; } } (i.default = n), s.register(n, "MemParallel");