diff --git a/android/assets/images/bfblogo.png b/android/assets/images/bfblogo.png new file mode 100644 index 0000000..0127141 Binary files /dev/null and b/android/assets/images/bfblogo.png differ diff --git a/android/assets/images/blackforestbytes_appstart.png b/android/assets/images/blackforestbytes_appstart.png new file mode 100644 index 0000000..c956eb9 Binary files /dev/null and b/android/assets/images/blackforestbytes_appstart.png differ diff --git a/android/assets/images/blackforestbyteslogo.png b/android/assets/images/blackforestbyteslogo.png new file mode 100644 index 0000000..dd76418 Binary files /dev/null and b/android/assets/images/blackforestbyteslogo.png differ diff --git a/core/src/de/samdev/colorrunner/CRGame.java b/core/src/de/samdev/colorrunner/CRGame.java index 37793e9..9b089d3 100644 --- a/core/src/de/samdev/colorrunner/CRGame.java +++ b/core/src/de/samdev/colorrunner/CRGame.java @@ -10,9 +10,9 @@ public class CRGame extends Game { @Override public void create() { - if (DEBUG) - setScreen(new GameScreen()); - else + //if (DEBUG) + // setScreen(new GameScreen()); + //else setScreen(new SplashScreen()); } } diff --git a/core/src/de/samdev/colorrunner/game/world/CRGameWorld.java b/core/src/de/samdev/colorrunner/game/world/CRGameWorld.java index 646f789..c577557 100644 --- a/core/src/de/samdev/colorrunner/game/world/CRGameWorld.java +++ b/core/src/de/samdev/colorrunner/game/world/CRGameWorld.java @@ -3,6 +3,7 @@ package de.samdev.colorrunner.game.world; import java.util.ArrayList; import java.util.List; +import com.badlogic.gdx.Game; import com.badlogic.gdx.Gdx; import com.badlogic.gdx.math.Rectangle; import com.badlogic.gdx.math.Vector2; @@ -20,6 +21,8 @@ import de.samdev.colorrunner.game.world.map.CRMapStorage; import de.samdev.colorrunner.game.world.map.CRTiledMap; import de.samdev.colorrunner.game.world.map.MapSection; import de.samdev.colorrunner.input.GameInputListener; +import de.samdev.colorrunner.screens.gameScreen.GameScreen; +import de.samdev.colorrunner.screens.menu.MainMenu; public class CRGameWorld implements GameInputListener { public PlayerEntity player; @@ -58,7 +61,11 @@ public class CRGameWorld implements GameInputListener { else entities.remove(i); } - + + if(player.getPosition().y < - 10) + { + ((Game) Gdx.app.getApplicationListener()).setScreen(new MainMenu()); + } expandMap(); } diff --git a/core/src/de/samdev/colorrunner/game/world/entities/gameentities/PlayerEntity.java b/core/src/de/samdev/colorrunner/game/world/entities/gameentities/PlayerEntity.java index aed62f2..e9b29e1 100644 --- a/core/src/de/samdev/colorrunner/game/world/entities/gameentities/PlayerEntity.java +++ b/core/src/de/samdev/colorrunner/game/world/entities/gameentities/PlayerEntity.java @@ -1,5 +1,7 @@ package de.samdev.colorrunner.game.world.entities.gameentities; +import com.badlogic.gdx.Game; +import com.badlogic.gdx.Gdx; import com.badlogic.gdx.graphics.Texture; import de.samdev.colorrunner.game.renderer.CRAssets; @@ -8,6 +10,7 @@ import de.samdev.colorrunner.game.world.SwipeDirection; import de.samdev.colorrunner.game.world.entities.CRGameEntity; import de.samdev.colorrunner.game.world.entities.GravityEntity; import de.samdev.colorrunner.game.world.entities.gameentities.floor.FloorTileEntity; +import de.samdev.colorrunner.screens.menu.MainMenu; public class PlayerEntity extends GravityEntity { public final static float PLAYER_WIDTH = 32; diff --git a/core/src/de/samdev/colorrunner/screens/gameScreen/GameScreen.java b/core/src/de/samdev/colorrunner/screens/gameScreen/GameScreen.java index 175ab73..1998899 100644 --- a/core/src/de/samdev/colorrunner/screens/gameScreen/GameScreen.java +++ b/core/src/de/samdev/colorrunner/screens/gameScreen/GameScreen.java @@ -4,6 +4,8 @@ import com.badlogic.gdx.Gdx; import com.badlogic.gdx.InputMultiplexer; import com.badlogic.gdx.Screen; import com.badlogic.gdx.input.GestureDetector; +import com.badlogic.gdx.maps.tiled.TiledMap; +import com.badlogic.gdx.maps.tiled.TmxMapLoader; import de.samdev.colorrunner.game.renderer.CRGameRenderer; import de.samdev.colorrunner.game.world.AverageExecutionLogger; diff --git a/core/src/de/samdev/colorrunner/screens/menu/SplashScreen.java b/core/src/de/samdev/colorrunner/screens/menu/SplashScreen.java index 801a442..87305fd 100644 --- a/core/src/de/samdev/colorrunner/screens/menu/SplashScreen.java +++ b/core/src/de/samdev/colorrunner/screens/menu/SplashScreen.java @@ -16,46 +16,30 @@ public class SplashScreen implements Screen { private float loadTime = 0; private int random = MathUtils.random(5); - private Texture logo = new Texture("images/samlogo.png"); + private Texture logo = new Texture("images/blackforestbytes_appstart.png"); private OrthographicCamera cam = new OrthographicCamera(); private SpriteBatch sB; - - @Override public void render(float delta) { - if(random == 0){ - Gdx.gl.glClearColor(0.4f, 0, 0, 1); // Rot - Gdx.gl.glClear(GL20.GL_COLOR_BUFFER_BIT); - }else if (random == 1){ - Gdx.gl.glClearColor(0.8f, 0.8f, 0, 1); //Gelb - Gdx.gl.glClear(GL20.GL_COLOR_BUFFER_BIT); - }else if ((random == 2)){ - Gdx.gl.glClearColor(1, 0.5f, 0.25f, 1); //Orange - Gdx.gl.glClear(GL20.GL_COLOR_BUFFER_BIT); - }else if (random == 3){ - Gdx.gl.glClearColor(0.25f, 0.5f, 1, 1); //Blau - Gdx.gl.glClear(GL20.GL_COLOR_BUFFER_BIT); - }else if (random == 4){ - Gdx.gl.glClearColor(0, 0.8f, 0.3f, 1); //Grün - Gdx.gl.glClear(GL20.GL_COLOR_BUFFER_BIT); - }else if (random == 5){ - Gdx.gl.glClearColor(1, 1, 1, 1); //Weiß - Gdx.gl.glClear(GL20.GL_COLOR_BUFFER_BIT); - } - - + + + Gdx.gl.glClearColor(1, 1, 1, 1); //Weiß + Gdx.gl.glClear(GL20.GL_COLOR_BUFFER_BIT); + + + sB.begin(); sB.draw(logo, -9, -8, 18, 16); sB.end(); loadTime += delta; - if (loadTime > 0.5) + if (loadTime > 1.9) ((Game) Gdx.app.getApplicationListener()).setScreen(new MainMenu()); }