feat(m79-b): contract advancement opens region two with its band, boss, battlefield and music
This commit is contained in:
@@ -92,6 +92,10 @@ const GUILD_DESK_BOTTOM_PARTY = preload("res://assets/entry/guild_desk_v001/bott
|
||||
const BATTLE_OPENING_BACKGROUND = preload("res://assets/backgrounds/first_expedition_field.png")
|
||||
const BATTLE_OPENING_ENEMY = preload("res://assets/enemies/riftblade/idle.png")
|
||||
const BATTLE_FIELD = preload("res://assets/battle/windglass_verge_battlefield.png")
|
||||
const BATTLE_FIELDS := {
|
||||
1: preload("res://assets/battle/windglass_verge_battlefield.png"),
|
||||
2: preload("res://assets/battle/siltwake_fens_battlefield.png"),
|
||||
}
|
||||
const BATTLE_ENEMY_ART := {
|
||||
"EN-R1-01": preload("res://assets/battle/enemies/enemy-en-r1-01-pane-nibbler.png"),
|
||||
"EN-R1-02": preload("res://assets/battle/enemies/enemy-en-r1-02-gust-finch.png"),
|
||||
@@ -3257,7 +3261,7 @@ func _build_battle_opening_canvas() -> void:
|
||||
child.free()
|
||||
var background := TextureRect.new()
|
||||
background.name = "BattleOpeningWorld"
|
||||
background.texture = BATTLE_FIELD
|
||||
background.texture = _battle_field_texture()
|
||||
background.expand_mode = TextureRect.EXPAND_IGNORE_SIZE
|
||||
background.stretch_mode = TextureRect.STRETCH_KEEP_ASPECT_COVERED
|
||||
background.texture_filter = CanvasItem.TEXTURE_FILTER_LINEAR_WITH_MIPMAPS
|
||||
@@ -3666,6 +3670,12 @@ func _battle_profession_parent(profession_id: String) -> String:
|
||||
return found.get_string() if found != null else ""
|
||||
|
||||
|
||||
func _battle_field_texture() -> Texture2D:
|
||||
var contract: Dictionary = Dictionary(guild_company.get("active_contract", {}))
|
||||
var region_index := int(contract.get("region_index", 1))
|
||||
return BATTLE_FIELDS.get(region_index, BATTLE_FIELD)
|
||||
|
||||
|
||||
func _battle_music_family(company: Dictionary) -> String:
|
||||
# Region 1 keeps the original family names; later regions suffix the id so
|
||||
# each region's battle and boss beds stay addressable.
|
||||
@@ -5043,7 +5053,7 @@ func _show_legacy_battle(company := {}, auto_play := true) -> void:
|
||||
battle_operation_id = String(battle.operation_id)
|
||||
guild_company = resolved
|
||||
current_screen = "battle"
|
||||
_build_world_base(false, BATTLE_FIELD)
|
||||
_build_world_base(false, _battle_field_texture())
|
||||
var frame_safe := _framed_page_safe("Battle")
|
||||
frame_safe.add_child(_entry_chrome("BattleFrame", "initial_company_scene_frame"))
|
||||
var safe := _content_page_safe("Battle")
|
||||
|
||||
Reference in New Issue
Block a user