• LibGDX 1.9.9 • GWT w wersji 2.8.0 • Project Structure (File -> Project Structure): - Project: Android Gradle Plugin Version: 3.4.1 Gradle Version: 5.4.1 - Variables: [android, desktop, html]: gdxVersion 1.9.9 ashleyVersion 1.7.4 gdxControllersVersion 2.1.0 • W pliku MyGdxGame.gwt.xml w folderze "core", zmienić linijk nr 4 na • Przekonwertować poziomy w programie Tiled ze skompresowanych na nieskompresowane • gradlew html:clean • html\war\assets usunąć stary plik "assets.txt" (o ile jest jeszcze) • Zamień wszystkie pliki z folderu: html\war\ na pliki z: libgdx-gdx-parent-1.9.9\extensions\gdx-setup\src\com\badlogic\gdx\setup\resources\html\war (Plik "libgdx-gdx-parent-1.9.9.zip" jest do pobrania ze stony github-a: https://github.com/libgdx/libgdx/tree/gdx-parent-1.9.9/) Zmień nazwę pliku index na index.html • Uruchom polecenie w termnalu: gradlew html:dist Przekopiować na serwer pliki z folderu: html\build\dist • Przykładowa zawartość pliku build.grade (skrypt "główny" dla całego projektu - w folderze głównym projektu): buildscript { repositories { mavenLocal() mavenCentral() maven { url "https://plugins.gradle.org/m2/" } maven { url "https://oss.sonatype.org/content/repositories/snapshots/" } google() } dependencies { classpath 'org.wisepersist:gwt-gradle-plugin:1.0.13' classpath 'org.gretty:gretty:3.0.2' classpath 'com.android.tools.build:gradle:3.4.1' classpath 'com.mobidevelop.robovm:robovm-gradle-plugin:2.3.12' } } allprojects { apply plugin: "eclipse" version = '1.0' ext { appName = "LicencjatProjekt" gdxVersion = '1.9.9' //roboVMVersion = '2.3.12' //box2DLightsVersion = '1.5' ashleyVersion = '1.7.4' //aiVersion = '1.8.2' gdxControllersVersion = '2.1.0' } repositories { mavenLocal() mavenCentral() google() maven { url "https://oss.sonatype.org/content/repositories/snapshots/" } maven { url "https://oss.sonatype.org/content/repositories/releases/" } } } project(":desktop") { apply plugin: "java-library" dependencies { implementation project(":core") api "com.badlogicgames.gdx:gdx-backend-lwjgl:$gdxVersion" api "com.badlogicgames.gdx:gdx-platform:$gdxVersion:natives-desktop" api "com.badlogicgames.gdx:gdx-box2d-platform:$gdxVersion:natives-desktop" api "com.badlogicgames.gdx:gdx-tools:$gdxVersion" api "com.badlogicgames.gdx:gdx-freetype-platform:$gdxVersion:natives-desktop" } } project(":android") { apply plugin: "com.android.application" configurations { natives } dependencies { implementation project(":core") api "com.badlogicgames.gdx:gdx-backend-android:$gdxVersion" natives "com.badlogicgames.gdx:gdx-platform:$gdxVersion:natives-armeabi" natives "com.badlogicgames.gdx:gdx-platform:$gdxVersion:natives-armeabi-v7a" natives "com.badlogicgames.gdx:gdx-platform:$gdxVersion:natives-arm64-v8a" natives "com.badlogicgames.gdx:gdx-platform:$gdxVersion:natives-x86" natives "com.badlogicgames.gdx:gdx-platform:$gdxVersion:natives-x86_64" api "com.badlogicgames.gdx:gdx-box2d:$gdxVersion" natives "com.badlogicgames.gdx:gdx-box2d-platform:$gdxVersion:natives-armeabi" natives "com.badlogicgames.gdx:gdx-box2d-platform:$gdxVersion:natives-armeabi-v7a" natives "com.badlogicgames.gdx:gdx-box2d-platform:$gdxVersion:natives-arm64-v8a" natives "com.badlogicgames.gdx:gdx-box2d-platform:$gdxVersion:natives-x86" natives "com.badlogicgames.gdx:gdx-box2d-platform:$gdxVersion:natives-x86_64" api "com.badlogicgames.gdx:gdx-freetype:$gdxVersion" natives "com.badlogicgames.gdx:gdx-freetype-platform:$gdxVersion:natives-armeabi" natives "com.badlogicgames.gdx:gdx-freetype-platform:$gdxVersion:natives-armeabi-v7a" natives "com.badlogicgames.gdx:gdx-freetype-platform:$gdxVersion:natives-arm64-v8a" natives "com.badlogicgames.gdx:gdx-freetype-platform:$gdxVersion:natives-x86" natives "com.badlogicgames.gdx:gdx-freetype-platform:$gdxVersion:natives-x86_64" //api "com.badlogicgames.box2dlights:box2dlights:$box2DLightsVersion" //api "com.badlogicgames.gdx:gdx-ai:$aiVersion" api "com.badlogicgames.ashley:ashley:$ashleyVersion" } } project(":html") { apply plugin: "java-library" apply plugin: "gwt" apply plugin: "war" apply plugin: "org.gretty" dependencies { implementation project(":core") api "com.badlogicgames.gdx:gdx-backend-gwt:$gdxVersion" api "com.badlogicgames.gdx:gdx:$gdxVersion:sources" api "com.badlogicgames.gdx:gdx-backend-gwt:$gdxVersion:sources" api "com.badlogicgames.gdx:gdx-box2d:$gdxVersion:sources" api "com.badlogicgames.gdx:gdx-box2d-gwt:$gdxVersion:sources" //api "com.badlogicgames.box2dlights:box2dlights:$box2DLightsVersion:sources" //api "com.badlogicgames.gdx:gdx-ai:$aiVersion:sources" //api "com.badlogicgames.ashley:ashley:$ashleyVersion:sources" //api "net.dermetfan.libgdx-utils:libgdx-utils:0.13.4:sources" api "net.dermetfan.libgdx-utils:libgdx-utils-box2d:0.13.4:sources" api "net.dermetfan.libgdx-utils:libgdx-utils:0.13.4:sources" //api "com.google.gwt:gwt-user:2.8.0:sources" } } project(":core") { apply plugin: "java-library" dependencies { api "com.badlogicgames.gdx:gdx:$gdxVersion" api "com.badlogicgames.gdx:gdx-box2d:$gdxVersion" api "com.badlogicgames.gdx:gdx-freetype:$gdxVersion" //api "com.badlogicgames.box2dlights:box2dlights:$box2DLightsVersion" //api "com.badlogicgames.gdx:gdx-ai:$aiVersion" //api "com.badlogicgames.ashley:ashley:$ashleyVersion" api "net.dermetfan.libgdx-utils:libgdx-utils-box2d:0.13.4" api "net.dermetfan.libgdx-utils:libgdx-utils:0.13.4" //api "com.underwaterapps.overlap2druntime:overlap2d-runtime-libgdx:0.1.0" //api "com.esotericsoftware.spine:spine-libgdx:3.6.53.1" } }