Skip to content

Commit

Permalink
showItemPropertyRanges: Spaces in range is only displayed if min or m…
Browse files Browse the repository at this point in the history
…ax value is negative
  • Loading branch information
nooperation committed Feb 1, 2024
1 parent a36cf29 commit e391cc3
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion plugins/showItemPropertyRanges/showItemPropertyRanges.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,14 @@ bool AppendStatPropertyRange(wchar_t* propertyString, D2ItemDataStrc* pItemData,
colorCode = '2'; // 8 highlights modified values, but it's probably too much information
}

wsprintfW(propertyString, L"%s ÿc%c[%d - %d]ÿc3", propertyString, colorCode, prop.nMin, prop.nMax);
if (prop.nMax < 0 || prop.nMin < 0)
{
wsprintfW(propertyString, L"%s ÿc%c[%d - %d]ÿc3", propertyString, colorCode, prop.nMin, prop.nMax);
}
else
{
wsprintfW(propertyString, L"%s ÿc%c[%d-%d]ÿc3", propertyString, colorCode, prop.nMin, prop.nMax);
}
return true;
}

Expand Down

0 comments on commit e391cc3

Please sign in to comment.