Skip to content

Comments

Midnight WIP#725

Merged
p3lim merged 159 commits intomasterfrom
midnight
Jan 17, 2026
Merged

Midnight WIP#725
p3lim merged 159 commits intomasterfrom
midnight

Conversation

@p3lim
Copy link
Member

@p3lim p3lim commented Oct 24, 2025

Most of these tests are being performed while in combat inside a dungeon, to ensure compatibility with secrets.

Legend:

  • 🟢 = everything works just fine as-is or with changes in this PR
  • 🟡 = mostly works or can be made to work with changes, or needs further testing
  • 🔴 = something is broken and we can't fix it
    • if it has this mark then we expect this to work but need Blizzard to do something
  • 💀 = completely dead and is intentionally not going to work
  • if something doesn't have an emoji then it just means I haven't tested it yet, don't nag, be patient

Status of checked things (last check = build 65028 (PTR RC 2)):

  • 🟢 core
  • 🟢 standard unit logic (i.e. player, target, etc)
  • 🟢 groups
    • they spawn atleast, need to check what happens when players join/leave in combat
  • 🟢 nameplates
    • they work fine, but we have to deploy a hack to make them clickable
    • this hack will not be necessary once they add a hitrect reparent API (planned)
  • arena prep

Elements:

  • additionalpower
  • alternativepower
  • 🟢 assistantindicator
    • only tested on player+target
  • 🟢 auras
    • 🟢 dispel color
    • 🟢 "stealable"
    • 🟢 cooldown spiral
    • 🟢 aura count
    • 🟢 tooltips
    • 🟡 sorting by time
      • there are new APIs for sorting, but it'll require a non-insignificant rework of how we deal with UNIT_AURA payload, so it'll be TBD for a bit
  • 🟡 castbar
    • 🟢 cast; statusbar, text, time, icon
    • 🟢 channel
    • 🟢 tracking casts across events
    • 🟢 empowered abilities for non-player
      • 🔴 unable to determine which stage is currently active, which makes fancy stuff less fancy
    • 🔴 cast/channel delay for non-player
      • planned new secrets formatter specifically for this in a later build
    • 🟢 change color based on interruptible state
    • 🟢 tradeskill hiding
  • 🟢 classpower
  • 🟢 combatindicator
    • only tested on player
  • 🟢 grouproleindicator
  • 🟢 health
  • 🟢 healthprediction
  • 🟢 leaderindicator
    • only tested on player+target
  • phaseindicator
  • portrait
  • 🟢 power
  • 🟢 powerprediction
    • only tested against power, not additionalpower
  • pvpclassificationindicator
  • 🟢 pvpindicator
    • only tested on player
  • questindicator
  • raidroleindicator
  • 🟢 raidtargetindicator
    • not tested on group/nameplates yet
  • 🟢 range
  • 🟢 readycheckindicator
  • 🟢 restingindicator
    • only tested on player
  • resurrectindicator
  • 🟢 runes
  • 🟢 stagger
  • summonindicator
  • 🟡 tags
    • when a tag contains secrets we're limited with what we can check (i.e. if a tag is empty or not), and I assume any boolean APIs would return secrets too so that won't fix anything
    • because of this it might be better (for layouts) to deal with updating fontstrings through PostUpdate of relevant elements (like before the tags were added) or with custom event handlers (which oUF makes pretty straight forward to add)
    • STATUS: need to decide what to do with this element
  • threatindicator
  • totems

New stuff:

  • Demon Hunter soul fragments
    • uses UNIT_AURA for some dumb reason, so can't put it in classpower

@p3lim p3lim added this to the midnight milestone Oct 24, 2025
@p3lim p3lim assigned p3lim and ls- Oct 24, 2025
@ls-
Copy link
Member

ls- commented Oct 24, 2025

giphy

@p3lim

This comment was marked as outdated.

@ls-

This comment was marked as outdated.

@kodewdle

This comment was marked as off-topic.

@remyeik

This comment was marked as off-topic.

@GuillaumeEllby

This comment was marked as off-topic.

@myzb

This comment was marked as off-topic.

@ls-

This comment was marked as outdated.

@p3lim
Copy link
Member Author

p3lim commented Nov 16, 2025

Leaving player secondary power tags as-is for now, as Blizzard has said they'd be made non-secret later in the beta.

@p3lim
Copy link
Member Author

p3lim commented Nov 16, 2025

As for 85aba05, :SetShown(secretBoolean) should also be possible in a later beta build.

That'll solve the stealable logic.

@p3lim
Copy link
Member Author

p3lim commented Nov 16, 2025

@ls- Was GetUnitTotalModifiedMaxHealthPercent ever used? I can't recall a single encounter.

@ls-
Copy link
Member

ls- commented Nov 16, 2025

@ls- Was GetUnitTotalModifiedMaxHealthPercent ever used? I can't recall a single encounter.

Nah, I coded the temp max health loss without it.

@p3lim
Copy link
Member Author

p3lim commented Nov 16, 2025

@ls-
Copy link
Member

ls- commented Nov 17, 2025

Oof, my bad, that's a brainfart, man, all the irl bs ate through my brain.

Yeah, it's used in devles, like with the poison clouds and shadow. It's a stacking debuff that reduces your max health and it looks like a bar that pushes on your health bar.

my ui
image

blizz ui
image

The easiest place to test it is Kriegval's Rest in Isle of Dorn.

@ls-
Copy link
Member

ls- commented Nov 17, 2025

Demon Hunter soul fragments

uses UNIT_AURA for some dumb reason, so can't put it in classpower

Aug evoker bar also works similarly. It's called ebon might, and it's basically a fancy way of showing the duration of the buff. And for DHs it's just a way of showing stacks on the buff.

Imho, these things should be in the cooldown managers, not these fake classpower bars.

@Coldkil
Copy link

Coldkil commented Nov 21, 2025

Sorry if this is the wrong place to write, but after the last month gloomy post, i see you guys still actively working on the project and for this i thank you - i am in the process of rewriting/reskinning the default UFs in the least invasive way as a backup plan for Midnight, but it's clear how their code is literally meant to be completely replaced and not worked with (like having to hook setting the texture of the mana bar every time the updates fire FFS - i can give you my current code if you want to laugh).

Just to get in touch and see if i understood the situation - while cosmetic stuff is mostly fine, the bulk of the changes is affecting auras and tags due to the fact that if our addon know values related to those elements we can also build things that do logic automatically, am i right?

@p3lim
Copy link
Member Author

p3lim commented Nov 22, 2025

The biggest hurdle is that we cannot compare secrets or do math on them. They are (slowly) making workarounds for the things we need to make the basics working properly, without exposing too much and end up right back where we were with addons solving encounters.

I am in direct contact with members of the Blizzard UI team now, so hopefully there will be some directed progress into making oUF (and other unit frame addons) work before the launch.

@Coldkil
Copy link

Coldkil commented Nov 22, 2025

Ok, that's great to know. I'll leave you to your work and follow this post as it's updated to see how it's going.
Thanks again for the effort you're putting in the project.

@Witnesscm

This comment was marked as resolved.

@p3lim

This comment was marked as resolved.

@p3lim
Copy link
Member Author

p3lim commented Dec 7, 2025

Things confirmed to come in Beta 4:

  • Aura sorting (although it'll require a full rewrite of the auras element if we want to support it, as the sorting isn't available to UNIT_AURA payload)
  • Curve support for debuff types
  • Remaining duration will be zero for permanent auras
    • This should fix the remaining cooldown issue
  • New API that returns a (secret) bool for permanent vs. not permanent auras
    • We can use this with :SetAlphaFromBoolean to hide cooldowns
  • New API(?) GetApplicationDisplayCount that lets us set a lower limit on aura applications
    • This should fix the aura count always showing "1"
  • Misc performance improvements for any aura API that uses unitToken, auraInstanceID as a pair

Preview notes for the aura sorting:

Sorting is implemented through extra optional parameters to C_UnitAuras.GetUnitAuras/GetUnitAuraInstanceIDs:

local sortedAuras = C_UnitAuras.GetUnitAuras(unitToken, filter[, maxCount[, sortRule[, sortDirection]]])
local sortedAuraInstanceIDs = C_UnitAuras.GetUnitAuraInstanceIDs(unitToken, filter[, maxCount[, sortRule[, sortDirection]]])

The sorting is applied on all auras for the unit matching the supplied filter, and after sorting the result list is truncated to maxCount if specified.

Sort rules are as follows:

  • Enum.UnitAuraSortRule.Default - equivalent to AuraUtil.DefaultAuraCompare
  • Enum.UnitAuraSortRule.BigDefensive - equivalent to AuraUtil.BigDefensiveAuraCompare
  • Enum.UnitAuraSortRule.Expiration - equivalent to Default with an added comparison for expiration time before the aura instance ID fallback. Unlike SecureAuraHeaderTemplate, this sorts permanent duration auras to the end of the list (ie. as-if they had an infinite expiry time).
  • Enum.UnitAuraSortRule.ExpirationOnly - Pure comparison on expiration time only. Same note about permanent aura durations applies.
  • Enun.UnitAuraSortRule.Name - equivalent to Default with an added comparison for (unicode-aware) name-based sorting before the aura instance ID fallback.
  • Enum.UnitAuraSortRule.NameOnly - Pure comparison on name only.

sortDirection is either Enum.UnitAuraSortDirection.Normal or .Reverse.

@p3lim
Copy link
Member Author

p3lim commented Dec 12, 2025

Everything visible aura-related is now fixed.

Still need to deal with the new way to sort auras, which doesn't support partial UNIT_AURA payload. Right now we just sort by player first then instanceID second (which means FIFO). Blizzard has given us ways to sort auras in a plethora of ways (see UnitAuraSortDirection and UnitAuraSortRule).

@p3lim
Copy link
Member Author

p3lim commented Dec 12, 2025

A note on the debuff colors:

If you don't want to see the color of a certain type (like the "none" type) you can replace the color with a new one that has 0 alpha (oUF.colors.debuff[0] = CreateColor(0, 0, 0, 0)), and the Overlay widget will effectively be hidden.

@p3lim
Copy link
Member Author

p3lim commented Dec 13, 2025

Castbar looking okay-ish, new APIs in beta 4 fixed the biggest issues, but still some remain.
See https://discord.com/channels/327414731654692866/1449232811117641822
The intent here is that we want to get rid of the huge OnUpdate script handler, but for now we need it to update fontstrings (statusbar is handled natively).

Heal prediction stuff might be seeing some improvements in beta 5, got word from my Blizzard contact.

The restricted environment got a fix for metatables in beta 4 as well, so we don't need to resort to Mixins.

@p3lim
Copy link
Member Author

p3lim commented Dec 17, 2025

Health prediction fully operational as of build 64914 (beta 5), but it warranted a rewrite of the element. While at it I renamed the widgets to make more sense, as well as adding support for two more widgets.

@p3lim
Copy link
Member Author

p3lim commented Dec 17, 2025

Nameplates work (visually), but they can't be clicked.
There are workarounds to this, by keeping the default .UnitFrame object and turning it invisible, but it's a hack, not a good enough solution.
Blizzard have stated they'll be adding an API so we can reparent and adjust the hitrect in a later build.

p3lim and others added 25 commits January 17, 2026 19:05
Might as well let this one rip now while we're making big changes
Previously this is something that layouts had to do in order for the
name plate unit frame to even show up, which is not a great UX,
especially when you're just getting started with oUF nameplates.

Layouts are fully capable of just clearing this and set their own points
if they need to, but default should've been there from the start.
We can concat secrets in strings just fine now
Unsure why this is necessary, we should look into this later
Also shifted things around to reduce nesting, and unnecessary call to
UnitPowerType when not needing it.
This will prevent castbars from hiding randomly when spamming instant
abilities during a cast
This avoids duplicate calls when using overrides
@p3lim p3lim merged commit e07a500 into master Jan 17, 2026
1 check passed
@p3lim p3lim deleted the midnight branch January 17, 2026 18:16
@oUF-wow oUF-wow locked as resolved and limited conversation to collaborators Jan 17, 2026
@p3lim
Copy link
Member Author

p3lim commented Jan 17, 2026

#740

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.