Skip to content

Commit

Permalink
Padding adjustment (#5)
Browse files Browse the repository at this point in the history
  • Loading branch information
ThisIsFineCopium authored Aug 7, 2024
1 parent b04b76a commit e04d8d9
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 3 deletions.
9 changes: 6 additions & 3 deletions Main/MapNotify.cs
Original file line number Diff line number Diff line change
Expand Up @@ -165,14 +165,17 @@ public void RenderItem(NormalInventoryItem Item, Entity Entity, bool isInventory
classID.Contains("HeistBlueprint")) &&
ItemDetails.ActiveWarnings.Count == 0) return;
// Get mouse position
var boxOrigin = new nuVector2(MouseLite.GetCursorPositionVector().X + 24, MouseLite.GetCursorPositionVector().Y);
var boxOrigin = new nuVector2(MouseLite.GetCursorPositionVector().X + 25, MouseLite.GetCursorPositionVector().Y);

// Pad vertically as well if using ninja pricer tooltip
if (Settings.PadForNinjaPricer && ItemDetails.NeedsPadding)
boxOrigin = new nuVector2(MouseLite.GetCursorPositionVector().X + 24, MouseLite.GetCursorPositionVector().Y + 56);
boxOrigin = new nuVector2(MouseLite.GetCursorPositionVector().X + 25, MouseLite.GetCursorPositionVector().Y + 56);
// Pad vertically as well if using ninja pricer tooltip 2nd padding
if (Settings.PadForNinjaPricer2 && ItemDetails.NeedsPadding)
boxOrigin = new nuVector2(MouseLite.GetCursorPositionVector().X + 25, MouseLite.GetCursorPositionVector().Y + 114);
// Personal pricer
if (Settings.PadForAltPricer && ItemDetails.NeedsPadding)
boxOrigin = new nuVector2(MouseLite.GetCursorPositionVector().X + 24, MouseLite.GetCursorPositionVector().Y + 30);
boxOrigin = new nuVector2(MouseLite.GetCursorPositionVector().X + 25, MouseLite.GetCursorPositionVector().Y + 30);

// Parsing inventory, don't use boxOrigin
if (isInventory)
Expand Down
2 changes: 2 additions & 0 deletions Settings/DrawSettings.cs
Original file line number Diff line number Diff line change
Expand Up @@ -232,6 +232,8 @@ public override void DrawSettings()
ImGui.SameLine(); HelpMarker("This will irreversibly delete all your existing warnings config files!");
Settings.PadForNinjaPricer.Value = Checkbox("Pad for Ninja Pricer", Settings.PadForNinjaPricer);
ImGui.SameLine(); HelpMarker("This will move the tooltip down vertically to allow room for the Ninja Pricer tooltip to be rendered. Only needed with that plugin active.");
Settings.PadForNinjaPricer2.Value = Checkbox("More Pad for Ninja Pricer", Settings.PadForNinjaPricer2);
ImGui.SameLine(); HelpMarker("This will move the tooltip down vertically to allow room for the Ninja Pricer tooltip to be rendered. Only needed with that plugin active.");
Settings.PadForAltPricer.Value = Checkbox("Pad for Personal Pricer", Settings.PadForAltPricer);
ImGui.SameLine(); HelpMarker("It's unlikely you'll need this.");
ImGui.Spacing();
Expand Down
1 change: 1 addition & 0 deletions Settings/MapNotifySettings.cs
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ public class MapNotifySettings : ISettings
public ToggleNode ShowCompletion { get; set; } = new(true);
public ToggleNode HorizontalLines { get; set; } = new(true);
public ToggleNode PadForNinjaPricer { get; set; } = new(false);
public ToggleNode PadForNinjaPricer2 { get; set; } = new(false);
public ToggleNode PadForAltPricer { get; set; } = new(false);
public ToggleNode AlwaysShowTooltip { get; set; } = new(true);
public ToggleNode AlwaysShowCompletionBorder { get; set; } = new(true);
Expand Down

0 comments on commit e04d8d9

Please sign in to comment.