Fix IDE0075
This commit is contained in:
committed by
Pavel Penev
parent
3402031399
commit
99c289e063
@@ -89,7 +89,7 @@ namespace OpenRA.Mods.Common.Traits
|
||||
|
||||
// Check if color has a (valid) alpha value.
|
||||
// Note: We can't throw on "rgba.Length > 3 but parse failed", because in GIMP palettes the 'invalid' value is probably a color name string.
|
||||
var noAlpha = rgba.Length > 3 ? !byte.TryParse(rgba[3], out a) : true;
|
||||
var noAlpha = rgba.Length <= 3 || !byte.TryParse(rgba[3], out a);
|
||||
|
||||
// Index should be completely transparent/background color
|
||||
if (i == TransparentIndex)
|
||||
|
||||
Reference in New Issue
Block a user