diff options
author | Jérémy Zurcher <jeremy@asynk.ch> | 2018-06-27 00:28:49 +0200 |
---|---|---|
committer | Jérémy Zurcher <jeremy@asynk.ch> | 2018-06-28 16:24:48 +0200 |
commit | 926ff7439cb4298f482e6c73de393550f4827a31 (patch) | |
tree | 276c5d23a6f8c1c468266765a9fafdaebe8b8d49 | |
parent | b6f07387af85687bf957e3e75e664be5ce972bd4 (diff) | |
download | gdx-boardgame-926ff7439cb4298f482e6c73de393550f4827a31.zip gdx-boardgame-926ff7439cb4298f482e6c73de393550f4827a31.tar.gz |
build ./android/assets from ./assets
-rw-r--r-- | .gitignore | 1 | ||||
-rw-r--r-- | android/assets/data/loading.atlas | 34 | ||||
-rw-r--r-- | android/assets/data/loading.png | bin | 14501 -> 0 bytes | |||
-rw-r--r-- | assets/build.gradle | 33 | ||||
-rw-r--r-- | assets/data/corner.png (renamed from android/assets/data/corner.png) | bin | 1513 -> 1513 bytes | |||
-rw-r--r-- | assets/data/map_00.png (renamed from android/assets/data/map_00.png) | bin | 3880220 -> 3880220 bytes | |||
-rw-r--r-- | assets/loading/bar.png | bin | 0 -> 621 bytes | |||
-rw-r--r-- | assets/loading/border.png | bin | 0 -> 2299 bytes | |||
-rw-r--r-- | assets/loading/loaded.png | bin | 0 -> 5898 bytes | |||
-rw-r--r-- | assets/loading/loading.png | bin | 0 -> 3727 bytes | |||
-rw-r--r-- | build.gradle | 4 | ||||
-rwxr-xr-x | do | 6 | ||||
-rw-r--r-- | settings.gradle | 2 |
13 files changed, 45 insertions, 35 deletions
@@ -1,6 +1,7 @@ ## Mine *~ .tags +/android/assets ## Java diff --git a/android/assets/data/loading.atlas b/android/assets/data/loading.atlas deleted file mode 100644 index cb8c853..0000000 --- a/android/assets/data/loading.atlas +++ /dev/null @@ -1,34 +0,0 @@ - -loading.png -size: 1024,128 -format: RGBA8888 -filter: Nearest,Nearest -repeat: none -bar - rotate: false - xy: 2, 18 - size: 692, 27 - orig: 692, 27 - offset: 0, 0 - index: -1 -border - rotate: false - xy: 2, 47 - size: 700, 36 - orig: 700, 36 - offset: 0, 0 - index: -1 -loaded - rotate: false - xy: 704, 69 - size: 276, 14 - orig: 276, 14 - offset: 0, 0 - index: -1 -loading - rotate: false - xy: 2, 2 - size: 130, 14 - orig: 130, 14 - offset: 0, 0 - index: -1 diff --git a/android/assets/data/loading.png b/android/assets/data/loading.png Binary files differdeleted file mode 100644 index c68fdd7..0000000 --- a/android/assets/data/loading.png +++ /dev/null diff --git a/assets/build.gradle b/assets/build.gradle new file mode 100644 index 0000000..1ef0761 --- /dev/null +++ b/assets/build.gradle @@ -0,0 +1,33 @@ +configurations { + texturePacker +} + +dependencies { + texturePacker "com.badlogicgames.gdx:gdx-tools:$gdxVersion" +} + +defaultTasks 'build' + +task clean(type: Delete) { + delete '../android/assets' +} + +task copyData(type: Copy) { + from 'data' + into '../android/assets/data' +} + +task packLoading(type: JavaExec) { + main = 'com.badlogic.gdx.tools.texturepacker.TexturePacker' + classpath = configurations.texturePacker + args = ['./loading', '../android/assets/data', 'loading'] +} + +/* task buildUI(dependsOn: ["processXHDPI"]) { */ +task build(dependsOn: clean) { + description "Builds the skin at various DPIs" +} + +build.dependsOn { + tasks.findAll { task -> (task.name.startsWith('pack') || task.name.startsWith('copy')) } +} diff --git a/android/assets/data/corner.png b/assets/data/corner.png Binary files differindex 7b9e8f4..7b9e8f4 100644 --- a/android/assets/data/corner.png +++ b/assets/data/corner.png diff --git a/android/assets/data/map_00.png b/assets/data/map_00.png Binary files differindex d2c6961..d2c6961 100644 --- a/android/assets/data/map_00.png +++ b/assets/data/map_00.png diff --git a/assets/loading/bar.png b/assets/loading/bar.png Binary files differnew file mode 100644 index 0000000..0e707de --- /dev/null +++ b/assets/loading/bar.png diff --git a/assets/loading/border.png b/assets/loading/border.png Binary files differnew file mode 100644 index 0000000..8354e38 --- /dev/null +++ b/assets/loading/border.png diff --git a/assets/loading/loaded.png b/assets/loading/loaded.png Binary files differnew file mode 100644 index 0000000..d7df58f --- /dev/null +++ b/assets/loading/loaded.png diff --git a/assets/loading/loading.png b/assets/loading/loading.png Binary files differnew file mode 100644 index 0000000..e609553 --- /dev/null +++ b/assets/loading/loading.png diff --git a/build.gradle b/build.gradle index 2504886..180f67a 100644 --- a/build.gradle +++ b/build.gradle @@ -91,6 +91,10 @@ project(":core") { } } +project(":assets") { + configurations { texturePacker } +} + task ctags(type: Exec) { executable "ctags" args "-R", "--language-force=java", "--exclude=*~", "-f.tags", "core/src/" @@ -8,6 +8,12 @@ function gradlew_do() } case "$1" in +# clean + "c") + shift; + ARGS="clean assets:build $ARGS" + gradlew_do + ;; # dist "d") shift; diff --git a/settings.gradle b/settings.gradle index 14bee42..15de458 100644 --- a/settings.gradle +++ b/settings.gradle @@ -1 +1 @@ -include 'desktop', 'android', 'html', 'core'
\ No newline at end of file +include 'desktop', 'android', 'html', 'core', 'assets' |