Samples: update with scaled tile size #183

This commit is contained in:
Emux
2016-09-25 19:02:08 +03:00
parent c991666d97
commit 2a2b30f9fc
21 changed files with 157 additions and 22 deletions

View File

@@ -45,21 +45,20 @@ public class GdxMapApp extends GdxMap {
}
public static void main(String[] args) {
Tile.SIZE = 360;
init();
new LwjglApplication(new GdxMapApp(), getConfig());
}
public static void run(GdxMap map) {
run(map, null, Tile.SIZE);
}
public static void run(GdxMap map, LwjglApplicationConfiguration config, int tileSize) {
Tile.SIZE = FastMath.clamp(tileSize, 128, 512);
new LwjglApplication(map, (config == null ? getConfig() : config));
}
public static void run(LwjglApplicationConfiguration config, int tileSize, GdxMap map) {
run(map, config, tileSize);
}
static protected LwjglApplicationConfiguration getConfig() {
LwjglApplicationConfiguration cfg = new LwjglApplicationConfiguration();
cfg.title = "vtm-gdx";