mirror of
https://github.com/GravitLauncher/Launcher
synced 2024-12-22 16:41:46 +03:00
[FEATURE] feature support
This commit is contained in:
parent
eddfd61c06
commit
8875146be3
2 changed files with 24 additions and 0 deletions
|
@ -40,12 +40,29 @@ public enum AuthType
|
|||
OTHER
|
||||
}
|
||||
}
|
||||
public enum ServerFeature
|
||||
{
|
||||
FEATURE_SUPPORT(1);
|
||||
public final int val;
|
||||
|
||||
ServerFeature(int val) {
|
||||
this.val = val;
|
||||
}
|
||||
}
|
||||
|
||||
@LauncherNetworkAPI
|
||||
public final List<AuthAvailability> list;
|
||||
@LauncherNetworkAPI
|
||||
public final long features;
|
||||
|
||||
public GetAvailabilityAuthRequestEvent(List<AuthAvailability> list) {
|
||||
this.list = list;
|
||||
this.features = ServerFeature.FEATURE_SUPPORT.val;
|
||||
}
|
||||
|
||||
public GetAvailabilityAuthRequestEvent(List<AuthAvailability> list, long features) {
|
||||
this.list = list;
|
||||
this.features = features;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -49,6 +49,13 @@ public AuthRequest(String login, byte[] password) {
|
|||
authType = ConnectTypes.CLIENT;
|
||||
}
|
||||
|
||||
public AuthRequest(String login, byte[] password, String auth_id) {
|
||||
this.login = VerifyHelper.verify(login, VerifyHelper.NOT_EMPTY, "Login can't be empty");
|
||||
this.password = new AuthECPassword(password.clone());
|
||||
this.auth_id = auth_id;
|
||||
getSession = true;
|
||||
authType = ConnectTypes.CLIENT;
|
||||
}
|
||||
@Deprecated
|
||||
public AuthRequest(String login, byte[] password, HWID hwid, String auth_id) {
|
||||
this.login = VerifyHelper.verify(login, VerifyHelper.NOT_EMPTY, "Login can't be empty");
|
||||
|
|
Loading…
Reference in a new issue