♻ScrW ScrH#18
Conversation
1000000 iters Before: 25.63 After: 0.27
|
Hello, this optimization previously existed in patches, but it caused problems with workshop addons. It is not mentioned on the wiki, but ---@type CamData
local camera = {
type = "3D",
x = 128,
y = 128,
w = 128,
h = 128
}
hook.Add( "HUDPaint", "test1", function()
print( ScrW(), ScrH() ) -- 1920 1080
cam.Start( camera )
cam.Start2D()
print( ScrW(), ScrH() ) -- 128 128
cam.End2D()
cam.End()
end )If you think this should be added, we can run new tests and re-check; perhaps it no longer causes problems. |
|
🤔 |
|
i've been using this optimization for almost 2 years on my sandbox server without any problems |
|
as I remember this addon stops working properly with this optimization |
Okay, yes, and also: well i feel like things are better now |
---@type CamData do end hook.Add("HUDPaint", "test1", function() end) probaly could make it better |
1000000 iters
Before: 25.63
After: 0.27