perf/chat-wrap-cache · PurpleFuchs · 3 Dateien · +35 −5 · 2026-11-07
Zusammenfassung
Card a141db (Kai chose Option 1: wrap cache). Both chat paths ran font:getWrap on every log entry every frame (open log + overlay twin at ChatWindow:321, per analyst) — up to 1000 wraps/frame. New shared GuiElements/Chat/ChatWrapCache.GetLines: single-slot {Text,Width,Font,Lines} cache on the entry itself (mutation/resize/font-safe, no flush path needed). Font in the key because both paths wrap the same FILE_Log with different font objects. luajit clean.
Geänderte Dateien (3)
| Source/GuiElements/Chat/ChatWrapCache.lua | neu | +29 −0 |
| Source/GuiElements/Chat/DrawChatWindow.lua | geändert | +2 −2 |
| Source/Objects/Gui/ChatWindow.lua | geändert | +4 −3 |