forked from Cavemanon/SnootGame
Compare commits
5 Commits
908d8f62f7
...
a787d1ceaf
Author | SHA1 | Date | |
---|---|---|---|
a787d1ceaf | |||
719f08ba24 | |||
a31fa50d8a | |||
803e878c3f | |||
f38c53776c |
@ -24,7 +24,7 @@ define tuples_index = [
|
|||||||
init python:
|
init python:
|
||||||
|
|
||||||
def select_chapter():
|
def select_chapter():
|
||||||
global current_chapter, is_end_reached, quick_menu
|
global current_chapter, quick_menu
|
||||||
|
|
||||||
selected_tuple = ()
|
selected_tuple = ()
|
||||||
|
|
||||||
@ -41,7 +41,7 @@ init python:
|
|||||||
|
|
||||||
set_stats()
|
set_stats()
|
||||||
toggle_debug()
|
toggle_debug()
|
||||||
quick_menu = True
|
quick_menu = True # Restores the bottom quick menu UI
|
||||||
|
|
||||||
renpy.call(current_chapter)
|
renpy.call(current_chapter)
|
||||||
|
|
||||||
@ -51,16 +51,16 @@ init python:
|
|||||||
|
|
||||||
|
|
||||||
def set_stats():
|
def set_stats():
|
||||||
global chapter_list_length, ending_route_number, is_end_reached
|
global ending_route_number, is_end_reached
|
||||||
|
|
||||||
ending_route_number = get_ending()
|
ending_route_number = get_ending()
|
||||||
|
|
||||||
find_chapter_in_array()
|
find_chapter_in_array()
|
||||||
|
|
||||||
if not is_end_reached:
|
if not is_end_reached:
|
||||||
add_ending_chapters() # From storyline
|
add_ending_chapters(ending_route_number)
|
||||||
|
|
||||||
update_ending_variables() # From storyline
|
update_ending_variables() # Updates variables for newly extended 'chapter_list' with ending chapters
|
||||||
|
|
||||||
|
|
||||||
def set_scores(anon_score, fang_score):
|
def set_scores(anon_score, fang_score):
|
||||||
@ -89,7 +89,10 @@ label reset_chapter_list:
|
|||||||
|
|
||||||
|
|
||||||
label chapter_select:
|
label chapter_select:
|
||||||
$ quick_menu = False
|
$ quick_menu = False # Hides bottom quick menu UI
|
||||||
|
|
||||||
|
$ anon_points = 0
|
||||||
|
$ fang_points = 0
|
||||||
|
|
||||||
stop sound
|
stop sound
|
||||||
stop music fadeout 2
|
stop music fadeout 2
|
||||||
@ -99,17 +102,21 @@ label chapter_select:
|
|||||||
"Initialize scores:"
|
"Initialize scores:"
|
||||||
|
|
||||||
"Ending 1":
|
"Ending 1":
|
||||||
$ set_scores(0, 0)
|
pass # Since points are already initialized at 0
|
||||||
"Ending 2":
|
"Ending 2":
|
||||||
$ set_scores(0, 4)
|
# anon 0
|
||||||
|
$ fang_points = 4
|
||||||
"Ending 3":
|
"Ending 3":
|
||||||
$ set_scores(4, 0)
|
$ anon_points = 4
|
||||||
|
# fang 0
|
||||||
"Ending 4":
|
"Ending 4":
|
||||||
$ set_scores(4, 4)
|
$ anon_points = 4
|
||||||
|
$ fang_points = 4
|
||||||
"Exit to main menu":
|
"Exit to main menu":
|
||||||
scene black with dissolve
|
scene black with dissolve
|
||||||
return
|
return
|
||||||
|
|
||||||
|
$ set_scores(anon_points, fang_points)
|
||||||
$ is_end_reached = False # Reset this for when the tool is used more than once
|
$ is_end_reached = False # Reset this for when the tool is used more than once
|
||||||
|
|
||||||
window hide
|
window hide
|
||||||
@ -119,5 +126,4 @@ label chapter_select:
|
|||||||
|
|
||||||
$ select_chapter()
|
$ select_chapter()
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -13,10 +13,10 @@ init -1 python:
|
|||||||
|
|
||||||
init python:
|
init python:
|
||||||
def next_story_chapter():
|
def next_story_chapter():
|
||||||
global chapter_list_index, current_chapter, ending_route_number
|
global chapter_list_index, current_chapter
|
||||||
|
|
||||||
# Add check "is_end_reached" to have this if statement be executed only once when finishing the general chapters
|
# Add check "is_end_reached" to have this if statement be executed only once when finishing the general chapters
|
||||||
if not is_end_reached and is_end_of_chapters():
|
if not is_end_reached and chapter_list_index >= chapter_list_length:
|
||||||
process_ending()
|
process_ending()
|
||||||
|
|
||||||
if chapter_list_index < chapter_list_length:
|
if chapter_list_index < chapter_list_length:
|
||||||
@ -25,25 +25,21 @@ init python:
|
|||||||
renpy.call(current_chapter)
|
renpy.call(current_chapter)
|
||||||
else:
|
else:
|
||||||
end_story()
|
end_story()
|
||||||
|
|
||||||
|
|
||||||
def is_end_of_chapters():
|
|
||||||
return chapter_list_index >= chapter_list_length
|
|
||||||
|
|
||||||
|
|
||||||
def process_ending():
|
def process_ending():
|
||||||
global ending_route_number
|
global ending_route_number
|
||||||
|
|
||||||
ending_route_number = get_ending()
|
ending_route_number = get_ending()
|
||||||
add_ending_chapters()
|
add_ending_chapters(ending_route_number)
|
||||||
update_ending_variables()
|
update_ending_variables() # Updates variables for newly extended 'chapter_list' with ending chapters
|
||||||
|
|
||||||
|
|
||||||
def add_ending_chapters():
|
def add_ending_chapters(route_number):
|
||||||
global chapter_list
|
global chapter_list
|
||||||
|
|
||||||
if ending_route_number in ending_routes:
|
if route_number in ending_routes:
|
||||||
chapter_list.extend(ending_routes[ending_route_number])
|
chapter_list.extend(ending_routes[route_number])
|
||||||
|
|
||||||
|
|
||||||
def update_ending_variables():
|
def update_ending_variables():
|
||||||
@ -59,7 +55,6 @@ init python:
|
|||||||
return len(chapter_list) - 1
|
return len(chapter_list) - 1
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
def end_story():
|
def end_story():
|
||||||
ending_image()
|
ending_image()
|
||||||
renpy.call("lending")
|
renpy.call("lending")
|
||||||
|
@ -1,8 +1,3 @@
|
|||||||
[tasks.patch]
|
|
||||||
type = "custom"
|
|
||||||
enabled = true
|
|
||||||
ver = "8.3.0"
|
|
||||||
|
|
||||||
[tasks.keystore] # required if matching task is enabled
|
[tasks.keystore] # required if matching task is enabled
|
||||||
type="keystore"
|
type="keystore"
|
||||||
enabled = true
|
enabled = true
|
||||||
|
Reference in New Issue
Block a user