-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Refactors ColorTags #9
base: master
Are you sure you want to change the base?
Conversation
Fix indentation.
Engine/src/mini/font/ColorTags.java
Outdated
color.a = Integer.parseInt(colorStr.subSequence(6, 8).toString(), 16) / 255f; | ||
} | ||
readHexColor(colorStr); | ||
return; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tabs
Engine/src/mini/font/ColorTags.java
Outdated
} else if (colorStr.length() == 4) { | ||
color.a = Integer.parseInt(Character.toString(colorStr.charAt(3)), 16) / 15f; | ||
} | ||
color.a = 0; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That is wrong, this needs to be a 1. If you look at how color.set was used previously.
Engine/src/mini/font/ColorTags.java
Outdated
} else if (colorStr.length() == 4) { | ||
readColorValue(colorStr, 3); | ||
} else { | ||
color.a = 0; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should be set to 1 otherwise we loose the color.
Engine/src/mini/font/ColorTags.java
Outdated
if (baseAlpha != -1) { | ||
color.a = baseAlpha; | ||
} else if (colorStr.length() == 4) { | ||
readColorValue(colorStr, 3); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you are forgetting to put color.a = readColorValue
No description provided.