Commit c84afdb2 authored by Anders H. Rebner's avatar Anders H. Rebner
Browse files

Renamed Client and Server-file to SpaceCheckers

parent 5fb4be88
...@@ -10,6 +10,6 @@ public class AndroidLauncher extends AndroidApplication { ...@@ -10,6 +10,6 @@ public class AndroidLauncher extends AndroidApplication {
protected void onCreate (Bundle savedInstanceState) { protected void onCreate (Bundle savedInstanceState) {
super.onCreate(savedInstanceState); super.onCreate(savedInstanceState);
AndroidApplicationConfiguration config = new AndroidApplicationConfiguration(); AndroidApplicationConfiguration config = new AndroidApplicationConfiguration();
initialize(new UniCheckersClient(), config); initialize(new SpaceCheckersClient(), config);
} }
} }
...@@ -16,27 +16,18 @@ import com.mygdx.game.views.GameViewManager; ...@@ -16,27 +16,18 @@ import com.mygdx.game.views.GameViewManager;
import com.mygdx.game.views.LoadingView; import com.mygdx.game.views.LoadingView;
import java.util.ArrayList; import java.util.ArrayList;
public class UniCheckersClient extends ApplicationAdapter { public class SpaceCheckersClient extends ApplicationAdapter {
PlayerController playerController; PlayerController playerController;
private GameViewManager gvm; private GameViewManager gvm;
private SpriteBatch sb;
private AssetManager assetManager;
private Stage stage;
private Viewport viewport;
private Skin skin;
ArrayList<PlayerController> playerControllers = new ArrayList<>();
NetworkController networkController;
@Override @Override
public void create () { public void create () {
Gdx.gl.glClearColor(0, 0, 1, 1); Gdx.gl.glClearColor(0, 0, 1, 1);
viewport = new FitViewport(Gdx.graphics.getWidth(), Gdx.graphics.getHeight()); Viewport viewport = new FitViewport(Gdx.graphics.getWidth(), Gdx.graphics.getHeight());
stage = new Stage(viewport); Stage stage = new Stage(viewport);
Gdx.input.setInputProcessor(stage); Gdx.input.setInputProcessor(stage);
// Initialize controllers.. // Initialize controllers..
...@@ -44,10 +35,10 @@ public class UniCheckersClient extends ApplicationAdapter { ...@@ -44,10 +35,10 @@ public class UniCheckersClient extends ApplicationAdapter {
playerController = new PlayerController(networkController); playerController = new PlayerController(networkController);
// Initialize Views.. // Initialize Views..
sb = new SpriteBatch(); SpriteBatch sb = new SpriteBatch();
assetManager = new AssetManager(new InternalFileHandleResolver()); AssetManager assetManager = new AssetManager(new InternalFileHandleResolver());
skin = new Skin(Gdx.files.internal("UISkins/glassy/skin/glassy-ui.json")); Skin skin = new Skin(Gdx.files.internal("UISkins/glassy/skin/glassy-ui.json"));
skin.getFont("font").getData().setScale(1.4F); skin.getFont("font").getData().setScale(1.4F);
gvm = new GameViewManager(); gvm = new GameViewManager();
......
...@@ -2,7 +2,7 @@ package com.mygdx.game.desktop; ...@@ -2,7 +2,7 @@ package com.mygdx.game.desktop;
import com.badlogic.gdx.backends.lwjgl.LwjglApplication; import com.badlogic.gdx.backends.lwjgl.LwjglApplication;
import com.badlogic.gdx.backends.lwjgl.LwjglApplicationConfiguration; import com.badlogic.gdx.backends.lwjgl.LwjglApplicationConfiguration;
import com.mygdx.game.UniCheckersClient; import com.mygdx.game.SpaceCheckersClient;
import java.io.IOException; import java.io.IOException;
...@@ -11,7 +11,7 @@ public class DesktopLauncher { ...@@ -11,7 +11,7 @@ public class DesktopLauncher {
LwjglApplicationConfiguration config = new LwjglApplicationConfiguration(); LwjglApplicationConfiguration config = new LwjglApplicationConfiguration();
config.width = 2160; config.width = 2160;
config.height = 1080; config.height = 1080;
new LwjglApplication(new UniCheckersClient(), config); new LwjglApplication(new SpaceCheckersClient(), config);
} }
......
...@@ -10,6 +10,6 @@ public class AndroidLauncher extends AndroidApplication { ...@@ -10,6 +10,6 @@ public class AndroidLauncher extends AndroidApplication {
protected void onCreate (Bundle savedInstanceState) { protected void onCreate (Bundle savedInstanceState) {
super.onCreate(savedInstanceState); super.onCreate(savedInstanceState);
AndroidApplicationConfiguration config = new AndroidApplicationConfiguration(); AndroidApplicationConfiguration config = new AndroidApplicationConfiguration();
initialize(new UniCheckersServer(), config); initialize(new SpaceCheckersServer(), config);
} }
} }
...@@ -7,7 +7,7 @@ import com.badlogic.gdx.graphics.Texture; ...@@ -7,7 +7,7 @@ import com.badlogic.gdx.graphics.Texture;
import com.badlogic.gdx.graphics.g2d.SpriteBatch; import com.badlogic.gdx.graphics.g2d.SpriteBatch;
import com.mygdx.game.controller.ServerController; import com.mygdx.game.controller.ServerController;
public class UniCheckersServer extends ApplicationAdapter { public class SpaceCheckersServer extends ApplicationAdapter {
SpriteBatch batch; SpriteBatch batch;
Texture img; Texture img;
......
...@@ -2,13 +2,13 @@ package com.mygdx.game.desktop; ...@@ -2,13 +2,13 @@ package com.mygdx.game.desktop;
import com.badlogic.gdx.backends.lwjgl.LwjglApplication; import com.badlogic.gdx.backends.lwjgl.LwjglApplication;
import com.badlogic.gdx.backends.lwjgl.LwjglApplicationConfiguration; import com.badlogic.gdx.backends.lwjgl.LwjglApplicationConfiguration;
import com.mygdx.game.UniCheckersServer; import com.mygdx.game.SpaceCheckersServer;
import java.io.IOException; import java.io.IOException;
public class DesktopLauncher { public class DesktopLauncher {
public static void main (String[] arg) throws IOException { public static void main (String[] arg) throws IOException {
LwjglApplicationConfiguration config = new LwjglApplicationConfiguration(); LwjglApplicationConfiguration config = new LwjglApplicationConfiguration();
new LwjglApplication(new UniCheckersServer(), config); new LwjglApplication(new SpaceCheckersServer(), config);
} }
} }
\ No newline at end of file
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment