It could be like this, I just don't see the connection to the user online status, since no character data is stored on player's PC (apart for the UI element postion, chat logs and macros).

That's why I half-seriously suggested it just calls the client's "retire" command without a prompt, that would explain the online requirement.