gmdb_mp_login
Authenticates a registered player using their username and password. When called, GMDB sends the player's login details to the GMDB authentication server. If authentication succeeds, the SDK automatically starts the multiplayer connection using the authentication token returned by the server.
Syntax
gmdb_mp_login(_username, _password);Arguments
_username, _password
Return value / result
The function returns a Boolean indicating whether the login request was started.
- `true` — The login request was started successfully.
- `false` — The request could not be started.
**Important:** A return value of `true` does not mean the player has successfully logged in. Authentication happens asynchronously.
Use `gmdb_mp_login_message()` to display login status and `gmdb_mp_ready()` to check whether the multiplayer connection is ready.
GameMaker example
var _username = "player123";
var _password = "MyPassword123!";
var _started = gmdb_mp_login(_username, _password);
if (!_started)
{
show_debug_message(gmdb_mp_login_message());
}