Page 1 of 1

Reduce Renpy game loading time on android

Posted: Wed Feb 17, 2021 8:29 pm
by Rnot2000
So i make renpy game on android, but it seem have some long loading like took 45 sec - 1 minute, :( :( :(
Is there any trick to reduce loading screen on android when opening the game ???

> its have like 5.000 picture (i compress from PNG to WEBP to reduce size of the pic)
> my game APK size is 311 mb
> i have this is one .rpy file that have 50.000 line... (is it make the loading took so long ???)

i'm using POCO F1 6GB ram - Snapdragon 845

Re: Reduce Renpy game loading time on android

Posted: Thu Feb 18, 2021 3:16 pm
by uyjulian
I would suggest splitting up the .rpy file.

That will allow smaller "compilation units" so it will reduce the loading time.

Also, I would suggest reducing duplicated code using features such as Creator-Defined Statements.

Other than that, not too sure.

One of the possible reasons for long loading time: Ren'Py is bottlenecked on .rpy loading due to the "pickle" library allocating lots of small objects, which will increase the loading time. I'd like to submit changes to Ren'Py to defer more loading at runtime (making it so, at most at initialization time, the .rpyc file is read to buffer) to decrease the initial loading time