dofile('data/Lua/Screens/DialogOK.lua')

function SetCaptions(screen)
	text_title = CreateTextEntity("WindowText28", GetString("Q_ERROR_MAX_PROFILES"))
    text_title:AttachTo( screen:GetObject('YesNoScreen') )
	text_title:SetScale(1)
	text_title:SetZ(190)
	text_title:SetXY(10, -70)
end

function OnButtonPress(title)
    DefaultOnButtonPress(title)
    
    -- destroy this screen
    local current_screen = GetGameManager():GetCurrentScreen()
    current_screen:SetAllowInput(false)
    current_screen:ScreenDestroy()
    
    if title == 'ok' then
        players_screen:SetAllowInput(true)
        players_screen:Go()
    end
end
