FTP won't anymore in general, but won't work for this anyway since the accounts folder is protected from writing by scripts.
The best solution assuming you can't just get Stefan to wipe the accounts folder (which you probably don't want anyway since you lose rights, comments, online time, etc.):
Quote:
Originally Posted by cbk1994
PHP Code:
function resetAll() { temp.folder.loadFolder("accounts/*", true); for (temp.file : folder) { if (!file.ends(".txt")) { continue; } file = file.substring(0, file.length() - 4); // remove extension temp.tokens = file.tokenize("/"); // split between slashes sendtorc("/reset" SPC removeEscapesFromFileName(tokens[tokens.size() - 1])); } }
I imagine something like this would work, but I've never tried anything like it. No rights should be needed; loadFolder works with no read rights as far as I know.
|
The NPC-server will actually need reset rights (not sure if I missed that or if npc-server rights hadn't yet been implemented when I wrote that post). I also fixed a couple of errors in the script but I might have missed more, make sure to test before using. I wrote that four years ago so I'm not confident it will behave appropriately with pc:## or Graal## accounts, but this approach is probably the best way to do a reset.