diff --git a/Source/UI/Chat/UIWhisperWnd.h b/Source/UI/Chat/UIWhisperWnd.h index 819e87f..e7847bb 100644 --- a/Source/UI/Chat/UIWhisperWnd.h +++ b/Source/UI/Chat/UIWhisperWnd.h @@ -17,6 +17,7 @@ public: void Paint() override; void Slot26(int x, int y) override; void Slot33(int x, int y) override; + void Slot43() override; protected: UIButtonContext* m_controls; diff --git a/Source/UI/Window/UIWindow.h b/Source/UI/Window/UIWindow.h index 616516d..4161832 100644 --- a/Source/UI/Window/UIWindow.h +++ b/Source/UI/Window/UIWindow.h @@ -29,6 +29,7 @@ struct SpriteRleImage; struct SpriteFrameCell; class CBitmapRes; class CActRes; +class TextureCache; struct WindowReplayRecorder; struct UIWindowContext { @@ -41,6 +42,7 @@ struct UIWindowContext { WindowRegistration& registration; UIWindowMgr& windowMgr; std::unordered_set& deferredDeletion; + TextureCache& textures; void DestroyDeferredChildren(); }; diff --git a/Source/UI/WindowOverlay.cpp b/Source/UI/WindowOverlay.cpp new file mode 100644 index 0000000..6dfe7a7 --- /dev/null +++ b/Source/UI/WindowOverlay.cpp @@ -0,0 +1,20 @@ +#include "Render/Primitives/AlphaRectangle.h" +#include "Render/Renderer.h" +#include "Render/TextureQuad.h" +#include "UI/Chat/UIWhisperWnd.h" + +// OFFSET: 0x008D0DB0 +// FUNCTION: fn_12091 +void UIWhisperWnd::Slot43() { + int x = 0; + int y = 0; + this->ToScreen(x, y); + DrawAlphaRectangle( + g_renderer->primitives, this->m_context->textures, g_renderer->queues, x + 1, y + 1, this->geometry.width - 2, this->geometry.height, 0x66000000, + g_renderer->fog.supported != 0, g_depthStart, g_depthEnd + ); + DrawAlphaRectangle( + g_renderer->primitives, this->m_context->textures, g_renderer->queues, x + 1, y + 1, this->geometry.width - 2, 17, 0x449EB6E4, + g_renderer->fog.supported != 0, g_depthStart, g_depthEnd + ); +} diff --git a/data/compile.json b/data/compile.json index ed52efb..032233d 100644 --- a/data/compile.json +++ b/data/compile.json @@ -700,6 +700,7 @@ "Source/UI/Window/WindowRetirement.cpp": 2, "Source/UI/WindowBackground.cpp": 2, "Source/UI/WindowLowerBorder.cpp": 2, + "Source/UI/WindowOverlay.cpp": 2, "Source/UI/WindowSprite.cpp": 2, "Source/UI/WindowTitlebar.cpp": 2, "Source/Utility/AES.cpp": 0,