mirror of
https://github.com/infinitefusion/infinitefusion-e18.git
synced 2026-01-21 21:56:01 +00:00
release 6.2
This commit is contained in:
@@ -19,6 +19,8 @@ class PokemonSystem
|
||||
attr_accessor :download_sprites
|
||||
attr_accessor :speedup
|
||||
attr_accessor :speedup_speed
|
||||
attr_accessor :max_nb_sprites_download
|
||||
attr_accessor :on_mobile
|
||||
|
||||
def initialize
|
||||
@textspeed = 1 # Text speed (0=slow, 1=normal, 2=fast)
|
||||
@@ -37,6 +39,8 @@ class PokemonSystem
|
||||
@speedup = 0 #0= hold, 1=toggle
|
||||
@speedup_speed = 3 #for hold only
|
||||
@download_sprites = 0
|
||||
@max_nb_sprites_download = 5
|
||||
|
||||
end
|
||||
end
|
||||
|
||||
@@ -349,6 +353,7 @@ class PokemonOption_Scene
|
||||
|
||||
def initialize
|
||||
@autosave_menu = false
|
||||
@manually_changed_difficulty=false
|
||||
end
|
||||
|
||||
def initUIElements
|
||||
@@ -411,192 +416,9 @@ class PokemonOption_Scene
|
||||
end
|
||||
end
|
||||
|
||||
#IMPLEMENT IN INHERITED CLASSES
|
||||
def pbGetOptions(inloadscreen = false)
|
||||
options = []
|
||||
options << SliderOption.new(_INTL("Music Volume"), 0, 100, 5,
|
||||
proc { $PokemonSystem.bgmvolume },
|
||||
proc { |value|
|
||||
if $PokemonSystem.bgmvolume != value
|
||||
$PokemonSystem.bgmvolume = value
|
||||
if $game_system.playing_bgm != nil && !inloadscreen
|
||||
playingBGM = $game_system.getPlayingBGM
|
||||
$game_system.bgm_pause
|
||||
$game_system.bgm_resume(playingBGM)
|
||||
end
|
||||
end
|
||||
}, "Sets the volume for background music"
|
||||
)
|
||||
|
||||
options << SliderOption.new(_INTL("SE Volume"), 0, 100, 5,
|
||||
proc { $PokemonSystem.sevolume },
|
||||
proc { |value|
|
||||
if $PokemonSystem.sevolume != value
|
||||
$PokemonSystem.sevolume = value
|
||||
if $game_system.playing_bgs != nil
|
||||
$game_system.playing_bgs.volume = value
|
||||
playingBGS = $game_system.getPlayingBGS
|
||||
$game_system.bgs_pause
|
||||
$game_system.bgs_resume(playingBGS)
|
||||
end
|
||||
pbPlayCursorSE
|
||||
end
|
||||
}, "Sets the volume for sound effects"
|
||||
)
|
||||
|
||||
options << EnumOption.new(_INTL("Default Movement"), [_INTL("Walking"), _INTL("Running")],
|
||||
proc { $PokemonSystem.runstyle },
|
||||
proc { |value| $PokemonSystem.runstyle = value },
|
||||
["Default to walking when not holding the Run key",
|
||||
"Default to running when not holding the Run key"]
|
||||
)
|
||||
|
||||
options << EnumOption.new(_INTL("Text Speed"), [_INTL("Normal"), _INTL("Fast")],
|
||||
proc { $PokemonSystem.textspeed },
|
||||
proc { |value|
|
||||
$PokemonSystem.textspeed = value
|
||||
MessageConfig.pbSetTextSpeed(MessageConfig.pbSettingToTextSpeed(value))
|
||||
}, "Sets the speed at which the text is displayed"
|
||||
)
|
||||
|
||||
if $game_switches
|
||||
options <<
|
||||
EnumOption.new(_INTL("Autosave"), [_INTL("On"), _INTL("Off")],
|
||||
proc { $game_switches[AUTOSAVE_ENABLED_SWITCH] ? 0 : 1 },
|
||||
proc { |value|
|
||||
if !$game_switches[AUTOSAVE_ENABLED_SWITCH] && value == 0
|
||||
@autosave_menu = true
|
||||
openAutosaveMenu()
|
||||
end
|
||||
$game_switches[AUTOSAVE_ENABLED_SWITCH] = value == 0
|
||||
},
|
||||
"Automatically saves when healing at Pokémon centers"
|
||||
)
|
||||
end
|
||||
|
||||
|
||||
options << EnumOption.new(_INTL("Speed-up type"), [_INTL("Hold"), _INTL("Toggle")],
|
||||
proc { $PokemonSystem.speedup },
|
||||
proc { |value|
|
||||
$PokemonSystem.speedup = value
|
||||
}, "Pick how you want speed-up to be enabled"
|
||||
)
|
||||
|
||||
options << SliderOption.new(_INTL("Speed-up speed"), 1, 10, 1,
|
||||
proc { $PokemonSystem.speedup_speed },
|
||||
proc { |value|
|
||||
$PokemonSystem.speedup_speed = value
|
||||
}, "Sets by how much to speed up the game when holding the speed up button (Default: 3x)"
|
||||
)
|
||||
# if $game_switches && ($game_switches[SWITCH_NEW_GAME_PLUS] || $game_switches[SWITCH_BEAT_THE_LEAGUE]) #beat the league
|
||||
# options << EnumOption.new(_INTL("Text Speed"), [_INTL("Normal"), _INTL("Fast"), _INTL("Instant")],
|
||||
# proc { $PokemonSystem.textspeed },
|
||||
# proc { |value|
|
||||
# $PokemonSystem.textspeed = value
|
||||
# MessageConfig.pbSetTextSpeed(MessageConfig.pbSettingToTextSpeed(value))
|
||||
# }, "Sets the speed at which the text is displayed"
|
||||
# )
|
||||
# else
|
||||
# options << EnumOption.new(_INTL("Text Speed"), [_INTL("Normal"), _INTL("Fast")],
|
||||
# proc { $PokemonSystem.textspeed },
|
||||
# proc { |value|
|
||||
# $PokemonSystem.textspeed = value
|
||||
# MessageConfig.pbSetTextSpeed(MessageConfig.pbSettingToTextSpeed(value))
|
||||
# }, "Sets the speed at which the text is displayed"
|
||||
# )
|
||||
# end
|
||||
options <<
|
||||
EnumOption.new(_INTL("Download sprites"), [_INTL("On"), _INTL("Off")],
|
||||
proc { $PokemonSystem.download_sprites },
|
||||
proc { |value|
|
||||
$PokemonSystem.download_sprites = value
|
||||
},
|
||||
"Automatically download custom sprites from the internet"
|
||||
)
|
||||
|
||||
|
||||
|
||||
if $game_switches && ($game_switches[SWITCH_NEW_GAME_PLUS] || $game_switches[SWITCH_BEAT_THE_LEAGUE]) #beat the league
|
||||
options <<
|
||||
EnumOption.new(_INTL("Battle type"), [_INTL("1v1"), _INTL("2v2"), _INTL("3v3")],
|
||||
proc { $PokemonSystem.battle_type },
|
||||
proc { |value|
|
||||
if value == 0
|
||||
$game_variables[VAR_DEFAULT_BATTLE_TYPE] = [1, 1]
|
||||
elsif value == 1
|
||||
$game_variables[VAR_DEFAULT_BATTLE_TYPE] = [2, 2]
|
||||
elsif value == 2
|
||||
$game_variables[VAR_DEFAULT_BATTLE_TYPE] = [3, 3]
|
||||
else
|
||||
$game_variables[VAR_DEFAULT_BATTLE_TYPE] = [1, 1]
|
||||
end
|
||||
$PokemonSystem.battle_type = value
|
||||
}, "Sets the number of Pokémon sent out in battles (when possible)"
|
||||
)
|
||||
end
|
||||
|
||||
options << EnumOption.new(_INTL("Battle Effects"), [_INTL("On"), _INTL("Off")],
|
||||
proc { $PokemonSystem.battlescene },
|
||||
proc { |value| $PokemonSystem.battlescene = value },
|
||||
"Display move animations in battles"
|
||||
)
|
||||
|
||||
options << EnumOption.new(_INTL("Battle Style"), [_INTL("Switch"), _INTL("Set")],
|
||||
proc { $PokemonSystem.battlestyle },
|
||||
proc { |value| $PokemonSystem.battlestyle = value },
|
||||
["Prompts to switch Pokémon before the opponent sends out the next one",
|
||||
"No prompt to switch Pokémon before the opponent sends the next one"]
|
||||
)
|
||||
|
||||
|
||||
options << NumberOption.new(_INTL("Speech Frame"), 1, Settings::SPEECH_WINDOWSKINS.length,
|
||||
proc { $PokemonSystem.textskin },
|
||||
proc { |value|
|
||||
$PokemonSystem.textskin = value
|
||||
MessageConfig.pbSetSpeechFrame("Graphics/Windowskins/" + Settings::SPEECH_WINDOWSKINS[value])
|
||||
}
|
||||
)
|
||||
# NumberOption.new(_INTL("Menu Frame"),1,Settings::MENU_WINDOWSKINS.length,
|
||||
# proc { $PokemonSystem.frame },
|
||||
# proc { |value|
|
||||
# $PokemonSystem.frame = value
|
||||
# MessageConfig.pbSetSystemFrame("Graphics/Windowskins/" + Settings::MENU_WINDOWSKINS[value])
|
||||
# }
|
||||
# ),
|
||||
options << EnumOption.new(_INTL("Text Entry"), [_INTL("Cursor"), _INTL("Keyboard")],
|
||||
proc { $PokemonSystem.textinput },
|
||||
proc { |value| $PokemonSystem.textinput = value },
|
||||
["Enter text by selecting letters on the screen",
|
||||
"Enter text by typing on the keyboard"]
|
||||
)
|
||||
if $game_variables
|
||||
options << EnumOption.new(_INTL("Fusion icons"), [_INTL("Combined"), _INTL("DNA")],
|
||||
proc { $game_variables[VAR_FUSION_ICON_STYLE] },
|
||||
proc { |value| $game_variables[VAR_FUSION_ICON_STYLE] = value },
|
||||
["Combines both Pokémon's party icons",
|
||||
"Uses the same party icon for all fusions"]
|
||||
)
|
||||
end
|
||||
options << EnumOption.new(_INTL("Screen Size"), [_INTL("S"), _INTL("M"), _INTL("L"), _INTL("XL"), _INTL("Full")],
|
||||
proc { [$PokemonSystem.screensize, 4].min },
|
||||
proc { |value|
|
||||
if $PokemonSystem.screensize != value
|
||||
$PokemonSystem.screensize = value
|
||||
pbSetResizeFactor($PokemonSystem.screensize)
|
||||
end
|
||||
}, "Sets the size of the screen"
|
||||
)
|
||||
options << EnumOption.new(_INTL("Quick Surf"), [_INTL("Off"), _INTL("On")],
|
||||
proc { $PokemonSystem.quicksurf },
|
||||
proc { |value| $PokemonSystem.quicksurf = value },
|
||||
"Start surfing automatically when interacting with water"
|
||||
)
|
||||
|
||||
options << EnumOption.new(_INTL("Level caps"), [_INTL("Off"), _INTL("On")],
|
||||
proc { $PokemonSystem.level_caps },
|
||||
proc { |value| $PokemonSystem.level_caps = value },
|
||||
"Prevents leveling above the next gym leader's highest leveled Pokemon"
|
||||
)
|
||||
|
||||
return options
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user