The Gold Road Chapter – which includes the Scribing system – and Update 42 is now available to test on the PTS! You can read the latest patch notes here: https://forums.elderscrollsonline.com/en/discussion/656454/
Maintenance for the week of April 22:
• [COMPLETE] Xbox: NA and EU megaservers for patch maintenance – April 24, 6:00AM EDT (10:00 UTC) - 12:00PM EDT (16:00 UTC)
• [COMPLETE] PlayStation®: NA and EU megaservers for patch maintenance – April 24, 6:00AM EDT (10:00 UTC) - 12:00PM EDT (16:00 UTC)

FTC Combat Log window focus issues

I_killed_Vivec
I_killed_Vivec
✭✭✭✭✭
✭✭
I understand that it might not be properly supported but I still love the FTC Combat Log, untethered from chat so it is in its own window. Unfortunately since High Isle there has been a change and it's parent is now GuiRoot and not FTC_UI. This fixes a bug that the UI reported on load, but (for me at least!) has the unfortunate side-effect of always making the window present, regardless of whether I'm in "normal" mode, or looking at inventory, checking emails, interacting with the bank, etc.

The only fix that I found for this was to toggle its visibility completely - so if I wanted it in combat I could have it on, but if interacting with the bank I could explicitly switch it off. Not ideal, but a work around I was prepared to accept.

This latest release (U35) has broken that because even if I switch it off when I attempt to add items to guild store via the banker it becomes live again, and will not toggle off until I leave the banker.

Does anyone know of a work around for this? I'd really like a fix so that it disappeared completely when not in "normal" mode, but I'd be happy enough just to have a toggle switch that worked!

Best Answer

  • Baertram
    Baertram
    ✭✭✭✭✭
    Hopefully I didn't break it...

    Welcome to addon development :D
    Answer ✓
  • Necrotech_Master
    Necrotech_Master
    ✭✭✭✭✭
    ✭✭✭✭✭
    ive noticed this issue as well since U34, the combat log used to always hide when in other menus (the esc menu, inventory, bank etc)

    it was more of an issue for me because of the esc menu since i have it on my left window basically right where all of the esc menu options show up (so i would have to move the menu to access addon or game settings, or even the logout on my laptop)
    plays PC/NA
    handle @Necrotech_Master
    active player since april 2014
  • Baertram
    Baertram
    ✭✭✭✭✭
    https://www.esoui.com/downloads/info1611-FoundryTacticalCombatFTC-HighIsle.html#comments

    Report it here so it gets fixed. Screenshots help btw.
    Seems that TNTKokser already did report it there as I see his screenshot?
    So you need to wait for the dev, Rhyono, to find the time.

    Edit:
    I overread that Rhyono is not actively playing ESO any longer, so maybe someone else will provide a fix there at the comments, like they did before, and Rhyono is at least able to update it then.
    Edited by Baertram on August 24, 2022 6:01PM
  • I_killed_Vivec
    I_killed_Vivec
    ✭✭✭✭✭
    ✭✭
    Thanks for the responses. Something happen last night (maybe the game update, because I hadn't updated addons), so now accessing the banker's guild store option doesn't automatically make the combat log active.

    So my immediate issue is solved, but I'd still prefer it if the combat log switched focus so it disappeared when switching from the "main" view".

    I'd be happy to help with a fix (lua isn't my main programming language, but I'm adaptable ;) ) but I'm not up to date with the ESO API or even why the change had to be made in the first place.

    Maybe I need to make the plunge...
  • Baertram
    Baertram
    ✭✭✭✭✭
    I'd guess the combat log is a TopLevelControl as you said so it got a control that can be added to a "fragment".
    A fregment is reusable code (e.g. the player inventory list control which will be reused at normal player inv, bank deposit, guildbank deposit, mail, trade, sell at guild store e.g.) used in game scenes. A scene defines something like the shown panels (guild bank, bank, trading house, mail, ...).

    You can craete your own custom fragment and assign it to the GUI and HUD_GUI scenes as changing the scenes will hide/show the fragments automatically. This way you can e.g. make a custom reminder icon texture control show and hide with the menus.

    Here is an example at the ESOUI Wiki:
    https://wiki.esoui.com/How_to_hide_controls_as_menu_opens
    local fragment = ZO_HUDFadeSceneFragment:New(yourTopLevelControlName, nil, 0)
    --You can also just use ZO_SimpleSceneFragment instead of ZO_HUDFadeSceneFragment 
    HUD_SCENE:AddFragment(fragment)
    HUD_UI_SCENE:AddFragment(fragment)
    

    yourTopLevelControlName needs to be the global control (TLC) which holds this addon's combat log then.

    But you would also need to remove older other code that handles the show/hide currently so I guess it won't be an easy fix.

    Search for <yourTopLevelControlName>:SetHidden(true) or false to find where it might get hidden/shown
    Edited by Baertram on August 24, 2022 8:35PM
  • I_killed_Vivec
    I_killed_Vivec
    ✭✭✭✭✭
    ✭✭
    Baertram wrote: »
    I'd guess the combat log is a TopLevelControl as you said so it got a control that can be added to a "fragment".
    A fregment is reusable code (e.g. the player inventory list control which will be reused at normal player inv, bank deposit, guildbank deposit, mail, trade, sell at guild store e.g.) used in game scenes. A scene defines something like the shown panels (guild bank, bank, trading house, mail, ...).

    You can craete your own custom fragment and assign it to the GUI and HUD_GUI scenes as changing the scenes will hide/show the fragments automatically. This way you can e.g. make a custom reminder icon texture control show and hide with the menus.

    Here is an example at the ESOUI Wiki:
    https://wiki.esoui.com/How_to_hide_controls_as_menu_opens
    local fragment = ZO_HUDFadeSceneFragment:New(yourTopLevelControlName, nil, 0)
    --You can also just use ZO_SimpleSceneFragment instead of ZO_HUDFadeSceneFragment 
    HUD_SCENE:AddFragment(fragment)
    HUD_UI_SCENE:AddFragment(fragment)
    

    yourTopLevelControlName needs to be the global control (TLC) which holds this addon's combat log then.

    But you would also need to remove older other code that handles the show/hide currently so I guess it won't be an easy fix.

    Search for <yourTopLevelControlName>:SetHidden(true) or false to find where it might get hidden/shown

    Thanks for the heads up. I'll take a look at it this weekend!
  • Baertram
    Baertram
    ✭✭✭✭✭
    If you need more info abou eso addons, lua, dev tools, ingaem variable inspectors etc. I had written some howtos and info threads at www.esoui.com:
    https://www.esoui.com/forums/forumdisplay.php?f=172
    At the top you'll find the "sticky threads" with that info, e.g.
    "New to addon creation?"

    DevTools: https://www.esoui.com/forums/forumdisplay.php?f=173
    Stick threads again at the top



    You can visit us here to talk with some devs if you like to:
    https://gitter.im/esoui/esoui
    Edited by Baertram on August 24, 2022 10:29PM
  • I_killed_Vivec
    I_killed_Vivec
    ✭✭✭✭✭
    ✭✭
    Fantastic! Thanks again. I'd always said that I wouldn't get drawn into addons because I develop software for a living (though for very different systems) and don't want to mix work and play.

    But I can see that changing... :)
  • Baertram
    Baertram
    ✭✭✭✭✭
    Yeah, I had the same thoughts and a similar background.. welll... since 2014 -> addons :D
    But it's fun! I like this hobby, allthough the normal job drags me into software coding and such topcis too.
  • Baertram
    Baertram
    ✭✭✭✭✭
    From quickly scanning the code of FTS there are several FTC_CombatLog:SetHidden function calls.
    Seems to hide and show with the chat if FTC.Vars.AlternateChat is true.
    Else it hides as you move -> if FTC.move then FTC_CombatLog:SetHidden(false)

    FTC_CombatLog is created and assigned from the library LibMsgWin
    ocal FCL = _G["FTC_CombatLog"]
    if FCL == nil then
    FCL = FTC.LMW:CreateMsgWindow("FTC_CombatLog", GetString(FTC_CL_Label) , nil , nil )

    So maybe the lib needs an update if it does not hide properly anymore,
    But I'd start with all those FTC_CombatLog:SetHidden calls first to see when it gets unhidden.

    Add debug messages before the calls like to see what happens when.
    d("Called from function xyz-variable1: " .. tostring(variable1))

    I recommand using LibDebugLogger and DebugLogViewer (an extra UI to see those d() messages seperated from chat and to find and see error messages, the loaded addons and their version more easily).
  • I_killed_Vivec
    I_killed_Vivec
    ✭✭✭✭✭
    ✭✭
    @Baertram

    It took me longer than it should have but I have a solution. With hindsight (!) it was quite obvious:

    - For High Isle the Combat Log window could not use the FTC_UI as parent, it had to be GuiRoot.

    - The event handler for "context" switch (push/pop layer) only managed the visibility of the FTC layer:

    function FTC.OnLayerChange( eventCode, layerIndex, activeLayerIndex )
    FTC:ToggleVisibility( activeLayerIndex )

    which now does not include the Combat Log window.

    That's why other components (Action Bar, etc) do disappear when the context switches, but the Combat Log doesn't.

    To further complicate matters, the initialization of the combat log hooked it into the maximization/minimization of the chat window, which isn't appropriate for a standalone log because for a lot of context changes the chat window is not minimized.

    The solution is to add a new function to toggle the visibility of the Combat Log when processing OnLayerChange() and run FTC with Alternate With Chat set to off.

    There was also an issue with toggling the visibility of the combat log using the addon keybind - as you pointed out this was related to chat if AlternateChat is true. If it isn't true then it wasn't being processed.

    I fixed that too, and it all appears to work. I posted a reply on the FTC website but there seems to be some confusion over how the code is handled, so I'll wait until someone tells me what to do!
  • Baertram
    Baertram
    ✭✭✭✭✭
    Glad you could make it work.
    If it's about updating the code and the original dev is not there anymore, you can look at the Esoui forum where there are sticky posts at the top of the addon help forums. It takes you what to do and to wait for or custom updates are wished or if you want to take over an addon.

    More of the time posting the addons fixed code or a total zip file from a cloud drive, at the addon comments, it's enough and works too ;-)
    Edited by Baertram on August 30, 2022 4:50PM
  • Necrotech_Master
    Necrotech_Master
    ✭✭✭✭✭
    ✭✭✭✭✭
    very nice

    i personally find FTC to be a rather bulky addon, and have most of the other stuff in it disabled outside of the scrolling combat log and the dps meter (i actually use 2 dps meters, the FTC one and the combat metrics one)

    i quite dislike all the "frames" it changes like the group one, my personal attributes and targeting (use basically the default UI for those)
    plays PC/NA
    handle @Necrotech_Master
    active player since april 2014
  • Baertram
    Baertram
    ✭✭✭✭✭
    I had used FTC in the past but disabled it years ago as it got slow and made by game lag.
    For now I'm only using Azurah to move vanilla UI controls like the attribute bars and only a few UI related addons (Perfect Pixel e.g.).
    Less addons = more speed.

    I dislike those total UI addons like AUI or Hoft's Bandit stuff (beside the fact that it includes many things, likeFTC, I'd never use they also often run events and code where not needed, even if disabled -> Error prone/ressource hungry/performance loss).
  • Baertram
    Baertram
    ✭✭✭✭✭
    @I_killed_Vivec
    Here is the GitHub link to the addon repository
    https://github.com/Rhyono/Foundry-Tactical-Combat

    if you are used to GitHub: Fork it and patch it in your fork with your changed code, then send a pull request so Rhyono get's your version code and is able to officially update it at www.esoui.com from GitHub.
    This way all benefit.

    If you are not used to GitHub maybe just send a message to Rhyono via esoui PM or GitHub website -> Open a new "Issue" at the Github repo of FTC and provide your code as a zip file link there so Rhyono can copy and fix it himself in his GitHub repo.
    Edited by Baertram on August 30, 2022 5:02PM
  • Necrotech_Master
    Necrotech_Master
    ✭✭✭✭✭
    ✭✭✭✭✭
    Baertram wrote: »
    I had used FTC in the past but disabled it years ago as it got slow and made by game lag.
    For now I'm only using Azurah to move vanilla UI controls like the attribute bars and only a few UI related addons (Perfect Pixel e.g.).
    Less addons = more speed.

    I dislike those total UI addons like AUI or Hoft's Bandit stuff (beside the fact that it includes many things, likeFTC, I'd never use they also often run events and code where not needed, even if disabled -> Error prone/ressource hungry/performance loss).

    i havent noticed performance issues so far, but it makes sense (and one of the reasons why i would prefer an FTC-lite which is just the combat log and dps meter)

    the avg lua memory im using between all of my addons (about 40 total), is 350-380 MB (excluding some weird memory leak issue im having with one or more addons when me or allies die in instanced content, its much worse in trials than dungeons/arenas, but dont want to derail too much lol)
    plays PC/NA
    handle @Necrotech_Master
    active player since april 2014
  • Baertram
    Baertram
    ✭✭✭✭✭
    I think the lua memory is nothing you can use as an indicator of slow game etc. anymore as there is no real "maximum" afaik (exceot: Your RAM size).
    It was in the past before 64bit support of ESO, but now it's more about your CPU speed, server and network speed and population: Many players, sending many requests, server needs to answer, etc.
    Especially in areas where there are less instances this can get laggy and slow then.

    And some addons add to that by circumventing ZOs protections like "You must open the AvA campaign lists manually first to initiate some server fetched data" -> Addon: Automatically opens it and makes the server answer.

    In the end the number of enabled addons AND their code (espeically combat events need filters so lua is not checking each combat event raised for each player near you at the server if you only want to see your own done dmg etc.) and API usage, the SavedVariables file size etc. will all sum up to the overall performance (not respecting any progeams running in background which will slow down your PC and consume RAM too, like TTC cient, and other clients/tools/videos/music players/etc. :D )
    Edited by Baertram on August 30, 2022 6:07PM
  • Necrotech_Master
    Necrotech_Master
    ✭✭✭✭✭
    ✭✭✭✭✭
    well it does in some ways matter, its easy to tell you have a memory leak in an addon when you log in and start at 380 MB used, and then after running a trial at like 500+, thats definitely not normal lol

    essential housing tools at one point had a memory leak for me, it was so bad i could only stay in a house for about 10 min before it started dropping my FPS to like <20 and i had to reloadui (i only used that briefly because a friend wanted to show me what they were working on)

    i use the info panel addon to show the used lua memory, which helps alert me to when there is a memory leak going on, the actual quantity used is not a huge concern, but i do have like a baseline, and if it goes like +100 MB over the baseline and doesnt go down without reloading the UI then something is leaking (it can be hard to tell with 40 addons though, granted most of them are extremely small, like one is just "mighty experience bar" to do some tweaks specifically for that lol)
    plays PC/NA
    handle @Necrotech_Master
    active player since april 2014
  • I_killed_Vivec
    I_killed_Vivec
    ✭✭✭✭✭
    ✭✭
    Baertram wrote: »
    @I_killed_Vivec
    Here is the GitHub link to the addon repository
    https://github.com/Rhyono/Foundry-Tactical-Combat

    if you are used to GitHub: Fork it and patch it in your fork with your changed code, then send a pull request so Rhyono get's your version code and is able to officially update it at www.esoui.com from GitHub.
    This way all benefit.

    Done - forked and pulled (!). And also available as FTC Lost Depths (v1.22) on ESOUI.

    Hopefully I didn't break it...
Sign In or Register to comment.