use of com.watabou.utils.PDPlatformSupport in project shattered-pixel-dungeon-gdx by 00-Evan.
the class AndroidLauncher method onCreate.
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
AndroidApplicationConfiguration config = new AndroidApplicationConfiguration();
String version;
int versionCode;
try {
version = getPackageManager().getPackageInfo(getPackageName(), 0).versionName;
versionCode = getPackageManager().getPackageInfo(getPackageName(), 0).versionCode;
} catch (PackageManager.NameNotFoundException e) {
version = "???";
versionCode = 0;
}
initialize(new ShatteredPixelDungeon(new PDPlatformSupport<GameAction>(version, versionCode, null, new AndroidInputProcessor())), config);
}
use of com.watabou.utils.PDPlatformSupport in project shattered-pixel-dungeon-gdx by 00-Evan.
the class HtmlLauncher method createApplicationListener.
@Override
public ApplicationListener createApplicationListener() {
String version = "???";
int versionCode = 0;
return new ShatteredPixelDungeon(new PDPlatformSupport(version, versionCode, null, null));
}
use of com.watabou.utils.PDPlatformSupport in project shattered-pixel-dungeon-gdx by 00-Evan.
the class IOSLauncher method createApplication.
@Override
protected IOSApplication createApplication() {
IOSApplicationConfiguration config = new IOSApplicationConfiguration();
final String version = NSBundle.getMainBundle().getInfoDictionaryObject("CFBundleShortVersionString").toString();
final int versionCode = Integer.parseInt(NSBundle.getMainBundle().getInfoDictionaryObject("CFBundleVersion").toString());
return new IOSApplication(new ShatteredPixelDungeon(new PDPlatformSupport(version, versionCode, null, new IOSInputProcessor())), config);
}
Aggregations