Save Toggles to File
Fogest opened this issue ยท 2 comments
I think it would be nice if toggles are saved to a file, so that users do not have to reset the toggles they have whenever a restart, or reload occurs.
If you got CommandHelper installed, try this (ugly) workaround:
/vanish [$] = >>> assign(@args, parse_args($)) if(equals(array_size(@args), 2) , if(equals_ic(@args[0], 'effects') , assign(@effect, to_lower(@args[1])) if(array_contains(array('smoke', 'lightning', 'explode'), @effect) , if(has_permission('vanish.effects.toggle.' . @effect) , # All fine: effect is valid and player can toggle it. assign(@node, 'vanish.effects.' . @effect) if(has_permission(@node) , runas(~console, 'exec u:' . player() . ' a:rmperm v:' . @node) runas(~console, 'exec u:' . player() . ' a:addperm v:^' . @node) , runas(~console, 'exec u:' . player() . ' a:rmperm v:' . @node) runas(~console, 'exec u:' . player() . ' a:addperm v:' . @node) ) ) ) ) ) run(get_cmd()) <<<
PS: I'm assuming here that you got bPermissions, but similar syntaxes can be done to other plugins.