@Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); AndroidApplicationConfiguration config = new AndroidApplicationConfiguration(); new CardboardImplementation(); initialize(new SimpleRoom(), config); }
@Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); try { AudioManager am = (AudioManager) getSystemService(Context.AUDIO_SERVICE); String s1 = am.getProperty(AudioManager.PROPERTY_OUTPUT_SAMPLE_RATE); String s2 = am.getProperty(AudioManager.PROPERTY_OUTPUT_FRAMES_PER_BUFFER); if (s1 != null && s2 != null) { World.freq = Integer.parseInt(s1); World.samples = Integer.parseInt(s2); System.out.println( "AudioManager suggested fs=" + World.freq + ", samples=" + World.samples); } } catch (Throwable t) { System.err.println("Could not get device defaults: " + t.toString()); } AndroidService.setInstance(new AndroidService(this)); AndroidApplicationConfiguration cfg = new AndroidApplicationConfiguration(); cfg.useAccelerometer = false; cfg.useCompass = false; cfg.useWakelock = true; initialize(new DrumApp(), cfg); }
@Override protected void onCreate(Bundle savedInstanceState) { Log.e(TAG, "onCreate"); super.onCreate(savedInstanceState); MyAppApplication myApp = ((MyAppApplication) getApplicationContext()); mGoogleApiClient = myApp.getClient(); room = myApp.getRoom(); mRoomId = room.getRoomId(); mParticipants = room.getParticipants(); Intent i = getIntent(); myself = (Player) i.getSerializableExtra("myself"); AndroidApplicationConfiguration config = new AndroidApplicationConfiguration(); initialize(new CatMath(this, myself), config); // updated by siyuan myId = room.getParticipantId(Games.Players.getCurrentPlayerId(myApp.getClient())); GameWorld.isOwner = isServer(); Log.e("isOwner:", String.valueOf(GameWorld.isOwner)); playerMap.put(myId, 1); GameWorld.numberOfPlayers = mParticipants.size(); Log.e(TAG, "onCreate ends"); } // end of onCreate
@Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); AndroidApplicationConfiguration config = new AndroidApplicationConfiguration(); initialize(new MyGameColumns(), config); }
@Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); AndroidApplicationConfiguration config = new AndroidApplicationConfiguration(); // config.useGLSurfaceView20API18 = true; initialize(new MyGdxGame(), config); }
/* * (non-Javadoc) * @see android.app.Activity#onCreate(android.os.Bundle) * * cfg.use20 = true um Texturen zu verwenden welche nicht PowerOf2 verwenden ( z.b. 8x8, 16x16, 32x32 usw. ) */ public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); AndroidApplicationConfiguration cfg = new AndroidApplicationConfiguration(); cfg.useGL20 = true; initialize(new MainTutorials(), cfg); }
@Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); AndroidApplicationConfiguration config = new AndroidApplicationConfiguration(); config.useAccelerometer = false; config.useCompass = false; initialize(new Drop(), config); }
@Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); AndroidApplicationConfiguration cfg = new AndroidApplicationConfiguration(); initialize(new StampedeGame(), cfg); }
@Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); AndroidApplicationConfiguration cfg = new AndroidApplicationConfiguration(); cfg.useGL20 = false; initialize(new WebDefender(), cfg); }
@Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); AndroidApplicationConfiguration cfg = new AndroidApplicationConfiguration(); cfg.useGL20 = true; initialize(new PickinGas(), cfg); }
@Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); AndroidApplicationConfiguration config = new AndroidApplicationConfiguration(); config.useGL20 = true; Engine engine = new Engine(); initialize(engine, config); engine.setLoadingPath("", true); }
@Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); AndroidApplicationConfiguration config = new AndroidApplicationConfiguration(); config.useAccelerometer = false; config.useCompass = false; config.useGLSurfaceView20API18 = true; initialize(new Side(), config); Gdx.app.setLogLevel(LOG_DEBUG); }
@Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); gameHelper = new GameHelper(this, GameHelper.CLIENT_GAMES); gameHelper.enableDebugLog(true); AndroidApplicationConfiguration config = new AndroidApplicationConfiguration(); game = new Game(this); initialize(game, config); gameHelper.setup(this); }
public void onCreate(android.os.Bundle savedInstanceState) { super.onCreate(savedInstanceState); RT.var("clojure.core", "require").invoke(Symbol.intern("hello-world.core")); try { Game game = (Game) RT.var("hello-world.core", "hello-world").deref(); initialize(game); } catch (Exception e) { e.printStackTrace(); } }
/** Called when the activity is first created. */ @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); AndroidApplicationConfiguration config = new AndroidApplicationConfiguration(); config.useAccelerometer = false; config.useCompass = false; config.useWakelock = true; config.useGL20 = true; initialize(new StarAssault(), config); }
@Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); AndroidApplicationConfiguration config = new AndroidApplicationConfiguration(); initialize( new AbstractGame() { @Override protected void init() {} }, config); }
@Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); AndroidApplicationConfiguration cfg = new AndroidApplicationConfiguration(); cfg.useGL20 = true; cfg.useAccelerometer = false; cfg.useCompass = false; initialize(new Lumpundform(), cfg); }
@Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); AndroidApplicationConfiguration cfg = new AndroidApplicationConfiguration(); cfg.useGL20 = false; // PLATFORM_DESKTOP = 0; // PLATFORM_ANDROID = 1; // PLATFORM_OUYA = 2; initialize(new BashNBump(1), cfg); }
@Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); AndroidApplicationConfiguration cfg = new AndroidApplicationConfiguration(); cfg.useGL20 = false; // Prevent the screen from dimming getWindow().addFlags(WindowManager.LayoutParams.FLAG_KEEP_SCREEN_ON); initialize(new MyCoolGame(), cfg); }
public void onCreate(Bundle var1) { super.onCreate(var1); this.getWindow().addFlags(128); AndroidApplicationConfiguration cfg = new AndroidApplicationConfiguration(); cfg.useGL20 = false; cfg.useAccelerometer = true; cfg.useCompass = false; this.requestWindowFeature(1); this.getWindow().setFlags(1024, 1024); this.getWindow().clearFlags(2048); layout = new RelativeLayout(this); layout.setLayoutParams(new LayoutParams(-1, -1)); adView = this.createAdView(); // layout.addView(adView); layout.addView(this.createGameView(cfg)); this.setContentView(layout); this.startAdvertising(adView); this.interstitialAd = new InterstitialAd(this); this.interstitialAd.setAdUnitId(AD_UNIT_ID_INTERSTITIAL); interstitialAd.setAdListener( new AdListener() { @Override public void onAdLoaded() { if (DEBUG) { Toast.makeText( getApplicationContext(), "Finished Loading Interstitial", Toast.LENGTH_SHORT) .show(); } } @Override public void onAdClosed() { if (DEBUG) { Toast.makeText(getApplicationContext(), "Closed Interstitial", Toast.LENGTH_SHORT) .show(); } } }); if (this.gameHelper == null) { this.gameHelper = new GameHelper(this, 1); this.gameHelper.enableDebugLog(true); } this.gameHelper.setup(this); }
@Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); AndroidApplicationConfiguration cfg = new AndroidApplicationConfiguration(); cfg.useGL20 = false; cfg.useAccelerometer = false; cfg.useCompass = false; Texture.setEnforcePotImages(false); Assets ass = new Assets(); ass.manager.load(Assets.class); initialize(new Endless_RPG(new AndroidGameOrientation()), cfg); }
@Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); Log.i(tag, "on create activiy"); AndroidApplicationConfiguration config = new AndroidApplicationConfiguration(); config.useWakelock = true; createWakeLock(config); game = new PokerGame(); MyPoker.game = game; initialize(game, config); MyPoker.client.setListener(game); // game.onReceivedJson(MyPoker.json); }
@Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); // fix for launcher icon starting new activity on top of old one if ((getIntent().getFlags() & Intent.FLAG_ACTIVITY_BROUGHT_TO_FRONT) != 0) { finish(); return; } listeners = new Array<ActionListener>(); AndroidApplicationConfiguration config = new AndroidApplicationConfiguration(); config.useAccelerometer = false; config.useCompass = false; config.hideStatusBar = true; // config.useImmersiveMode = true; config.useAccelerometer = false; if (GameScreen.SOFT_DEBUG) config.useWakelock = true; MyGame.setPlatformSpecific(this); initialize(new MyGame(), config); // create app exit alertBuilder = new AlertDialog.Builder(this); alertBuilder.setTitle("Exit"); alertBuilder.setMessage("Do you really want to exit?"); alertBuilder.setCancelable(true); alertBuilder.setPositiveButton( "Yes", new DialogInterface.OnClickListener() { public void onClick(DialogInterface dialog, int id) { Gdx.app.exit(); } }); alertBuilder.setNegativeButton( "No", new DialogInterface.OnClickListener() { public void onClick(DialogInterface dialog, int id) { dialog.cancel(); } }); }
@Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); // getWindow().addFlags(WindowManager.LayoutParams.FLAG_KEEP_SCREEN_ON); // SystemUtils.initFullScreen(this); mGoogleApiClient = new GoogleApiClient.Builder(this) .addConnectionCallbacks(this) .addOnConnectionFailedListener(this) .addApi(Nearby.CONNECTIONS_API) .build(); AndroidApplicationConfiguration config = new AndroidApplicationConfiguration(); game = new UAGdxGame(); initialize(game, config); }
@Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); WindowManager.LayoutParams attrs = getWindow().getAttributes(); attrs.flags |= WindowManager.LayoutParams.FLAG_FULLSCREEN; getWindow().setAttributes(attrs); setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_LANDSCAPE); if (Build.VERSION.SDK_INT >= 11) { resetStatusBar(); } AndroidApplicationConfiguration cfg = new AndroidApplicationConfiguration(); cfg.useGL20 = true; initialize(new GlxyGame(), cfg); }
/** Called when the activity is first created. */ @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); AndroidApplicationConfiguration config = new AndroidApplicationConfiguration(); config.useAccelerometer = false; config.useCompass = false; config.useWakelock = true; config.useGL20 = true; // int mode = Activity.MODE_PRIVATE; // prefs = getSharedPreferences("bomber-pref", mode); // Maze m = new Maze(); /*Intent intent = new Intent(); intent.setClass(this, MainActivity.class); startActivity(intent);*/ // stageNumber = getStagePref(); initialize(new BomberMan(this), config); }
@Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); // Create the GameHelper _gameHelper = new GameHelper(this, GameHelper.CLIENT_GAMES); _gameHelper.enableDebugLog(false); GameHelperListener gameHelperListener = new GameHelper.GameHelperListener() { @Override public void onSignInSucceeded() { // TODO Auto-generated method stub } @Override public void onSignInFailed() { // TODO Auto-generated method stub } }; _gameHelper.setup(gameHelperListener); // signIn(); Intent serviceIntent = new Intent("com.android.vending.billing.InAppBillingService.BIND"); serviceIntent.setPackage("com.android.vending"); bindService(serviceIntent, mServiceConn, Context.BIND_AUTO_CREATE); // queryPurchases(); AndroidApplicationConfiguration config = new AndroidApplicationConfiguration(); config.useImmersiveMode = true; initialize(new Runners(this), config); }
@Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); Bundle bundle = getIntent().getExtras(); IP = bundle.getString("ip"); PORT = Integer.parseInt(bundle.getString("port")); Log.d("UxAndroid", "ip: " + IP + ", port: " + PORT); initialize( new ApplicationListener() { BitmapFont font; SpriteBatch batch; @Override public void create() { new Thread( new Runnable() { @Override public void run() { try { RemoteSender sender = new RemoteSender(IP, PORT); synchronized (UxAndroid.this) { UxAndroid.this.sender = sender; } } catch (GdxRuntimeException e) { } } }) .start(); batch = new SpriteBatch(); font = new BitmapFont(); } @Override public void resume() {} @Override public void resize(int width, int height) { batch.getProjectionMatrix().setToOrtho2D(0, 0, width, height); } @Override public void render() { boolean connected = false; synchronized (UxAndroid.this) { if (sender != null) { sender.sendUpdate(); connected = sender.isConnected(); } } Gdx.gl.glClear(GL10.GL_COLOR_BUFFER_BIT); batch.begin(); if (connected) { font.draw( batch, "accel:" + Gdx.input.getAccelerometerX() + ", " + Gdx.input.getAccelerometerY() + ", " + Gdx.input.getAccelerometerZ() + ", fps: " + Gdx.graphics.getFramesPerSecond(), 10, 20); } else { font.draw(batch, "No connection to " + IP + ":" + PORT, 10, 20); } batch.end(); } @Override public void pause() {} @Override public void dispose() {} }, false); }
@Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); initialize(new MyGame(), false); }
@Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); AndroidApplicationConfiguration config = new AndroidApplicationConfiguration(); initialize(new GemTd(GemTd.MOBILE_MODE), config); }