Android Open Source - AmazingGame Game Screen






From Project

Back to project page AmazingGame.

License

The source code is released under:

GNU General Public License

If you think the Android project AmazingGame listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.

Java Source Code

package game.screens;
//  w  ww.j  a v a  2  s .  c  o  m
import game.MyGdxGame;
import game.input.MapInputHandler;
import game.world.GameMap;
import game.world.GameRenderer;

import com.badlogic.gdx.Gdx;
import com.badlogic.gdx.Screen;
import com.badlogic.gdx.graphics.GL20;

public class GameScreen implements Screen
{
  private GameMap map;
  private GameRenderer renderer;
  private MapInputHandler input;

  
  public GameScreen(int numPlayers, MyGdxGame currentGame)
  {
    map = new GameMap(numPlayers);
    renderer = new GameRenderer(map, 1000, 1000, map.getStage());
    input = new MapInputHandler(renderer, map);

    
    Gdx.input.setInputProcessor(input);
    
//    Gdx.input.setInputProcessor(map.getStage());
  }
  
  @Override
  public void render(float delta)
  {
    Gdx.gl.glClearColor(0, 0, 1, 1f);
        Gdx.gl.glClear(GL20.GL_COLOR_BUFFER_BIT);
    
    map.update(delta);
    renderer.render(delta);
  }

  @Override
  public void resize(int width, int height)
  {
    
  }

  @Override
  public void show()
  {
    
  }

  @Override
  public void hide()
  {
    
  }

  @Override
  public void pause()
  {
    
  }

  @Override
  public void resume()
  {
    
  }

  @Override
  public void dispose()
  {
    
  }


  public void winningPlayer(int i)
  {
    
  }

  public void noWinningPlayer()
  {
    
  }

}




Java Source Code List

game.IOSLauncher.java
game.MyGdxGame.java
game.android.AndroidLauncher.java
game.client.HtmlLauncher.java
game.desktop.DesktopLauncher.java
game.generator.MapGenerator.java
game.helpers.AssetLoader.java
game.helpers.Constants.java
game.helpers.MapHelper.java
game.helpers.TileClickHelper.java
game.input.MapInputHandler.java
game.objects.BlurpleBuilding.java
game.objects.BurnedMoose.java
game.objects.Grass.java
game.objects.PoopDesert.java
game.objects.River.java
game.objects.TileSprite.java
game.objects.Tree.java
game.objects.Unit.java
game.objects.Wall.java
game.objects.Water.java
game.screens.GameScreen.java
game.world.GameMap.java
game.world.GameRenderer.java
game.world.PlayerManager.java