Ren'Py for Android: Launcher Test

In this forum we discuss the future of Ren'Py, both bug fixes and longer-term development. Pre-releases are announced and discussed here.
Message
Author
User avatar
PyTom
Ren'Py Creator
Posts: 15893
Joined: Mon Feb 02, 2004 10:58 am
Completed: Moonlight Walks
Projects: Ren'Py
IRC Nick: renpytom
Github: renpytom
itch: renpytom
Location: Kings Park, NY
Contact:

Ren'Py for Android: Launcher Test

#1 Post by PyTom » Sat Dec 18, 2010 3:25 am

ikadroid.jpg
The Question running on the Android emulator.
Developing on the emulator isn't recommended - it's slooow.
After a bit more work, I've nearly finished Android-specific Ren'Py development. And so, I'm happy to present the Ren'Py for Android Launcher Test. This fixes all of the bugs people have reported. It runs on a wider range of hardware, and fixes memory leaks that would cause crashing after a while. It also includes support for launching games distributed as android packages (so they could be in the market by themselves), and for launching games from the SD card.

The requirements haven't changed. This requires Android 2.0 or later, 16MB free space on the SD card, 100MB free ram, and working OpenGL ES 1.1 support. If you tried the old demo, please uninstall it before installing these packages. I don't (yet) support upgrades.

Today's release consists of two packages: We have the Ren'Py Launcher and The Question. QR codes:

Image

Image

When you install both packages, a "The Question" icon will show up on your launcher. Choosing it will cause The Question to start up. (If only TheQuestion-debug.apk is installed, then it will prompt you to install Ren'Py. That won't work, since we're not on Android Market yet.)

This version also supports developing for Android. You can do this by mounting your sdcard and putting the proper files on it. If your sdcard is located at sdcard, then you want something that looks like:

Code: Select all

sdcard/renpy/mygame/android.txt
sdcard/renpy/mygame/icon.png
sdcard/renpy/mygame/.nomedia
sdcard/renpy/mygame/game/script.rpy
sdcard/renpy/mygame/game/options.rpy
...
On windows, the sdcard will be a drive letter, so you'd have files like S:\renpy\mygame\android.txt.

The first three files are new. The android.txt file contains information that tells Ren'Py for android how to launch your game. It looks like:

Code: Select all

title=The Question
author=Mikey et al.
api=1
orientation=landscape
The title and author fields are self explanatory. The api should be set to 1 to tell Ren'Py what version to use - if you set it higher, Ren'Py will try to upgrade itself. The orientation can be landscape or portrait - you also need to set config.screen_width and config.screen_height to appropriate values.

The icon.png file is the icon to show in the launcher screen. The .nomedia file should be an empty file - it's used to prevent Android from scanning the game directory for pictures to show in the media gallery.

Once you have this on your SD card, you can re-mount the SD card on android, and run Ren'Py from the launcher. It will scan the SD card, give you a list of games there, and you can choose one of them to run.

Once again, thanks to all the testers, and I look forward to your feedback about this new version.

I plan to make Moonlight Walks a launch title for Ren'Py for Android. If you have a game, and you're willing to spend some time porting it and need help, let me know.
Supporting creators since 2004
(When was the last time you backed up your game?)
"Do good work." - Virgil Ivan "Gus" Grissom
"Silly and fun things are important." - Elon Musk
Software > Drama • https://www.patreon.com/renpytom

User avatar
jack_norton
Lemma-Class Veteran
Posts: 4067
Joined: Mon Jul 21, 2008 5:41 pm
Completed: Too many! See my homepage
Projects: A lot! See www.winterwolves.com
Tumblr: winterwolvesgames
Contact:

Re: Ren'Py for Android: Launcher Test

#2 Post by jack_norton » Sat Dec 18, 2010 4:15 am

A stupid question (maybe I missed it): you can port ANY game to renpy-android? Even supercustomized ones like mine? :D
follow me on Image Image Image
computer games

User avatar
PyTom
Ren'Py Creator
Posts: 15893
Joined: Mon Feb 02, 2004 10:58 am
Completed: Moonlight Walks
Projects: Ren'Py
IRC Nick: renpytom
Github: renpytom
itch: renpytom
Location: Kings Park, NY
Contact:

Re: Ren'Py for Android: Launcher Test

#3 Post by PyTom » Sat Dec 18, 2010 4:30 am

The answer to that is complex.

Certainly, we support the vast majority of features that Ren'Py supports. So you can expect things like screens and python logic to work exactly the same. So we support complex games.

The big difference is in how someone interacts with the device. Since everything is done by touch, you need to make the buttons big enough that someone can comfortably hit them with their fat fingers. Similarly, a touch device can only register touch, so it's the equivalent of a mouse that only register its position when the button is held down, and jumps to the upper-left when it's released. Finally, many devices don't have keyboards, so that's out.

There are a few missing features, for hardware and space reasons:
- No movie playback support.
- No ImageDissolve (also AlphaDissolve, AlphaBlend) support.
- A change in dissolve semantics.

But fundamentally, this is Ren'Py, with all its python and crazy extensibility - and not a cut-down engine.
Supporting creators since 2004
(When was the last time you backed up your game?)
"Do good work." - Virgil Ivan "Gus" Grissom
"Silly and fun things are important." - Elon Musk
Software > Drama • https://www.patreon.com/renpytom

User avatar
jack_norton
Lemma-Class Veteran
Posts: 4067
Joined: Mon Jul 21, 2008 5:41 pm
Completed: Too many! See my homepage
Projects: A lot! See www.winterwolves.com
Tumblr: winterwolvesgames
Contact:

Re: Ren'Py for Android: Launcher Test

#4 Post by jack_norton » Sat Dec 18, 2010 4:55 am

Nice. The small button problem is the same as iphone, grr :D for normal VN that isn't going to be a problem but for a RPG like Planet Stronghold it would definitely be (clicking on portraits to access inventory for example). Anyway is cool to know that the only real limit is on the game-design side and not coding!
follow me on Image Image Image
computer games

User avatar
netravelr
Miko-Class Veteran
Posts: 504
Joined: Thu Jan 28, 2010 2:31 am
Completed: Culina: Hands in the Kitchen, Culina: The Spirit of Cooking, Saving Zoey
Projects: Love at the Laundromat
Organization: Lakeview Interactive
Deviantart: netravelr
Location: USA
Contact:

Re: Ren'Py for Android: Launcher Test

#5 Post by netravelr » Sun Dec 19, 2010 12:42 am

Just finished The Question on my Droid. Looks like great progress and I have to try making something specifically for the Android soon now. :-)
Image
Technical Designer/Programmer
Game Design Portfolio - Project updates on my Twitter
Experienced in: C/C++/C#, Python, Unreal, Unity, and Flash
_________________
"Space can be very lonely. The greatest adventure is having someone share it with you."

vaiol123
Newbie
Posts: 9
Joined: Sat Aug 22, 2009 1:21 pm
Contact:

Re: Ren'Py for Android: Launcher Test

#6 Post by vaiol123 » Sun Dec 19, 2010 10:32 am

Darn AT&T and it's sideload restrictions...

Will definitely report back once I figure this out.

elbosco
Newbie
Posts: 1
Joined: Thu Dec 23, 2010 4:26 pm
Contact:

Re: Ren'Py for Android: Launcher Test

#7 Post by elbosco » Thu Dec 23, 2010 4:30 pm

Great! Many thanks from one Android Developer. Good job

fischer22
Regular
Posts: 60
Joined: Thu Apr 22, 2010 2:59 am
Contact:

Re: Ren'Py for Android: Launcher Test

#8 Post by fischer22 » Fri Dec 24, 2010 12:08 am

Sorry for the silly question, but how could I port and try MY visual novel (currently in development) on an android device?

User avatar
TGeorgeMihai
Newbie
Posts: 3
Joined: Mon Jan 03, 2011 2:00 pm
Contact:

Re: Ren'Py for Android: Launcher Test

#9 Post by TGeorgeMihai » Mon Jan 03, 2011 2:33 pm

Great, thank you :)

I'm new here but this is exactly what I was searching for...

I've tasted it on my LG Optimus (GT540) with Android 2.1 and works great. Fullspeed in game, the menu have a little delay (1~2 sec when you are in the game press the "Menu Key" to save or quit) but nothing that would ruin the overall great experience :D

I think this Android port is very good, works great on the minimum specs (Android 2.1 and 500-600Mhz procesor ). I've tested that if I recive a call the game will stop, but no, it worked perfect even after that.

iichan_lolbot
Veteran
Posts: 206
Joined: Tue Dec 30, 2008 9:18 am
Projects: iichan erogame
Contact:

Re: Ren'Py for Android: Launcher Test

#10 Post by iichan_lolbot » Sun Jan 16, 2011 4:57 pm

Hey, wow, it works just great! Our team plans to release at least 3 small VN (in russian, english and some other versions) using this!
So, there are 3 major questions we have:

1. Do you think this is a stable platform and releases can be already build using this version of RenPy engine? Are there any known limits on script and data (looks like 1366x768 game doesn't want to work)?
2. Distribution Builder. Do you plan adding a new target to "Win32-MacOS-Linux-Universal" list?
3. Tracebacks. We are just beginning to explorere this RenPy version and were unable to find traceback.txt after game failure. Does it even exist? Some of our games does not even start and we want to know why *^_^*


Also: I sometimes do renpy.utter_restart() when I need to do some dirty changes in settings or styles. Is it possible to keep it working on Android too? If no - ok, we will release 7 versions of one of our too-many-times-translated-game.

P.S. A bugreport - we tried cookbook's snow particle genetar and it leads application to crash after showing a particle.

User avatar
PyTom
Ren'Py Creator
Posts: 15893
Joined: Mon Feb 02, 2004 10:58 am
Completed: Moonlight Walks
Projects: Ren'Py
IRC Nick: renpytom
Github: renpytom
itch: renpytom
Location: Kings Park, NY
Contact:

Re: Ren'Py for Android: Launcher Test

#11 Post by PyTom » Sun Jan 16, 2011 5:16 pm

iichan_lolbot wrote:1. Do you think this is a stable platform and releases can be already build using this version of RenPy engine? Are there any known limits on script and data (looks like 1366x768 game doesn't want to work)?
In a word, no. I'm going to spend the next few days qualifying it, and I hope to make a release to Market shortly. What was the problem you had with a large game, and what device are you testing on?
2. Distribution Builder. Do you plan adding a new target to "Win32-MacOS-Linux-Universal" list?
Probably not, just because you need quite a bit of the android toolchain for it to work. Instead, you'll probably want to grab the PyGame for Android packaging tool from http://www.renpy.org/pygame/ - it will also work for Android.
3. Tracebacks. We are just beginning to explorere this RenPy version and were unable to find traceback.txt after game failure. Does it even exist? Some of our games does not even start and we want to know why *^_^*
I'll look into this. For now, you can use adb logcat to see output, including tracebacks.
Also: I sometimes do renpy.utter_restart() when I need to do some dirty changes in settings or styles. Is it possible to keep it working on Android too? If no - ok, we will release 7 versions of one of our too-many-times-translated-game.
Hm... maybe? I don't think you'd want to do this, because it will be very slow. But I don't see why it wouldn't work.
P.S. A bugreport - we tried cookbook's snow particle genetar and it leads application to crash after showing a particle.
I'll look into this. That code was rewritten recently, so it's possible that it's already fixed.
Supporting creators since 2004
(When was the last time you backed up your game?)
"Do good work." - Virgil Ivan "Gus" Grissom
"Silly and fun things are important." - Elon Musk
Software > Drama • https://www.patreon.com/renpytom

iichan_lolbot
Veteran
Posts: 206
Joined: Tue Dec 30, 2008 9:18 am
Projects: iichan erogame
Contact:

Re: Ren'Py for Android: Launcher Test

#12 Post by iichan_lolbot » Tue Jan 18, 2011 1:47 pm

A full traceback for snow failure:

Code: Select all

I/python  (  248):   File "/home/tom/ab/renpy-dev/renpy/bootstrap.py", line 270, in bootstrap
I/python  (  248):   File "/home/tom/ab/renpy-dev/renpy/main.py", line 313, in main
I/python  (  248):   File "/home/tom/ab/renpy-dev/renpy/main.py", line 93, in run
I/python  (  248):   File "/home/tom/ab/renpy-1000/renpy/execution.py", line 259, in run
I/python  (  248):   File "/home/tom/ab/renpy-1000/renpy/ast.py", line 942, in execute
I/python  (  248):   File "/home/tom/ab/renpy-1000/renpy/exports.py", line 748,in with_statement
I/python  (  248):   File "/home/tom/ab/renpy-dev/renpy/display/core.py", line 1405, in do_with
I/python  (  248):   File "/home/tom/ab/renpy-dev/renpy/display/core.py", line 1595, in interact
I/python  (  248):   File "/home/tom/ab/renpy-dev/renpy/display/core.py", line 1966, in interact_core
I/python  (  248):   File "/home/tom/ab/renpy-dev/renpy/display/core.py", line 1295, in draw_screen
I/python  (  248):   File "render.pyx", line 339, in renpy.display.render.render_screen (render.c:4063)
I/python  (  248):   File "render.pyx", line 155, in renpy.display.render.render (render.c:2060)
I/python  (  248):   File "/home/tom/ab/renpy-1000/renpy/display/layout.py", line 508, in render
I/python  (  248):   File "render.pyx", line 97, in renpy.display.render.render(render.c:2311)
I/python  (  248):   File "render.pyx", line 155, in renpy.display.render.render (render.c:2060)
I/python  (  248):   File "/home/tom/ab/renpy-dev/renpy/display/transition.py",line 86, in render
I/python  (  248):   File "/home/tom/ab/renpy-dev/renpy/display/transition.py",line 63, in null_render
I/python  (  248):   File "render.pyx", line 97, in renpy.display.render.render(render.c:2311)
I/python  (  248):   File "render.pyx", line 155, in renpy.display.render.render (render.c:2060)
I/python  (  248):   File "/home/tom/ab/renpy-1000/renpy/display/layout.py", line 508, in render
I/python  (  248):   File "render.pyx", line 97, in renpy.display.render.render(render.c:2311)
I/python  (  248):   File "render.pyx", line 155, in renpy.display.render.render (render.c:2060)
I/python  (  248):   File "/home/tom/ab/renpy-1000/renpy/display/layout.py", line 508, in render
I/python  (  248):   File "render.pyx", line 97, in renpy.display.render.render (render.c:2311)
I/python  (  248):   File "render.pyx", line 155, in renpy.display.render.render (render.c:2060)
I/python  (  248):   File "accelerator.pyx", line 70, in renpy.display.accelerator.transform_render (accelerator.c:1008)
I/python  (  248):   File "render.pyx", line 155, in renpy.display.render.render (render.c:2060)
I/python  (  248):   File "/home/tom/ab/renpy-1000/renpy/display/image.py", line 137, in render
I/python  (  248):   File "/home/tom/ab/renpy-1000/renpy/display/image.py", line 32, in wrap_render
I/python  (  248):   File "render.pyx", line 97, in renpy.display.render.render (render.c:2311)
I/python  (  248):   File "render.pyx", line 155, in renpy.display.render.render (render.c:2060)
I/python  (  248):   File "/home/tom/ab/renpy-1000/renpy/display/particle.py", line 366, in render
I/python  (  248):   File "render.pyx", line 97, in renpy.display.render.render (render.c:2311)
I/python  (  248):   File "render.pyx", line 155, in renpy.display.render.render (render.c:2060)
I/python  (  248):   File "/home/tom/ab/renpy-1000/renpy/display/particle.py", line 201, in render
I/python  (  248):   File "/home/tom/ab/renpy-1000/renpy/display/particle.py", line 347, in update_callback
I/python  (  248): TypeError: 'NoneType' object is not iterable
I/python  (  248): While running game code:
I/python  (  248):  - script call at line 750 of /home/tom/ab/renpy-dev/common/00library.rpy
I/python  (  248):  - script at line 833 of /mnt/sdcard/renpy/uvao2/game/script-ru.rpy
I/ActivityManager(   61): Process org.renpy.android:python (pid 248) has died.
I/WindowManager(   61): WIN DEATH: Window{43fd84e0 org.renpy.android/org.renpy.a
ndroid.PythonActivity paused=false}
I/WindowManager(   61): WIN DEATH: Window{44005400 SurfaceView paused=false}
I/UsageStats(   61): Unexpected resume of com.android.launcher while already res
umed in org.renpy.android
I/ActivityManager(   61): Low Memory: No more background processes.
W/InputManagerService(   61): Got RemoteException sending setActive(false) notif
ication to pid 248 uid 10032
D/dalvikvm(  118): GC_EXPLICIT freed 8042 objects / 398424 bytes in 668ms
D/dalvikvm(  115): GC_EXPLICIT freed 365 objects / 15128 bytes in 152ms
D/MediaScanner(  167):  prescan time: 341ms
D/MediaScanner(  167):     scan time: 334905ms
D/MediaScanner(  167): postscan time: 3ms
D/MediaScanner(  167):    total time: 335249ms
D/MediaScannerService(  167): done scanning volume external
D/dalvikvm(  167): GC_EXTERNAL_ALLOC freed 4815 objects / 273296 bytes in 167ms
D/skia    (  118): purging 17K from font cache [2 entries]
D/dalvikvm(  118): GC_EXPLICIT freed 1589 objects / 75328 bytes in 185ms
D/dalvikvm(  167): GC_EXTERNAL_ALLOC freed 1267 objects / 95176 bytes in 153ms
D/skia    (  167): --- decoder->decode returned false
W/MediaThumbRequest(  167): Can't create mini thumbnail for /mnt/sdcard/renpy/uv
ao2/game/stol_a.png
D/dalvikvm(  167): GC_EXTERNAL_ALLOC freed 456 objects / 33976 bytes in 136ms
D/skia    (  167): --- decoder->decode returned false
W/MediaThumbRequest(  167): Can't create mini thumbnail for /mnt/sdcard/renpy/uv
ao2/game/slava-3.png
D/dalvikvm(  167): GC_EXTERNAL_ALLOC freed 345 objects / 21320 bytes in 130ms
D/dalvikvm(  167): GC_EXTERNAL_ALLOC freed 352 objects / 34360 bytes in 140ms
D/skia    (   61): purging 7K from font cache [1 entries]

User avatar
PyTom
Ren'Py Creator
Posts: 15893
Joined: Mon Feb 02, 2004 10:58 am
Completed: Moonlight Walks
Projects: Ren'Py
IRC Nick: renpytom
Github: renpytom
itch: renpytom
Location: Kings Park, NY
Contact:

Re: Ren'Py for Android: Launcher Test

#13 Post by PyTom » Tue Jan 18, 2011 1:50 pm

Thanks, I'll look into this.
Supporting creators since 2004
(When was the last time you backed up your game?)
"Do good work." - Virgil Ivan "Gus" Grissom
"Silly and fun things are important." - Elon Musk
Software > Drama • https://www.patreon.com/renpytom

iichan_lolbot
Veteran
Posts: 206
Joined: Tue Dec 30, 2008 9:18 am
Projects: iichan erogame
Contact:

Re: Ren'Py for Android: Launcher Test

#14 Post by iichan_lolbot » Tue Jan 18, 2011 3:30 pm

Doesn't work on Android-x86 Virtual CD =(
Attachments
android.png
android 2.2
android.png
android 1.6
Last edited by iichan_lolbot on Tue Jan 18, 2011 4:29 pm, edited 1 time in total.

User avatar
PyTom
Ren'Py Creator
Posts: 15893
Joined: Mon Feb 02, 2004 10:58 am
Completed: Moonlight Walks
Projects: Ren'Py
IRC Nick: renpytom
Github: renpytom
itch: renpytom
Location: Kings Park, NY
Contact:

Re: Ren'Py for Android: Launcher Test

#15 Post by PyTom » Tue Jan 18, 2011 3:43 pm

Yes, it's arm-only for the time being.
Supporting creators since 2004
(When was the last time you backed up your game?)
"Do good work." - Virgil Ivan "Gus" Grissom
"Silly and fun things are important." - Elon Musk
Software > Drama • https://www.patreon.com/renpytom

Post Reply

Who is online

Users browsing this forum: No registered users