Android Development Questions—JDK and Presplash/Downloading images

Discuss how to use the Ren'Py engine to create visual novels and story-based games. New releases are announced in this section.
Forum rules
This is the right place for Ren'Py help. Please ask one question per thread, use a descriptive subject like 'NotFound error in option.rpy' , and include all the relevant information - especially any relevant code and traceback messages. Use the code tag to format scripts.
Post Reply
Message
Author
limpciabatta
Newbie
Posts: 13
Joined: Sun Feb 19, 2023 10:22 pm
Contact:

Android Development Questions—JDK and Presplash/Downloading images

#1 Post by limpciabatta »

Hi, I've been trying to figure out what I need/how I should go about exporting my Ren'Py project as an Android app that users can play on their Android devices, and after reviewing the documentation here (https://www.renpy.org/doc/html/android.html#android), I have a few questions, primarily about the Java Development Kit and the presplash/downloading images. If you're able to help provide some clarity for me on these topics, I'd greatly appreciate it!

1: To start, I've downloaded the Java Development Kit found here: https://adoptium.net/ —I'm using a mac and downloaded Temurin for macOSx64. However, the Ren'Py documentation says that I need version 8 of the JDK (here: https://adoptopenjdk.net/releases.html? ... nt=hotspot)—is this just something in the documentation that needs to be updated to reflect the latest updates of the JDK, or should I find a way to download OpenJDK 8?

2: I downloaded Temurin for macOSx64 to my downloads folder, and then I've gone into the Ren'Py launcher>Android and selected Install SDK & Create Keys. However, I receive the following error message:

Code: Select all

I'm sorry, but an uncaught exception occurred.

While running game code:
  File "game/android.rpy", line 507, in <module>
  File "game/mobilebuild.rpy", line 214, in call
  File "game/mobilebuild.rpy", line 238, in check_process
CalledProcessError: Command '['java', '-classpath', '/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/rapt/buildlib', 'CheckJDK8']' returned non-zero exit status 1.

-- Full Traceback ------------------------------------------------------------

Full traceback:
  File "launcher/game/android.rpyc", line 505, in script
  File "/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/renpy/ast.py", line 1131, in execute
    renpy.python.py_exec_bytecode(self.code.bytecode, self.hide, store=self.store)
  File "/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/renpy/python.py", line 1061, in py_exec_bytecode
    exec(bytecode, globals, locals)
  File "game/android.rpy", line 507, in <module>
  File "/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/rapt/buildlib/rapt/install_sdk.py", line 356, in install_sdk
    check_java(interface)
  File "/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/rapt/buildlib/rapt/install_sdk.py", line 55, in check_java
    if not run_slow(interface, plat.java, "-classpath", plat.path("buildlib"), "CheckJDK8", use_path=True):
  File "/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/rapt/buildlib/rapt/install_sdk.py", line 37, in run_slow
    interface.call(args, cancel=True, **kwargs)
  File "game/mobilebuild.rpy", line 214, in call
  File "/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/renpy/exports.py", line 3181, in call_screen
    rv = renpy.ui.interact(mouse="screen", type="screen", roll_forward=roll_forward)
  File "/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/renpy/ui.py", line 299, in interact
    rv = renpy.game.interface.interact(roll_forward=roll_forward, **kwargs)
  File "/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/renpy/display/core.py", line 3377, in interact
    repeat, rv = self.interact_core(preloads=preloads, trans_pause=trans_pause, pause=pause, pause_start=pause_start, pause_modal=pause_modal, **kwargs) # type: ignore
  File "/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/renpy/display/core.py", line 4258, in interact_core
    rv = root_widget.event(ev, x, y, 0)
  File "/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/renpy/display/layout.py", line 1175, in event
    rv = i.event(ev, x - xo, y - yo, cst)
  File "/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/renpy/display/layout.py", line 1175, in event
    rv = i.event(ev, x - xo, y - yo, cst)
  File "/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/renpy/display/layout.py", line 1175, in event
    rv = i.event(ev, x - xo, y - yo, cst)
  File "/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/renpy/display/screen.py", line 743, in event
    rv = self.child.event(ev, x, y, st)
  File "/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/renpy/display/layout.py", line 1175, in event
    rv = i.event(ev, x - xo, y - yo, cst)
  File "/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/renpy/display/behavior.py", line 2418, in event
    return run(self.function, *self.args, **self.kwargs)
  File "/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/renpy/display/behavior.py", line 329, in run
    return action(*args, **kwargs)
  File "game/mobilebuild.rpy", line 238, in check_process
CalledProcessError: Command '['java', '-classpath', '/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/rapt/buildlib', 'CheckJDK8']' returned non-zero exit status 1.

macOS-10.16-x86_64-i386-64bit x86_64
Ren'Py 8.0.3.22090809
Ren'Py Launcher 8.0.3.22090809
Tue Nov 21 07:32:20 2023
Am I getting this error because I'm using a wrong version of the JDK, the JDK wasn't installed in the correct folder, or is this due to another issue? And any advice on how to resolve this error?

3: Presplash and downloading images—is there any guidance on the sizes these images should be? I'm using the 2560x1440 screen dimensions for my game development, so would it be safe to assume that I should use those dimensions for these images, too?

Thank you so much, I really appreciate any help you're able to provide on these!

User avatar
Imperf3kt
Lemma-Class Veteran
Posts: 3807
Joined: Mon Dec 14, 2015 5:05 am
itch: Imperf3kt
Location: Your monitor
Contact:

Re: Android Development Questions—JDK and Presplash/Downloading images

#2 Post by Imperf3kt »

Ren'Py (currently) specifically required version 8, yes. Other versions will not work.
Warning: May contain trace amounts of gratuitous plot.
pro·gram·mer (noun) An organism capable of converting caffeine into code.

Current project: GGD Mentor

Twitter

limpciabatta
Newbie
Posts: 13
Joined: Sun Feb 19, 2023 10:22 pm
Contact:

Re: Android Development Questions—JDK and Presplash/Downloading images

#3 Post by limpciabatta »

Groovy, thanks! I've deleted the version of the JDK I previously downloaded and downloaded JDK8, although I'm still getting this error:

Code: Select all

I'm sorry, but an uncaught exception occurred.

While running game code:
  File "game/android.rpy", line 507, in <module>
  File "game/mobilebuild.rpy", line 214, in call
  File "game/mobilebuild.rpy", line 238, in check_process
CalledProcessError: Command '['/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/rapt/Sdk/cmdline-tools/latest/bin/sdkmanager', '--update']' returned non-zero exit status 1.

-- Full Traceback ------------------------------------------------------------

Full traceback:
  File "launcher/game/android.rpyc", line 505, in script
  File "/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/renpy/ast.py", line 1131, in execute
    renpy.python.py_exec_bytecode(self.code.bytecode, self.hide, store=self.store)
  File "/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/renpy/python.py", line 1061, in py_exec_bytecode
    exec(bytecode, globals, locals)
  File "game/android.rpy", line 507, in <module>
  File "/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/rapt/buildlib/rapt/install_sdk.py", line 360, in install_sdk
    get_packages(interface)
  File "/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/rapt/buildlib/rapt/install_sdk.py", line 179, in get_packages
    if not run_slow(interface, plat.sdkmanager, "--update", yes=True):
  File "/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/rapt/buildlib/rapt/install_sdk.py", line 37, in run_slow
    interface.call(args, cancel=True, **kwargs)
  File "game/mobilebuild.rpy", line 214, in call
  File "/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/renpy/exports.py", line 3181, in call_screen
    rv = renpy.ui.interact(mouse="screen", type="screen", roll_forward=roll_forward)
  File "/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/renpy/ui.py", line 299, in interact
    rv = renpy.game.interface.interact(roll_forward=roll_forward, **kwargs)
  File "/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/renpy/display/core.py", line 3377, in interact
    repeat, rv = self.interact_core(preloads=preloads, trans_pause=trans_pause, pause=pause, pause_start=pause_start, pause_modal=pause_modal, **kwargs) # type: ignore
  File "/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/renpy/display/core.py", line 4258, in interact_core
    rv = root_widget.event(ev, x, y, 0)
  File "/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/renpy/display/layout.py", line 1175, in event
    rv = i.event(ev, x - xo, y - yo, cst)
  File "/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/renpy/display/layout.py", line 1175, in event
    rv = i.event(ev, x - xo, y - yo, cst)
  File "/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/renpy/display/layout.py", line 1175, in event
    rv = i.event(ev, x - xo, y - yo, cst)
  File "/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/renpy/display/screen.py", line 743, in event
    rv = self.child.event(ev, x, y, st)
  File "/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/renpy/display/layout.py", line 1175, in event
    rv = i.event(ev, x - xo, y - yo, cst)
  File "/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/renpy/display/behavior.py", line 2418, in event
    return run(self.function, *self.args, **self.kwargs)
  File "/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/renpy/display/behavior.py", line 329, in run
    return action(*args, **kwargs)
  File "game/mobilebuild.rpy", line 238, in check_process
CalledProcessError: Command '['/Users/username/Documents/Primary/sides/Ocean/Abyssal Plain/Trench/writingfolder/Visual Novel/renpy-8.0.3-sdk/rapt/Sdk/cmdline-tools/latest/bin/sdkmanager', '--update']' returned non-zero exit status 1.

macOS-10.16-x86_64-i386-64bit x86_64
Ren'Py 8.0.3.22090809
Ren'Py Launcher 8.0.3.22090809
Wed Nov 22 05:22:50 2023

Upon further research/looking for instances where others have encountered the same error, I think it looks like I either don't have the JDK8 installed correctly/in the correct place, or I might need to set the JAVA_HOME system variable? I'm not sure how to do either of these (I'm using macOS Sonoma 14.1) though—are there any specific steps I can follow?

Thanks!

User avatar
Imperf3kt
Lemma-Class Veteran
Posts: 3807
Joined: Mon Dec 14, 2015 5:05 am
itch: Imperf3kt
Location: Your monitor
Contact:

Re: Android Development Questions—JDK and Presplash/Downloading images

#4 Post by Imperf3kt »

I'm sorry, I have no experience with macs, my last interaction with one being over 2 decades ago.

I don't recognise the bug you are experiencing
Warning: May contain trace amounts of gratuitous plot.
pro·gram·mer (noun) An organism capable of converting caffeine into code.

Current project: GGD Mentor

Twitter

Post Reply

Who is online

Users browsing this forum: Google [Bot], risukadekei