removes bst slider in randomizer menu when in intro

This commit is contained in:
infinitefusion
2022-09-24 00:07:42 -04:00
parent 34d5c77312
commit ec64343fd0
4 changed files with 112 additions and 109 deletions

Binary file not shown.

View File

@@ -148,21 +148,22 @@ class RandomizerTrainerOptionsScene < PokemonOption_Scene
end
def pbGetOptions(inloadscreen = false)
options = [
SliderOption.new(_INTL("Randomness degree"), 25, 500, 5,
options = []
if !$game_switches[SWITCH_DURING_INTRO]
options << SliderOption.new(_INTL("Randomness degree"), 25, 500, 5,
proc { $game_variables[VAR_RANDOMIZER_TRAINER_BST] },
proc { |value|
$game_variables[VAR_RANDOMIZER_TRAINER_BST]=value
}),
EnumOption.new(_INTL("Custom Sprites only"), [_INTL("On"), _INTL("Off")],
$game_variables[VAR_RANDOMIZER_TRAINER_BST] = value
})
end
options << EnumOption.new(_INTL("Custom Sprites only"), [_INTL("On"), _INTL("Off")],
proc { $game_switches[RANDOM_TEAMS_CUSTOM_SPRITES] ? 0 : 1 },
proc { |value|
$game_switches[RANDOM_TEAMS_CUSTOM_SPRITES] = value == 0
},
"Use only Pokémon that have custom sprites in trainer teams"
)
]
return options
end
end
@@ -198,14 +199,16 @@ class RandomizerWildPokemonOptionsScene < PokemonOption_Scene
end
def pbGetOptions(inloadscreen = false)
options = [
SliderOption.new(_INTL("Randomness degree"), 25, 500, 5,
options = []
if !$game_switches[SWITCH_DURING_INTRO]
options << SliderOption.new(_INTL("Randomness degree"), 25, 500, 5,
proc { $game_variables[VAR_RANDOMIZER_WILD_POKE_BST] },
proc { |value|
$game_variables[VAR_RANDOMIZER_WILD_POKE_BST]=value
}),
$game_variables[VAR_RANDOMIZER_WILD_POKE_BST] = value
})
end
EnumOption.new(_INTL("Type"), [_INTL("Global"), _INTL("Area")],
options << EnumOption.new(_INTL("Type"), [_INTL("Global"), _INTL("Area")],
proc {
if $game_switches[RANDOM_WILD_AREA]
1
@@ -227,41 +230,41 @@ class RandomizerWildPokemonOptionsScene < PokemonOption_Scene
"Randomizes Pokémon using a one-to-one mapping of the Pokedex",
"Randomizes the encounters in each route individually"
]
),
EnumOption.new(_INTL("Starters"), [_INTL("On"), _INTL("Off")],
)
options << EnumOption.new(_INTL("Custom sprites only"), [_INTL("On"), _INTL("Off")],
proc { $game_switches[SWITCH_RANDOM_WILD_ONLY_CUSTOMS] ? 0 : 1 },
proc { |value|
$game_switches[SWITCH_RANDOM_WILD_ONLY_CUSTOMS] = value == 0
}, "(For 'Fuse everything' and starters) Randomize only to Pokémon that have a custom sprite."
)
options << EnumOption.new(_INTL("Starters"), [_INTL("On"), _INTL("Off")],
proc { $game_switches[SWITCH_RANDOM_STARTERS] ? 0 : 1 },
proc { |value|
$game_switches[SWITCH_RANDOM_STARTERS] = value == 0
}, "Randomize the selection of starters to choose from at the start of the game"
),
EnumOption.new(_INTL("Static encounters"), [_INTL("On"), _INTL("Off")],
)
options << EnumOption.new(_INTL("Static encounters"), [_INTL("On"), _INTL("Off")],
proc { $game_switches[RANDOM_STATIC] ? 0 : 1 },
proc { |value|
$game_switches[RANDOM_STATIC] = value == 0
},
"Randomize Pokémon that appear in the overworld (including legendaries)"
),
)
EnumOption.new(_INTL("Gift Pokémon"), [_INTL("On"), _INTL("Off")],
options << EnumOption.new(_INTL("Gift Pokémon"), [_INTL("On"), _INTL("Off")],
proc { $game_switches[GIFT_POKEMON] ? 0 : 1 },
proc { |value|
$game_switches[GIFT_POKEMON] = value == 0
}, "Randomize Pokémon that are gifted to the player"
),
)
EnumOption.new(_INTL("Fuse everything"), [_INTL("On"), _INTL("Off")],
options << EnumOption.new(_INTL("Fuse everything"), [_INTL("On"), _INTL("Off")],
proc { $game_switches[REGULAR_TO_FUSIONS] ? 0 : 1 },
proc { |value|
$game_switches[REGULAR_TO_FUSIONS] = value == 0
}, "Include fused Pokémon in the randomize pool for wild Pokémon"
),
EnumOption.new(_INTL("Custom sprites only"), [_INTL("On"), _INTL("Off")],
proc { $game_switches[SWITCH_RANDOM_WILD_ONLY_CUSTOMS] ? 0 : 1 },
proc { |value|
$game_switches[SWITCH_RANDOM_WILD_ONLY_CUSTOMS] = value == 0
}, "(With fuse everything option) Randomize only to Pokémon that have a custom sprite."
)
]
return options
end
end
@@ -294,42 +297,41 @@ class RandomizerGymOptionsScene < PokemonOption_Scene
end
def pbGetOptions(inloadscreen = false)
options = [
SliderOption.new(_INTL("Randomness degree"), 25, 500, 5,
options = []
if !$game_switches[SWITCH_DURING_INTRO]
options << SliderOption.new(_INTL("Randomness degree"), 25, 500, 5,
proc { $game_variables[VAR_RANDOMIZER_TRAINER_BST] },
proc { |value|
$game_variables[VAR_RANDOMIZER_TRAINER_BST]=value
}),
EnumOption.new(_INTL("Gym types"), [_INTL("On"), _INTL("Off")],
proc { $game_switches[RANDOM_GYM_TYPES] ? 0 : 1 },
proc { |value|
$game_switches[RANDOM_GYM_TYPES] = value == 0
}, "Shuffle the gym types"
),
EnumOption.new(_INTL("Rerandomize each battle"), [_INTL("On"), _INTL("Off")],
proc { $game_switches[SWITCH_GYM_RANDOM_EACH_BATTLE] ? 0 : 1 },
proc { |value|
$game_switches[SWITCH_GYM_RANDOM_EACH_BATTLE] = value == 0
$game_switches[SWITCH_RANDOM_GYM_PERSIST_TEAMS] = !$game_switches[SWITCH_GYM_RANDOM_EACH_BATTLE]
}, "Gym trainers and leaders have a new team each try instead of keeping the same one"
),
EnumOption.new(_INTL("Custom sprites only"), [_INTL("On"), _INTL("Off")],
$game_variables[VAR_RANDOMIZER_TRAINER_BST] = value
})
end
options << EnumOption.new(_INTL("Custom sprites only"), [_INTL("On"), _INTL("Off")],
proc { $game_switches[SWITCH_RANDOM_GYM_CUSTOMS] ? 0 : 1 },
proc { |value|
$game_switches[SWITCH_RANDOM_GYM_CUSTOMS] = value == 0
}, "Use only Pokémon that have custom sprites in gym trainers or gym leader teams"
)
]
options << EnumOption.new(_INTL("Gym types"), [_INTL("On"), _INTL("Off")],
proc { $game_switches[RANDOM_GYM_TYPES] ? 0 : 1 },
proc { |value|
$game_switches[RANDOM_GYM_TYPES] = value == 0
}, "Shuffle the gym types"
)
options << EnumOption.new(_INTL("Rerandomize each battle"), [_INTL("On"), _INTL("Off")],
proc { $game_switches[SWITCH_GYM_RANDOM_EACH_BATTLE] ? 0 : 1 },
proc { |value|
$game_switches[SWITCH_GYM_RANDOM_EACH_BATTLE] = value == 0
$game_switches[SWITCH_RANDOM_GYM_PERSIST_TEAMS] = !$game_switches[SWITCH_GYM_RANDOM_EACH_BATTLE]
}, "Gym trainers and leaders have a new team each try instead of keeping the same one"
)
return options
end
end
class RandomizerItemOptionsScene < PokemonOption_Scene
RANDOM_HELD_ITEMS = 843
def initialize
@changedColor = false
end
@@ -412,7 +414,7 @@ class RandomizerItemOptionsScene < PokemonOption_Scene
}, "Randomize the TMs given by NPCs"
),
EnumOption.new(_INTL("Shops items"), [_INTL("On"), _INTL("Off")],
EnumOption.new(_INTL("Shop items"), [_INTL("On"), _INTL("Off")],
proc { $game_switches[SWITCH_RANDOM_SHOP_ITEMS] ? 0 : 1 },
proc { |value|
$game_switches[SWITCH_RANDOM_SHOP_ITEMS] = value == 0

View File

@@ -23,6 +23,7 @@ SWITCH_GAME_DIFFICULTY_HARD = 666
SWITCH_MODERN_MODE=974
#Game progression switches
SWITCH_DURING_INTRO = 917
SWITCH_CHOOSING_STARTER=3
SWITCH_GOT_BADGE_1 = 4
SWITCH_GOT_BADGE_2 = 5

Binary file not shown.