Merge pull request #211 from kittenchilly/master

Use official HUD Offset support in Rep
This commit is contained in:
wofsauge authored and GitHub committed 2021-11-18 22:28:23 +01:00
commit 3dc11cd2a0
3 files changed
+11 -1

No files matched your search

+3
View File
@@ -868,6 +868,9 @@ function EID:handleHUDElement(hudElement)
end
local screenSize = EID:getScreenSize()
local hudOffset = EID.Config["HUDOffset"]
if REPENTANCE then
hudOffset = (Options.HUDOffset * 10)
end
for _,v in ipairs(hudElement.anchors) do
if v == "TOP" then
alteredHudElement.y = hudElement.y + hudOffset * 2
+5 -1
View File
@@ -837,7 +837,11 @@ if EID.MCMLoaded or REPENTANCE then
EID.isHidden = EID.Config["InitiallyHidden"]
EID.UsedPosition = Vector(EID.Config["XPosition"], EID.Config["YPosition"])
EID:loadFont(EID.modPath .. "resources/font/eid_"..EID.Config["FontType"]..".fnt")
EID:addTextPosModifier("HudOffset", Vector((EID.Config["HUDOffset"] * 2) - 20, EID.Config["HUDOffset"] - 10))
if REPENTANCE then
EID:addTextPosModifier("HudOffset", Vector(((Options.HUDOffset * 10) * 2) - 20, (Options.HUDOffset * 10) - 10))
else
EID:addTextPosModifier("HudOffset", Vector((EID.Config["HUDOffset"] * 2) - 20, EID.Config["HUDOffset"] - 10))
end
end
end
+3
View File
@@ -32,6 +32,9 @@ function EID:renderMCMDummyDescription()
if hudOffset == nil and ScreenHelper then
hudOffset = ScreenHelper.GetOffset()
end
if REPENTANCE then
hudOffset = (Options.HUDOffset * 10)
end
EID.Config["HUDOffset"] = hudOffset
EID:addTextPosModifier("HudOffset", Vector((hudOffset * 2) - 20, hudOffset - 10))
if MCM.IsVisible and EID.MCMCompat_isDisplayingEIDTab ~= "" then