diff --git a/src/common/actionflow.py b/src/common/actionflow.py index cb233a0..c4cbd4f 100644 --- a/src/common/actionflow.py +++ b/src/common/actionflow.py @@ -56,9 +56,15 @@ class ActionFlow: assert index is not None, "Action '%s' is not registered" % name return index - def allow(self, action: type[Action], value=True): - index = self.index(action) - self.on[index] = False if value else None + def allow(self, *actions: type[Action]): + for Item in actions: + index = self.index(Item) + self.on[index] = False + + def deter(self, *actions: type[Action]): + for Item in actions: + index = self.index(Item) + self.on[index] = None def stage(self, *preset: type[Action]): for Props in preset: