public void Auth(xPlayer player, params string[] password) { if (player.PlayerData.password != null) { if (player.PlayerData.password == GetPasswordHash(string.Join("", password))) { } else { player.SendMessage(player.PlayerData.lang.get("authme.login.error.password")); } } else { player.SendMessage(player.PlayerData.lang.get("authme.login.error.noaccount")); } }
public void Reg(xPlayer player, params string[] password) { string Name = player.Username; if (player.PlayerData.isAuth) { return; } Dictionary <string, string> userdata = Query("SELECT user_low FROM userdata WHERE user_low='" + player.Username.ToLower() + "'"); if (userdata == null) { //Register code } else { player.SendMessage(player.PlayerData.lang.get("authme.register.error.registered")); } }