Skip to content

Commit

Permalink
Merge pull request #211 from ApocalypsjeNL/3.0
Browse files Browse the repository at this point in the history
Add BuildPlatforn and UIProfile enums
  • Loading branch information
ApocalypsjeNL authored Oct 24, 2023
2 parents bb8e406 + 9c13ca7 commit 5009a52
Show file tree
Hide file tree
Showing 2 changed files with 65 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
package org.cloudburstmc.protocol.bedrock.data;

public enum BuildPlatform {

UNDEFINED,
/**
* Android
*/
GOOGLE,
IOS,
/**
* Mac OS
*/
OSX,
/**
* Kindle, FireTV
*/
AMAZON,
GEAR_VR,
HOLOLENS,
/**
* Windows Store version
*/
UWP,
/**
* Educational edition
*/
WIN_32,
DEDICATED,
/**
* Apple TV
*/
TV_OS,
/**
* Playstation
*/
SONY,
/**
* Nintendo Switch
*/
NX,
XBOX,
WINDOWS_PHONE,
LINUX;

private static final BuildPlatform[] VALUES = values();

public static BuildPlatform from(int id) {
return id > 0 && id < VALUES.length ? VALUES[id] : VALUES[0];
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
package org.cloudburstmc.protocol.bedrock.data;

public enum UserInterfaceProfile {

CLASSIC,
POCKET,
NONE;

private static final UserInterfaceProfile[] VALUES = values();

public static UserInterfaceProfile from(int id) {
return VALUES[id];
}
}

0 comments on commit 5009a52

Please sign in to comment.