mirror of
https://github.com/infinitefusion/infinitefusion-e18.git
synced 2025-12-06 06:01:46 +00:00
Fix event command "Return to Title Screen" (#124)
Fix loading a game after event command "Return to Title Screen" starting a loop.
This commit is contained in:
@@ -75,6 +75,11 @@ module SaveData
|
||||
return @loaded
|
||||
end
|
||||
|
||||
# Marks value as unloaded.
|
||||
def mark_as_unloaded
|
||||
@loaded = false
|
||||
end
|
||||
|
||||
# Uses the {#from_old_format} proc to select the correct data from
|
||||
# +old_format+ and return it.
|
||||
# Returns nil if the proc is undefined.
|
||||
@@ -221,6 +226,13 @@ module SaveData
|
||||
load_values(save_data) { |value| !value.loaded? }
|
||||
end
|
||||
|
||||
# Marks all values that aren't loaded on bootup as unloaded.
|
||||
def self.mark_values_as_unloaded
|
||||
@values.each do |value|
|
||||
value.mark_as_unloaded unless value.load_in_bootup?
|
||||
end
|
||||
end
|
||||
|
||||
# Loads each value from the given save data that has
|
||||
# been set to be loaded during bootup. Done when a save file exists.
|
||||
# @param save_data [Hash] save data to load
|
||||
|
||||
@@ -164,6 +164,8 @@ class Scene_Map
|
||||
end
|
||||
updateSpritesets
|
||||
if $game_temp.to_title
|
||||
$game_temp.to_title = false
|
||||
SaveData.mark_values_as_unloaded
|
||||
$scene = pbCallTitle
|
||||
return
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user