How to make "4.5/5 stars", etc. into a GUI?

I have a rating system for player avatars in my game but I wanted to have it display the average rating for each avatar as well (for example, 0.5 of a star) I currently just have it display it in whole number increments because as far as I’m concerned there isn’t any masking feature for Roblox GUIs or anything similar.

If anyone has any ideas let me know

Example of current avatar rating screen: (ignore glitched favorites button lol)

How does the Star turn yellow do you use image color or another image?

To make 4.5 Stars use UIGradient

Example Script:

UIGradient.Color = ColorSequence.new({
	ColorSequenceKeypoint.new(0, Color3.new(1, 1, 0)),
	ColorSequenceKeypoint.new(0.5, Color3.new(1, 1, 0)),
	ColorSequenceKeypoint.new(0.51, Color3.new(0.392157, 0.392157, 0.392157)),
	ColorSequenceKeypoint.new(1, Color3.new(0.392157, 0.392157, 0.392157)),
})

You just need to change the offset of the gradient. Changing the entire ColorSequence is less efficient and more tedious.

3 Likes

I’m not the best with UI’s I knew there was a better way to do it, lol

Wow super helpful never thought of using a uigradient haha

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.