85 lines
2.1 KiB
Lua
85 lines
2.1 KiB
Lua
local f0_local0 = module
|
|
local f0_local1, f0_local2 = ...
|
|
f0_local0( f0_local1, package.seeall )
|
|
CoD.PrintModuleLoad( _NAME )
|
|
f0_local0 = function ( f1_arg0, f1_arg1 )
|
|
LUI.FlowManager.RequestLeaveMenu( f1_arg0 )
|
|
end
|
|
|
|
f0_local1 = function ( f2_arg0, f2_arg1 )
|
|
f2_arg0:setText( Game.GetMigrationStatus() )
|
|
end
|
|
|
|
f0_local2 = function ()
|
|
local self = LUI.UIElement.new()
|
|
self.id = "percentage_display_id"
|
|
self:registerAnimationState( "default", {
|
|
topAnchor = true,
|
|
leftAnchor = true,
|
|
top = 100,
|
|
left = 100,
|
|
height = 65,
|
|
width = 512
|
|
} )
|
|
self:animateToState( "default", 0 )
|
|
local f3_local1 = LUI.UIText.new()
|
|
f3_local1.id = "hm_description_id"
|
|
f3_local1:registerAnimationState( "default", {
|
|
topAnchor = true,
|
|
leftAnchor = true,
|
|
top = 0,
|
|
left = 0,
|
|
height = CoD.TextSettings.BoldFont.Height,
|
|
width = 512,
|
|
font = CoD.TextSettings.BoldFont.Font,
|
|
alignment = LUI.Alignment.left
|
|
} )
|
|
f3_local1:animateToState( "default", 0 )
|
|
f3_local1:setText( "" )
|
|
f3_local1:setTextStyle( CoD.TextStyle.Shadowed )
|
|
f3_local1:registerEventHandler( "host_migration_update", f0_local1 )
|
|
LUI.MenuBuilder.BuildAddChild( f3_local1, {
|
|
type = "UITimer",
|
|
id = "hm_description_refresh_id",
|
|
properties = {
|
|
event = "host_migration_update",
|
|
interval = 250
|
|
}
|
|
} )
|
|
self:addElement( f3_local1 )
|
|
return self
|
|
end
|
|
|
|
LUI.MenuBuilder.registerType( "host_migration_main", function ()
|
|
local f4_local0 = Engine.Localize( "@LUA_MENU_HOST_MIGRATION_CAPS" )
|
|
local self = LUI.UIElement.new()
|
|
self.id = "host_migration_id"
|
|
self:registerAnimationState( "default", {
|
|
topAnchor = true,
|
|
leftAnchor = true,
|
|
bottomAnchor = true,
|
|
rightAnchor = true,
|
|
top = 0,
|
|
left = 0,
|
|
bottom = 0,
|
|
right = 0,
|
|
alpha = 1
|
|
} )
|
|
self:animateToState( "default", 0 )
|
|
self:registerEventHandler( "hide_host_migration", f0_local0 )
|
|
LUI.MenuBuilder.BuildAddChild( self, {
|
|
type = "UIWorldBlur",
|
|
id = "hmWorldBlurOverlay",
|
|
states = {
|
|
default = {
|
|
worldBlur = 5
|
|
}
|
|
}
|
|
} )
|
|
self:addElement( LUI.mp_hud.OptionsMenu.mp_pause_menu_background_def() )
|
|
self:addElement( LUI.mp_hud.OptionsMenu.mp_pause_menu_title_def( f4_local0 ) )
|
|
self:addElement( f0_local2() )
|
|
return self
|
|
end )
|
|
LockTable( _M )
|