Skip to content
Snippets Groups Projects
Commit 60a3085c authored by Leonard Haddad's avatar Leonard Haddad :rocket:
Browse files

Merge branch 'setup' into 'master'

added bunch of stuff in UI

See merge request reswp-2020/galaxytrucker!8
parents 19c47730 970fe04e
No related branches found
No related tags found
No related merge requests found
Showing
with 528 additions and 37 deletions
package com.galaxytrucker.galaxytruckerreloaded.IO.Screen;
public class MainMenu {
}
package com.galaxytrucker.galaxytruckerreloaded.IO.Screen;
public class Map {
}
package com.galaxytrucker.galaxytruckerreloaded.IO.Screen;
public interface Screen {
}
package com.galaxytrucker.galaxytruckerreloaded;
import com.badlogic.gdx.ApplicationAdapter;
import com.badlogic.gdx.Game;
import com.badlogic.gdx.Gdx;
import com.badlogic.gdx.graphics.GL20;
import com.badlogic.gdx.graphics.Texture;
import com.badlogic.gdx.graphics.g2d.SpriteBatch;
public class Main extends ApplicationAdapter {
public class Main extends Game {
SpriteBatch batch;
Texture img;
......
package com.galaxytrucker.galaxytruckerreloaded.View;
public interface BaseRenderer {
/** Setup */
public void setup();
/** Render */
public void render();
}
package com.galaxytrucker.galaxytruckerreloaded.View.Screen;
import com.badlogic.gdx.Screen;
import com.badlogic.gdx.audio.Music;
import com.badlogic.gdx.audio.Sound;
import com.badlogic.gdx.graphics.OrthographicCamera;
import com.badlogic.gdx.graphics.Texture;
import com.badlogic.gdx.graphics.g2d.SpriteBatch;
import com.galaxytrucker.galaxytruckerreloaded.Main;
/**
* Main game screen
*/
public class GamePlay implements Screen {
/**
* SpriteBatch
*/
private SpriteBatch batch;
/**
* Orthographic camera
*/
private OrthographicCamera camera;
/**
* Background texture
*/
private Texture background;
/**
* Main class for spriteBatch
*/
private Main mainClass;
/**
* Looping music
*/
private Music music;
/**
* Click sound effect
*/
private Sound clickSound;
@Override
public void show() {
}
@Override
public void render(float delta) {
}
@Override
public void resize(int width, int height) {
}
@Override
public void pause() {
}
@Override
public void resume() {
}
@Override
public void hide() {
}
@Override
public void dispose() {
}
/**
* Change the background
*
* @param background - the new background
*/
public void setBackground(Texture background) {
this.background = background;
}
/**
* Constructor
*/
public GamePlay(Main main) {
}
}
package com.galaxytrucker.galaxytruckerreloaded.View.Screen;
import com.badlogic.gdx.Screen;
import com.badlogic.gdx.audio.Music;
import com.badlogic.gdx.audio.Sound;
import com.badlogic.gdx.graphics.OrthographicCamera;
import com.badlogic.gdx.graphics.Texture;
import com.badlogic.gdx.graphics.g2d.SpriteBatch;
import com.badlogic.gdx.scenes.scene2d.ui.ImageButton;
import com.badlogic.gdx.scenes.scene2d.ui.TextField;
import com.galaxytrucker.galaxytruckerreloaded.Main;
/**
* Login Screen
*/
public class LoginScreen implements Screen {
/**
* SpriteBatch
*/
private SpriteBatch batch;
/**
* Orthographic camera
*/
private OrthographicCamera camera;
/**
* Background image
*/
private Texture background;
/**
* Username input text field
*/
private TextField username;
/**
* Login button
*/
private ImageButton loginButton;
/**
* Main class for spriteBatch
*/
private Main mainClass;
/**
* Looping music track
*/
private Music music;
/**
* Click sound effect
*/
private Sound clickSound;
@Override
public void show() {
}
@Override
public void render(float delta) {
}
@Override
public void resize(int width, int height) {
}
@Override
public void pause() {
}
@Override
public void resume() {
}
@Override
public void hide() {
}
@Override
public void dispose() {
}
/** Constructor */
public LoginScreen(Main main){}
}
package com.galaxytrucker.galaxytruckerreloaded.View.Screen;
import com.badlogic.gdx.Screen;
import com.badlogic.gdx.audio.Music;
import com.badlogic.gdx.audio.Sound;
import com.badlogic.gdx.graphics.OrthographicCamera;
import com.badlogic.gdx.graphics.Texture;
import com.badlogic.gdx.graphics.g2d.SpriteBatch;
import com.badlogic.gdx.scenes.scene2d.ui.ImageButton;
import com.galaxytrucker.galaxytruckerreloaded.Main;
/**
* Main menu screen
*/
public class MainMenu implements Screen {
/**
* The sprite batch
*/
private SpriteBatch batch;
/**
* Orthographic camera
*/
private OrthographicCamera camera;
/**
* The screen texture
*/
private Texture background;
/**
* SinglePlayer button
*/
private ImageButton singleplayerButton;
/**
* SinglePlayer button texture
*/
private Texture singleplayerButtonTexture;
/**
* MultiPlayer button
*/
private ImageButton multiplayerButton;
/**
* MultiPlayer button texture
*/
private Texture multiplayerButtonTexture;
/**
* Options button
*/
private ImageButton optionsButton;
/**
* Option button texture
*/
private Texture optionsButtonTexture;
/**
* Quit button
*/
private ImageButton quitButton;
/**
* Quit button texture
*/
private ImageButton quitButtonTexture;
/**
* Main class for accessing SpriteBatch
*/
private Main mainClass;
/**
* Looping music track
*/
private Music music;
/**
* Click sound effect
*/
private Sound clickSound;
@Override
public void show() {
}
@Override
public void render(float delta) {
}
@Override
public void resize(int width, int height) {
}
@Override
public void pause() {
}
@Override
public void resume() {
}
@Override
public void hide() {
}
@Override
public void dispose() {
}
/** Constructor */
public MainMenu(Main main){}
}
package com.galaxytrucker.galaxytruckerreloaded.View.Screen;
import com.badlogic.gdx.Screen;
import com.badlogic.gdx.audio.Music;
import com.badlogic.gdx.audio.Sound;
import com.badlogic.gdx.graphics.OrthographicCamera;
import com.badlogic.gdx.graphics.Texture;
import com.badlogic.gdx.graphics.g2d.SpriteBatch;
import com.galaxytrucker.galaxytruckerreloaded.Main;
/**
* Ship selector screen when creating new game
*/
public class ShipSelector implements Screen {
/**
* Sprite batch
*/
private SpriteBatch batch;
/**
* Orthographic camera
*/
private OrthographicCamera camera;
/**
* Background
*/
private Texture background;
/**
* Looping music
*/
private Music music;
/**
* Click sound effect
*/
private Sound clickSound;
@Override
public void show() {
}
@Override
public void render(float delta) {
}
@Override
public void resize(int width, int height) {
}
@Override
public void pause() {
}
@Override
public void resume() {
}
@Override
public void hide() {
}
@Override
public void dispose() {
}
/** Constructor */
public ShipSelector(Main main){}
}
package com.galaxytrucker.galaxytruckerreloaded.View.Ship;
import com.galaxytrucker.galaxytruckerreloaded.View.BaseRenderer;
public abstract class ShipView implements BaseRenderer {
}
package com.galaxytrucker.galaxytruckerreloaded.View.UI.Inventory;
import com.galaxytrucker.galaxytruckerreloaded.Main;
public class InventorySlot {
/** Constructor */
public InventorySlot(Main main){}
}
package com.galaxytrucker.galaxytruckerreloaded.View.UI;
import com.galaxytrucker.galaxytruckerreloaded.Main;
public class InventoryUI {
/** Constructor */
public InventoryUI(Main main){}
}
package com.galaxytrucker.galaxytruckerreloaded.View.UI.Options;
import com.badlogic.gdx.graphics.OrthographicCamera;
import com.badlogic.gdx.graphics.Texture;
import com.badlogic.gdx.graphics.g2d.SpriteBatch;
import com.badlogic.gdx.scenes.scene2d.ui.ImageButton;
import com.galaxytrucker.galaxytruckerreloaded.Main;
/**
* Ingame options UI
*/
public class OptionsUI {
/**
* SpriteBatch
*/
private SpriteBatch batch;
/**
* Orthographic camera
*/
private OrthographicCamera camera;
/**
* Continue button
*/
private ImageButton continueButton;
/**
* Continue button image
*/
private Texture continueButtonTexture;
/**
* Main Menu button
*/
private ImageButton mainMenuButton;
/**
* Main Menu button texture
*/
private Texture mainMenuButtonTexture;
/**
* Quit button
*/
private ImageButton quitButton;
/**
* Quit button texture
*/
private Texture quitButtonTexture;
/**
* Main class for sprite batch
*/
private Main mainClass;
/**
* Setup called after initialisation
*/
private void setup() {
}
/**
* Open the options menu
*/
public void openOptions() {
}
/**
* Close the options menu
*/
public void closeOptions() {
}
/**
* Constructor
*/
public OptionsUI(Main main) {
setup();
}
}
package com.galaxytrucker.galaxytruckerreloaded.View.UI.ShipInformation;
import com.badlogic.gdx.graphics.Texture;
import com.badlogic.gdx.graphics.g2d.SpriteBatch;
import com.badlogic.gdx.scenes.scene2d.ui.List;
import com.galaxytrucker.galaxytruckerreloaded.Main;
/**
* HullUI
*/
public class HullUI {
/**
* SpriteBatch
*/
private SpriteBatch batch;
/**
* Textures
*/
private List<Texture> hullTextures;
/**
* Main class for sprite batch
*/
private Main mainClass;
/**
* Constructor
*/
public HullUI(Main main) {
}
}
package com.galaxytrucker.galaxytruckerreloaded.View.Weapons;
import com.galaxytrucker.galaxytruckerreloaded.View.BaseRenderer;
public abstract class WeaponView implements BaseRenderer {
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment