|
Pol
Revision:cb584c9
|
#include <account.h>
Inheritance diagram for Pol::Accounts::Account:Public Member Functions | |
| Account (Clib::ConfigElem &elem) | |
| ~Account () | |
| bool | banned () const |
| void | clear_character (int index) |
| unsigned char | default_cmdlevel () const |
| std::string | default_privlist () const |
| bool | enabled () const |
| size_t | estimatedSize () const |
| Mobile::Character * | get_character (int index) |
| int | getnextfreeslot () const |
| bool | has_active_characters () |
| Returns true if at least one character from this account is already logged in. More... | |
| const char * | name () const |
| int | numchars () const |
| const std::string | password () const |
| const std::string | passwordhash () const |
| void | readfrom (Clib::ConfigElem &elem) |
| void | set_character (int index, Mobile::Character *chr) |
| void | set_password (std::string newpass) |
| void | set_passwordhash (std::string newpass) |
| const std::string | uo_expansion () const |
| unsigned short | uo_expansion_flag () const |
| void | writeto (Clib::StreamWriter &sw) const |
| void | writeto (Clib::ConfigElem &elem) const |
Public Member Functions inherited from ref_counted | |
| unsigned int | add_ref () |
| unsigned int | count () const |
| unsigned int | release () |
Static Public Member Functions | |
| static unsigned short | convert_uo_expansion (const std::string &expansion) |
Private Attributes | |
| bool | banned_ |
| std::vector< Core::CharacterRef > | characters_ |
| unsigned char | default_cmdlevel_ |
| Clib::StringSet | default_privs_ |
| bool | enabled_ |
| std::string | name_ |
| Clib::StringSet | options_ |
| std::string | password_ |
| std::string | passwordhash_ |
| Core::PropertyList | props_ |
| unsigned short | uo_expansion_ |
Friends | |
| class | AccountObjImp |
Additional Inherited Members | |
Protected Member Functions inherited from ref_counted | |
| ref_counted () | |
| ~ref_counted ()=default | |
Protected Attributes inherited from ref_counted | |
| std::atomic< unsigned int > | _count |
|
explicit |
Definition at line 31 of file account.cpp.
References Pol::Core::PolConfig::character_slots, characters_, Pol::Plib::SystemState::config, readfrom(), and Pol::Plib::systemstate.
Referenced by estimatedSize().
| Pol::Accounts::Account::~Account | ( | ) |
Definition at line 143 of file account.cpp.
References Pol::Core::PolConfig::character_slots, characters_, Pol::Plib::SystemState::config, and Pol::Plib::systemstate.
| bool Pol::Accounts::Account::banned | ( | ) | const |
Definition at line 272 of file account.cpp.
References banned_.
Referenced by Pol::Core::login2(), and Pol::Core::loginserver_login().
| void Pol::Accounts::Account::clear_character | ( | int | index | ) |
Definition at line 179 of file account.cpp.
References characters_.
Referenced by Pol::Accounts::AccountObjImp::call_method_id(), and Pol::Core::delete_character().
|
static |
Definition at line 240 of file account.cpp.
References Pol::Network::AOS, Pol::Network::HSA, Pol::Network::KR, Pol::Network::LBR, Pol::Network::ML, Pol::Network::SA, Pol::Network::SE, Pol::Network::T2A, and Pol::Network::TOL.
Referenced by readfrom().
| unsigned char Pol::Accounts::Account::default_cmdlevel | ( | ) | const |
Definition at line 282 of file account.cpp.
References default_cmdlevel_.
Referenced by Pol::Core::ClientCreateChar(), Pol::Core::ClientCreateChar70160(), Pol::Core::ClientCreateCharKR(), and Pol::Core::loginserver_login().
| std::string Pol::Accounts::Account::default_privlist | ( | ) | const |
Definition at line 277 of file account.cpp.
References default_privs_, and Pol::Clib::StringSet::extract().
Referenced by Pol::Core::ClientCreateChar(), Pol::Core::ClientCreateChar70160(), and Pol::Core::ClientCreateCharKR().
| bool Pol::Accounts::Account::enabled | ( | ) | const |
Definition at line 267 of file account.cpp.
References enabled_.
Referenced by Pol::Core::login2(), and Pol::Core::loginserver_login().
| size_t Pol::Accounts::Account::estimatedSize | ( | ) | const |
Definition at line 158 of file account.cpp.
References Account(), characters_, default_privs_, Pol::Clib::StringSet::estimatedSize(), Pol::Core::PropertyList::estimatedSize(), name_, options_, password_, passwordhash_, and props_.
| Mobile::Character * Pol::Accounts::Account::get_character | ( | int | index | ) |
Definition at line 169 of file account.cpp.
References characters_.
Referenced by Pol::Core::char_select(), Pol::Core::ClientCreateChar(), Pol::Core::ClientCreateChar70160(), Pol::Core::ClientCreateCharKR(), Pol::Core::handle_delete_character(), Pol::Mobile::Character::readCommonProperties(), and Pol::Core::send_start().
| int Pol::Accounts::Account::getnextfreeslot | ( | ) | const |
Definition at line 296 of file account.cpp.
References Pol::Core::PolConfig::character_slots, characters_, Pol::Plib::SystemState::config, and Pol::Plib::systemstate.
Referenced by Pol::Accounts::AccountObjImp::call_method_id().
| bool Pol::Accounts::Account::has_active_characters | ( | ) |
Returns true if at least one character from this account is already logged in.
Definition at line 185 of file account.cpp.
References Pol::Core::PolConfig::character_slots, characters_, Pol::Plib::SystemState::config, and Pol::Plib::systemstate.
Referenced by Pol::Core::char_select(), Pol::Core::ClientCreateChar(), Pol::Core::ClientCreateChar70160(), Pol::Core::ClientCreateCharKR(), and Pol::Core::handle_delete_character().
| const char * Pol::Accounts::Account::name | ( | ) | const |
Definition at line 193 of file account.cpp.
References name_.
Referenced by Pol::Core::acct_check(), Pol::Core::char_select(), Pol::Core::client_io_thread(), Pol::Core::ClientCreateChar(), Pol::Core::ClientCreateChar70160(), Pol::Core::ClientCreateCharKR(), Pol::Accounts::delete_account(), Pol::Core::delete_character(), Pol::Module::gumpbutton_handler(), Pol::Core::handle_menu_selection(), Pol::Core::handle_msg_BF(), Pol::Core::handle_rename_char(), Pol::Module::handle_selcolor(), Pol::Core::handle_unicode_prompt(), Pol::Core::NetworkManager::kill_disconnected_clients(), Pol::Core::login2(), Pol::Core::loginserver_login(), Pol::Module::popup_menu_selection_made(), Pol::Core::process_data(), Pol::Core::report_weird_packet(), Pol::Core::start_packetlog(), Pol::Network::Client::status(), Pol::Core::textcmd_startlog(), Pol::Core::threadstatus_thread(), and writeto().
| int Pol::Accounts::Account::numchars | ( | ) | const |
Definition at line 287 of file account.cpp.
References Pol::Core::PolConfig::character_slots, characters_, Pol::Plib::SystemState::config, and Pol::Plib::systemstate.
Referenced by Pol::Accounts::delete_account().
| const std::string Pol::Accounts::Account::password | ( | ) | const |
Definition at line 198 of file account.cpp.
References password_.
Referenced by Pol::Core::login2(), and Pol::Core::loginserver_login().
| const std::string Pol::Accounts::Account::passwordhash | ( | ) | const |
Definition at line 203 of file account.cpp.
References passwordhash_.
Referenced by Pol::Core::login2(), and Pol::Core::loginserver_login().
| void Pol::Accounts::Account::readfrom | ( | Clib::ConfigElem & | elem | ) |
Definition at line 47 of file account.cpp.
References Pol::Plib::SystemState::accounts_txt_dirty, banned_, Pol::Core::PropertyList::clear(), Pol::Core::CmdLevel::cmdlevel, convert_uo_expansion(), default_cmdlevel_, default_privs_, enabled_, Pol::Core::find_cmdlevel(), Pol::Clib::ConfigElem::has_prop(), Pol::Clib::MD5_Encrypt(), name_, password_, passwordhash_, props_, Pol::Clib::StringSet::readfrom(), Pol::Core::PropertyList::readProperties(), Pol::Clib::ConfigElem::remove_bool(), Pol::Clib::ConfigElem::remove_string(), Pol::Plib::systemstate, Pol::Clib::ConfigElem::throw_error(), and uo_expansion_.
Referenced by Account(), and Pol::Accounts::reread_account().
| void Pol::Accounts::Account::set_character | ( | int | index, |
| Mobile::Character * | chr | ||
| ) |
Definition at line 174 of file account.cpp.
References characters_.
Referenced by Pol::Accounts::AccountObjImp::call_method_id(), Pol::Core::ClientCreateChar(), Pol::Core::ClientCreateChar70160(), Pol::Core::ClientCreateCharKR(), and Pol::Core::createchar2().
|
inline |
Definition at line 62 of file account.h.
Referenced by Pol::Core::login2(), and Pol::Core::loginserver_login().
|
inline |
| const std::string Pol::Accounts::Account::uo_expansion | ( | ) | const |
Definition at line 208 of file account.cpp.
References Pol::Network::AOS, Pol::Network::HSA, Pol::Network::KR, Pol::Network::LBR, Pol::Network::ML, Pol::Network::SA, Pol::Network::SE, Pol::Network::T2A, Pol::Network::TOL, and uo_expansion_.
Referenced by writeto().
| unsigned short Pol::Accounts::Account::uo_expansion_flag | ( | ) | const |
Definition at line 235 of file account.cpp.
References uo_expansion_.
Referenced by Pol::Core::send_feature_enable().
| void Pol::Accounts::Account::writeto | ( | Clib::StreamWriter & | sw | ) | const |
Definition at line 84 of file account.cpp.
References banned_, Pol::Core::GameState::cmdlevels, default_cmdlevel_, default_privs_, Pol::Clib::StringSet::empty(), enabled_, Pol::Clib::StringSet::extract(), Pol::Core::gamestate, name_, password_, passwordhash_, pf_endl, Pol::Core::PropertyList::printProperties(), props_, Pol::Plib::systemstate, uo_expansion(), and uo_expansion_.
Referenced by Pol::Accounts::duplicate_account(), and Pol::Accounts::write_account_data().
| void Pol::Accounts::Account::writeto | ( | Clib::ConfigElem & | elem | ) | const |
Definition at line 115 of file account.cpp.
References Pol::Clib::ConfigElem::add_prop(), banned_, default_cmdlevel_, default_privs_, Pol::Clib::StringSet::empty(), enabled_, Pol::Clib::StringSet::extract(), Pol::Core::gamestate, name(), name_, password_, passwordhash_, Pol::Core::PropertyList::printProperties(), props_, Pol::Plib::systemstate, uo_expansion(), and uo_expansion_.
|
friend |
|
private |
Definition at line 73 of file account.h.
Referenced by banned(), readfrom(), and writeto().
|
private |
Definition at line 67 of file account.h.
Referenced by Account(), clear_character(), estimatedSize(), get_character(), getnextfreeslot(), has_active_characters(), numchars(), set_character(), and ~Account().
|
private |
Definition at line 76 of file account.h.
Referenced by default_cmdlevel(), readfrom(), and writeto().
|
private |
Definition at line 75 of file account.h.
Referenced by default_privlist(), estimatedSize(), readfrom(), and writeto().
|
private |
Definition at line 72 of file account.h.
Referenced by enabled(), readfrom(), and writeto().
|
private |
Definition at line 68 of file account.h.
Referenced by estimatedSize(), name(), readfrom(), and writeto().
|
private |
Definition at line 78 of file account.h.
Referenced by estimatedSize().
|
private |
Definition at line 69 of file account.h.
Referenced by estimatedSize(), password(), readfrom(), and writeto().
|
private |
Definition at line 70 of file account.h.
Referenced by estimatedSize(), passwordhash(), readfrom(), and writeto().
|
private |
Definition at line 74 of file account.h.
Referenced by estimatedSize(), readfrom(), and writeto().
|
private |
Definition at line 71 of file account.h.
Referenced by readfrom(), uo_expansion(), uo_expansion_flag(), and writeto().