After closing Intel XDK I started seek for another tool to convert my html5/phaser game to android. So, I watched some videos on YouTube and decide to try using Cordova and Node.js command line.
I downloaded and installed Android Studio, Node.js and JDK (8u162 version, because it is the last version for Windows 32-bit, as I see).
After installing cordova with node.js command line and creating a new project I tried to build my project and I have next error:
D:\Android\Development\datesniper>cordova prepare
Android Studio project detected
D:\Android\Development\datesniper>cordova build android --debug
Android Studio project detected
ANDROID_HOME=C:\Users\Aleksey\AppData\Local\Android\sdk
JAVA_HOME=D:\Java\jdk-8u162
studio
Subproject Path: CordovaLib
Subproject Path: app
Starting a Gradle Daemon (subsequent builds will be faster)
FAILURE: Build failed with an exception.
* What went wrong:
Unable to start the daemon process.
This problem might be caused by incorrect configuration of the daemon.
For example, an unrecognized jvm option is used.
Please refer to the user guide chapter on the daemon at https://docs.gradle.org/
4.1/userguide/gradle_daemon.html
Please read the following process output to find out more:
-----------------------
Error occurred during initialization of VM
Could not reserve enough space for 2097152KB object heap
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug
option to get more log output.
* Get more help at https://help.gradle.org
(node:4316) UnhandledPromiseRejectionWarning: Error: cmd: Command failed with ex
it code 1 Error output:
FAILURE: Build failed with an exception.
* What went wrong:
Unable to start the daemon process.
This problem might be caused by incorrect configuration of the daemon.
For example, an unrecognized jvm option is used.
Please refer to the user guide chapter on the daemon at https://docs.gradle.org/
4.1/userguide/gradle_daemon.html
Please read the following process output to find out more:
-----------------------
Error occurred during initialization of VM
Could not reserve enough space for 2097152KB object heap
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug
option to get more log output.
* Get more help at https://help.gradle.org
at ChildProcess.whenDone (D:\Android\Development\datesniper\platforms\androi
d\cordova\node_modules\cordova-common\src\superspawn.js:169:23)
at emitTwo (events.js:126:13)
at ChildProcess.emit (events.js:214:7)
at maybeClose (internal/child_process.js:925:16)
at Process.ChildProcess._handle.onexit (internal/child_process.js:209:5)
(node:4316) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This
error originated either by throwing inside of an async function without a catch
block, or by rejecting a promise which was not handled with .catch(). (rejection
id: 1)
(node:4316) [DEP0018] DeprecationWarning: Unhandled promise rejections are depre
cated. In the future, promise rejections that are not handled will terminate the
Node.js process with a non-zero exit code.
D:\Android\Development\datesniper>
What can I do? Is there some other (less complicated) way to convert my phaser game to android?
Thanks!
Update: when I try to create new project in Android Studio, there is a mistake while building: Gradle sync failed: CreateProcess error=216, Version "%1" is not compatible with the version of Windows running on this computer.
How can I replace gradle version for 32-bit Windows?