feat: command to toggle all modules (dirty fix...)
This commit is contained in:
parent
c6dff8df7d
commit
184aa773ba
1 changed files with 13 additions and 0 deletions
|
@ -127,6 +127,19 @@ public class BoSCoVicino implements ICommons {
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
);
|
);
|
||||||
|
|
||||||
|
dispatcher.register(
|
||||||
|
Commands.literal("toggle-all")
|
||||||
|
.executes(ctx -> {
|
||||||
|
for (Module mod : BoSCoVicino.mods) {
|
||||||
|
if (mod.enabled.get()) {
|
||||||
|
mod.disable();
|
||||||
|
mod.enable();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return 1;
|
||||||
|
})
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@SubscribeEvent
|
@SubscribeEvent
|
||||||
|
|
Loading…
Reference in a new issue