TheAltening Auth API made by Vladymyr now branded under the official repo
Please use the version x.x.x-j9
if you are running Java 10 and above, otherwise just stick to x.x.x
version.
repositories {
mavenCentral()
}
dependencies {
implementation 'com.thealtening.auth:auth:@BADGE-VERSION@'
}
<dependencies>
<dependency>
<groupId>com.thealtening.auth</groupId>
<artifactId>auth</artifactId>
<version>@BADGE-VERSION@</version>
</dependency>
</dependencies>
- Use JDK 1.8+
- Create a new
TheAlteningAuthentication
instance depending on the service wanted:
import com.thealtening.auth.TheAlteningAuthentication
TheAlteningAuthentication mojang = TheAlteningAuthentication.mojang();
TheAlteningAuthentication theAltening = TheAlteningAuthentication.theAltening();
- In case that you want to switch to another service, use the
updateService
method from your auth instance.
theAlteningAuth.updateService(AlteningServiceType.MOJANG);
theAlteningAuth.updateService(AlteningServiceType.THEALTENING);
Note: if the given service type is null
or the same as the current, no change will be made.