Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 28 additions & 0 deletions src/Modules/ItemTools.lua.rej
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
diff a/src/Modules/ItemTools.lua b/src/Modules/ItemTools.lua (rejected hunks)
@@ -53,7 +53,7 @@ function itemLib.formatValue(value, baseValueScalar, valueScalar, precision, dis
elseif displayPrecision then
return tostring(value, displayPrecision)
else
- return tostring(roundSymmetric(value, precision and m_min(2, m_floor(math.log(precision, 10) + 0.001)) or 2)) -- max decimals ingame is 2
+ return tostring(roundSymmetric(value, precision and m_min(2, m_floor(math.log(precision, 10) + 0.001)) or 2)) -- max decimals ingame is 2
end
end

@@ -117,7 +117,7 @@ function itemLib.applyRange(line, range, valueScalar, baseValueScalar)
modifiedLine = replaceNthInstance(modifiedLine, "#", values[i], i - substituted)
substituted = substituted + 1
end
-
+
-- Check if the modified line matches any scalability data
local key = modifiedLine:gsub("+#", "#")
if data.modScalability[key] then
@@ -339,7 +339,7 @@ function itemLib.formatModLine(modLine, dbMode)
line = line .. " ^1'" .. modLine.extra .. "'"
end
else
- colorCode = (modLine.crafted and colorCodes.CRAFTED) or (modLine.enchant and colorCodes.ENCHANTED) or (modLine.fractured and colorCodes.FRACTURED) or (modLine.mutated and colorCodes.MUTATED) or (modLine.custom and (not modLine.desecrated and colorCodes.CUSTOM)) or colorCodes.MAGIC
+ colorCode = (modLine.fractured and colorCodes.FRACTURED) or (modLine.crafted and colorCodes.CRAFTED) or (modLine.enchant and colorCodes.ENCHANTED) or (modLine.mutated and colorCodes.MUTATED) or (modLine.custom and (not modLine.desecrated and colorCodes.CUSTOM)) or colorCodes.MAGIC
end
return colorCode..line
end