mirror of
https://github.com/luanti-org/luanti.git
synced 2025-10-05 19:31:04 +00:00
Add on_authplayer callback and 'last_login' to on_joinplayer (#9574)
Replace on_auth_fail callback with more versatile on_authplayer Better clarify account login process in Lua API documentation Change initial timestamp for newly registered accounts to -1
This commit is contained in:
parent
037422fdba
commit
15ba75e4cf
10 changed files with 81 additions and 46 deletions
|
@ -41,7 +41,7 @@ public:
|
|||
bool on_prejoinplayer(const std::string &name, const std::string &ip,
|
||||
std::string *reason);
|
||||
bool can_bypass_userlimit(const std::string &name, const std::string &ip);
|
||||
void on_joinplayer(ServerActiveObject *player);
|
||||
void on_joinplayer(ServerActiveObject *player, s64 last_login);
|
||||
void on_leaveplayer(ServerActiveObject *player, bool timeout);
|
||||
void on_cheat(ServerActiveObject *player, const std::string &cheat_type);
|
||||
bool on_punchplayer(ServerActiveObject *player, ServerActiveObject *hitter,
|
||||
|
@ -51,7 +51,7 @@ public:
|
|||
const PlayerHPChangeReason &reason);
|
||||
void on_playerReceiveFields(ServerActiveObject *player,
|
||||
const std::string &formname, const StringMap &fields);
|
||||
void on_auth_failure(const std::string &name, const std::string &ip);
|
||||
void on_authplayer(const std::string &name, const std::string &ip, bool is_success);
|
||||
|
||||
// Player inventory callbacks
|
||||
// Return number of accepted items to be moved
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue