If you delete character it's data will remain in database. Because you cannot log in to that character anymore to get rid off that toon's info without wiping whole database add slash command like /bi clear charactername. It will wipe data of charactername from current realm.
Below is fragment of code to put inside function BankItems_SlashHandler():
elseif strfind(msg, "clear (.*)") then local selfPlayerRealm = strtrim(GetRealmName()) local p1, p2 = strmatch(msg, "clear (.)(.*)") if not p1 or not p2 then return end -- names are at least 2 chars long local playerName = strupper(p1)..p2.."|"..selfPlayerRealm for key, value in pairs(BankItems_Save) do if type(value) == "table" and key == playerName then BankItems_DelPlayer(key) end end return
Place above code before
elseif msg == "clearall" then
Also you can add
BankItems_Chat(L["-- /bi clear character : clear character's info"])
in same function.
|Mornadan||Jan 07, 2014 at 00:02 UTC||Create|