Android Port #64

Merged
MichaelYick merged 9 commits from nutbuster/SnootGame:Monster-Update-6 into Monster-Update-6 2021-07-29 04:39:03 +00:00
7 changed files with 61 additions and 28 deletions

3
.gitignore vendored
View File

@ -31,3 +31,6 @@ ehthumbs_vista.db
#backups
*.bak
#android
.android.json

BIN
android-icon_foreground.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 81 KiB

BIN
android-presplash.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 262 KiB

View File

@ -445,7 +445,7 @@ init python:
## Font sizes.
gui.text_size = 44
gui.name_text_size = 48
gui.name_text_size = 46
gui.notify_text_size = 38
gui.interface_text_size = 45
gui.button_text_size = 45

View File

@ -23,7 +23,7 @@ define gui.show_name = True
## The version of the game.
define config.version = "Patchy-patch5.1.1"
define config.version = "Monster-Update-6"
## Text that is placed on the game's about screen. Place the text between the
## triple-quotes, and leave a blank line between paragraphs.

View File

@ -1,23 +1,24 @@
###Updater Python stuff###
init python:
if persistent.updateresult is None:
persistent.updateresult = "No new version is available"
if persistent.autoup is None:
persistent.autoup = False
if persistent.updateWebServer is None:
persistent.updateWebServer = "http://updates.snootgame.xyz/updates.json"
if renpy.variant("pc"): #Don't run this on mobile, not supported
if persistent.updateresult is None:
persistent.updateresult = "No new version is available"
if persistent.autoup is None:
persistent.autoup = False
if persistent.updateWebServer is None:
persistent.updateWebServer = "http://updates.snootgame.xyz/updates.json"
def UpdateCheck():
# WHY YES I ONLY ALLOW PEOPLE USING MY FRAMEWORK TO CHECK FOR AN UPDATE EVERY SIX FUCKING HOURS HOW DID YOU KNOW
# NOPE check_interval=5 (5 SECONDS) FUCK YOU
pendingVersion = updater.UpdateVersion(persistent.updateWebServer, check_interval=5)
if pendingVersion == None or pendingVersion == config.version or "TEST" in pendingVersion:
persistent.updateresult = "No new version is available"
else:
persistent.updateresult = pendingVersion
def UpdateCheck():
# WHY YES I ONLY ALLOW PEOPLE USING MY FRAMEWORK TO CHECK FOR AN UPDATE EVERY SIX FUCKING HOURS HOW DID YOU KNOW
# NOPE check_interval=5 (5 SECONDS) FUCK YOU
pendingVersion = updater.UpdateVersion(persistent.updateWebServer, check_interval=5)
if pendingVersion == None or pendingVersion == config.version or "TEST" in pendingVersion:
persistent.updateresult = "No new version is available"
else:
persistent.updateresult = pendingVersion
def ToggleAutoUpdate():
persistent.autoup = not persistent.autoup
def ToggleAutoUpdate():
persistent.autoup = not persistent.autoup
################################################################################
## Initialization
@ -132,7 +133,6 @@ screen say(who, what):
text what id "what"
## If there's a side image, display it above the text. Do not display on the
## phone variant - there's no room.
if not renpy.variant("small"):
@ -434,7 +434,7 @@ screen main_menu():
vbox:
spacing 10
xpos 1885
yalign 0.98
ypos 1130
use main_menu_buttons("gui/button/menubuttons/template_idle.png",
[
[ "Start", Start() ],
@ -1618,8 +1618,8 @@ style pref_vbox:
screen quick_button(filename, label, function):
variant "small"
button:
xmaximum 180
ymaximum 100
xmaximum 124
ymaximum 124
action function
fixed:
add filename xalign 0.5 yalign 0.5 zoom 1.75
@ -1630,6 +1630,7 @@ screen quick_menu():
zorder 100
if quick_menu:
hbox:
spacing 28
style_prefix "quick"
xalign 0.5
yalign 0.975
@ -1641,6 +1642,28 @@ screen quick_menu():
[ "Menu", ShowMenu() ] \
] )
screen extrasnavigation(): #Updates are removed (not even supported by Ren'Py)
variant "small"
vbox:
xpos 1940
yalign 0.03
if persistent.splashtype == 1:
add "gui/sneedgame.png"
else:
add "gui/snootgame.png"
vbox:
spacing 25
xpos 1885
yalign 0.9
use main_menu_buttons("gui/button/menubuttons/template_idle.png",
[
[ "Help", ShowMenu("help") ],
[ "About", ShowMenu("about") ],
[ "Gallery", ShowMenu("cg_gallery_0") ],
[ "Return", ShowMenu("main_menu") ]
] )
style radio_button:
variant "small"
foreground "gui/phone/button/radio_[prefix_]foreground.png"

View File

@ -273,13 +273,20 @@ screen view_image(item, _origin, zoom = zoom_arr.index(1.0), flag='a'):
#Reuse quick buttons, Ren'Py handles touch input lazy, it doesn't have
#double finger pinch zoom, it translates taps as mouse events - have to use
#buttons
if (ALLOW_ZOOM) and renpy.variant("small"):
hbox:
style_prefix "quick"
xalign 0.5
yalign 0.975
hbox:
style_prefix "quick"
xalign 0.5
yalign 0.975
if (ALLOW_ZOOM) and renpy.variant("small"):
use quick_buttons("gui/button/uioptionbuttons/template_idle.png",
[
[ "+", zoom_a_f ],
[ "-", zoom_b_f ]
[ "-", zoom_b_f ],
[ "Return", zoom_b_f ]
] )
else:
use quick_buttons("gui/button/uioptionbuttons/template_idle.png",
[
[ "Return", _origin ]
] )