Page 1 of 1
Where is Account cleaner ?
Posted: Sun Apr 16, 2006 4:12 am
by CrazyMan
How i now pol cant delete account from the scripts.
Where i can find perl or some like that script for clean my accounts.txt - delete all baned accounts ?
Re: Where is Account cleaner ?
Posted: Sun Apr 16, 2006 8:03 am
by Shinigami
CrazyMan wrote:How i now pol cant delete account from the scripts.
...in Pol096
Shinigami
Posted: Sun Apr 16, 2006 8:06 am
by CrazyMan
my bad english....
How i can delete all banned accounts?
Posted: Sun Apr 16, 2006 8:08 am
by CrazyMan
*Stupid CrazyMan...*
05-25 Shinigami
Added : Account.delete() - delete this empty account
Added : Account.split( newacctname : string, index : 1..5 )
create a new account and move character to it
Added : Account.move_char( destacctname : string, index : 1..5 )
move character from this account to destination account.
you can use it to flip chars on same account too - it's not a bug, it's a feature ;oP
Sorry...
Posted: Sat Apr 22, 2006 2:19 am
by Harley
I am sorry, as I still noob in scripting, you could not show me how this script looks. Thanks.
Posted: Sat Apr 22, 2006 2:38 am
by CrazyMan
Code: Select all
use uo;
program newbie_acccleaner()
var acc_list := ListAccounts();
var account;
foreach acc_name in acc_list
account := FindAccount(acc_name);
account.Delete();
endforeach
endprogram
Posted: Sat Apr 22, 2006 2:54 am
by Harley
very interesting, but! How it work? .acccleaner [acc] and nothing has occured! Tell please, how it work. Thanks.
Posted: Sat Apr 22, 2006 3:27 am
by FreeSoul
Account.delete() - delete this empty account
EMPTY account
Code: Select all
use uo;
include "util/bank";
program acccleaner(who, name)
var account;
account := FindAccount(name);
if (account)
var char,cnt;
for(cnt :=1; cnt <=5; cnt :=cnt+1)
char := account.getcharacter(cnt);
if (char)
SendSysMessage(who, "character at slot "+cnt);
if (WipeBankBox( char ))
SendSysMessage(who, "Bankbox wiped!");
else
SendSysMessage(who, "no bankbox to wipe!");
endif
foreach thing in listequippeditems(char)
Destroyitem(thing);
endforeach
SendSysMessage(who, "equippment destroyed!");
account.deletecharacter(cnt);
endif
endfor
account.Delete();
else
SendSysMessage(who,"no account with that name");
endif
endprogram