mirror of
https://github.com/infinitefusion/infinitefusion-e18.git
synced 2025-12-10 14:44:58 +00:00
Migration - more progress
This commit is contained in:
@@ -753,7 +753,7 @@ def pbEditPlayerMetadata(player_id = 1)
|
||||
val = property[1].defaultValue if val.nil? && property[1].respond_to?(:defaultValue)
|
||||
data.push(val)
|
||||
end
|
||||
if pbPropertyList(_INTL("Player {1}", metadata.id), data, properties, true)
|
||||
if pbPropertyList(_INTL("Overrides {1}", metadata.id), data, properties, true)
|
||||
# Construct player metadata hash
|
||||
schema = GameData::PlayerMetadata.schema
|
||||
metadata_hash = {}
|
||||
|
||||
@@ -21,7 +21,7 @@ def pbAutoPositionAll
|
||||
metrics = GameData::SpeciesMetrics.get_species_form(sp.species, sp.form)
|
||||
bitmap1 = GameData::Species.sprite_bitmap(sp.species, sp.form, nil, nil, nil, true)
|
||||
bitmap2 = GameData::Species.sprite_bitmap(sp.species, sp.form)
|
||||
if bitmap1&.bitmap # Player's y
|
||||
if bitmap1&.bitmap # Overrides's y
|
||||
metrics.back_sprite[0] = 0
|
||||
metrics.back_sprite[1] = (bitmap1.height - (findBottom(bitmap1.bitmap) + 1)) / 2
|
||||
end
|
||||
|
||||
@@ -842,11 +842,11 @@ MenuHandlers.add(:debug_menu, :empty_bag, {
|
||||
})
|
||||
|
||||
#===============================================================================
|
||||
# Player options.
|
||||
# Overrides options.
|
||||
#===============================================================================
|
||||
|
||||
MenuHandlers.add(:debug_menu, :player_menu, {
|
||||
"name" => _INTL("Player options..."),
|
||||
"name" => _INTL("Overrides options..."),
|
||||
"parent" => :main,
|
||||
"description" => _INTL("Set money, badges, Pokédexes, player's appearance and name, etc."),
|
||||
"always_show" => false
|
||||
@@ -1114,7 +1114,7 @@ MenuHandlers.add(:debug_menu, :change_outfit, {
|
||||
params.setRange(0, 99)
|
||||
params.setDefaultValue(oldoutfit)
|
||||
$player.outfit = pbMessageChooseNumber(_INTL("Set the player's outfit."), params)
|
||||
pbMessage(_INTL("Player's outfit was changed.")) if $player.outfit != oldoutfit
|
||||
pbMessage(_INTL("Overrides's outfit was changed.")) if $player.outfit != oldoutfit
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
@@ -9,7 +9,7 @@ MenuHandlers.add(:battle_debug_menu, :battlers, {
|
||||
})
|
||||
|
||||
MenuHandlers.add(:battle_debug_menu, :list_player_battlers, {
|
||||
"name" => _INTL("Player-side battlers"),
|
||||
"name" => _INTL("Overrides-side battlers"),
|
||||
"parent" => :battlers,
|
||||
"description" => _INTL("Edit Pokémon on the player's side of battle."),
|
||||
"effect" => proc { |battle|
|
||||
@@ -103,7 +103,7 @@ MenuHandlers.add(:battle_debug_menu, :pokemon_teams, {
|
||||
first_index = player_party_starts[i]
|
||||
last_index = (i < player_party_starts.length - 1) ? player_party_starts[i + 1] : battle.pbParty(0).length
|
||||
num_pkmn = last_index - first_index
|
||||
if i == 0 # Player
|
||||
if i == 0 # Overrides
|
||||
commands.push(_INTL("You: {1} ({2} Pokémon)", trainer.full_name, num_pkmn))
|
||||
else
|
||||
commands.push(_INTL("Ally {1}: {2} ({3} Pokémon)", i, trainer.full_name, num_pkmn))
|
||||
@@ -162,7 +162,7 @@ MenuHandlers.add(:battle_debug_menu, :trainer_items, {
|
||||
end
|
||||
if battle.player.length > 1
|
||||
battle.player.each_with_index do |trainer, i|
|
||||
next if i == 0 # Player
|
||||
next if i == 0 # Overrides
|
||||
items = battle.ally_items ? battle.ally_items[i].clone : []
|
||||
commands.push(_INTL("Ally {1}: {2} ({3} items)", i, trainer.full_name, items.length))
|
||||
item_arrays.push(items)
|
||||
@@ -436,7 +436,7 @@ MenuHandlers.add(:battle_debug_menu, :set_field_effects, {
|
||||
})
|
||||
|
||||
MenuHandlers.add(:battle_debug_menu, :player_side, {
|
||||
"name" => _INTL("Player's side effects..."),
|
||||
"name" => _INTL("Overrides's side effects..."),
|
||||
"parent" => :field,
|
||||
"description" => _INTL("Effects that apply to the side the player is on."),
|
||||
"effect" => proc { |battle|
|
||||
|
||||
@@ -920,7 +920,7 @@ MenuHandlers.add(:pokemon_debug_menu, :ownership, {
|
||||
gender_text = _INTL("Male") if pkmn.owner.male?
|
||||
gender_text = _INTL("Female") if pkmn.owner.female?
|
||||
public_id_text = sprintf("%05d", pkmn.owner.public_id)
|
||||
msg = [_INTL("Player's Pokémon\n{1}\n{2}\n{3} ({4})",
|
||||
msg = [_INTL("Overrides's Pokémon\n{1}\n{2}\n{3} ({4})",
|
||||
pkmn.owner.name, gender_text, public_id_text, pkmn.owner.id),
|
||||
_INTL("Foreign Pokémon\n{1}\n{2}\n{3} ({4})",
|
||||
pkmn.owner.name, gender_text, public_id_text, pkmn.owner.id)][pkmn.foreign?($player) ? 1 : 0]
|
||||
|
||||
@@ -269,7 +269,7 @@ class MetadataLister
|
||||
def commands
|
||||
@commands.clear
|
||||
@commands.push(_INTL("[GLOBAL METADATA]"))
|
||||
@player_ids.each { |id| @commands.push(_INTL("Player {1}", id)) }
|
||||
@player_ids.each { |id| @commands.push(_INTL("Overrides {1}", id)) }
|
||||
@commands.push(_INTL("[ADD NEW PLAYER]")) if @new_player
|
||||
return @commands
|
||||
end
|
||||
@@ -277,7 +277,7 @@ class MetadataLister
|
||||
# Cancel: -1
|
||||
# New player: -2
|
||||
# Global metadata: 0
|
||||
# Player character: 1+ (the player ID itself)
|
||||
# Overrides character: 1+ (the player ID itself)
|
||||
def value(index)
|
||||
return index if index < 1
|
||||
return -2 if @new_player && index == @commands.length - 1
|
||||
|
||||
Reference in New Issue
Block a user