Create libs/ and lib/libs.txt.
The latter is the flags file that will load the libs directory in libs mode.
This commit is contained in:
@@ -0,0 +1 @@
|
|||||||
|
## When this file exists, Ren'Py will load files in game/libs before other files in game.
|
||||||
@@ -26,6 +26,15 @@ define gui.asian = False
|
|||||||
# and provides the full path to the template project.
|
# and provides the full path to the template project.
|
||||||
default gui_template_path = None
|
default gui_template_path = None
|
||||||
|
|
||||||
|
define LIBS_TXT = _("""\
|
||||||
|
The game/libs/ directory is meant for third-party libraries that ask to be put in
|
||||||
|
game/libs.
|
||||||
|
|
||||||
|
When this file (game/libs/libs.txt) is present, Ren'Py will load all files in libs
|
||||||
|
before any other file in game/, and will not consider directory names when loading
|
||||||
|
these files.
|
||||||
|
""")
|
||||||
|
|
||||||
init -1 python:
|
init -1 python:
|
||||||
|
|
||||||
import gui7
|
import gui7
|
||||||
|
|||||||
@@ -28,15 +28,19 @@ import os
|
|||||||
import shutil
|
import shutil
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
def finish(p):
|
def finish(p):
|
||||||
|
|
||||||
for dn in [ "images", "audio" ]:
|
for dn in [ "images", "audio", "libs" ]:
|
||||||
|
|
||||||
fulldn = os.path.join(p.prefix, dn)
|
fulldn = os.path.join(p.prefix, dn)
|
||||||
|
|
||||||
if not os.path.exists(fulldn):
|
if not os.path.exists(fulldn):
|
||||||
os.mkdir(fulldn)
|
os.mkdir(fulldn)
|
||||||
|
|
||||||
|
with open(os.path.join(p.prefix, "libs", "libs.txt"), "w") as f:
|
||||||
|
f.write(renpy.translation.translate_string(renpy.store.LIBS_TXT, language=p.language))
|
||||||
|
|
||||||
def generate_gui(p):
|
def generate_gui(p):
|
||||||
|
|
||||||
ImageGenerator(p).generate_all()
|
ImageGenerator(p).generate_all()
|
||||||
|
|||||||
Reference in New Issue
Block a user