Closed mattuntergassmair closed 4 years ago
Fancy! what kind of colors does that give us?
Fancy! what kind of colors does that give us?
I guess we can be arbitrarily specific about the colors we want, right now I've done the following: For every color channel (R, G, B), the value is determined as .3 + .7x
where x
are some bits from the id-hash and .3 is a minimum value, so the "darkest" possible color is RGB(.3,.3,.3)
.
Is it good to merge?
The current
add_renderable!
function for theEntity
type uses a randomized color, which differs in every function call and leads to inconsistent colors between time frames. This PR bases the color randomization on the hash of the entityid
and is therefore consistent for vehicles with the same id.