Page 1 of 1

Access to "corrected" player chat color.

Posted: Thu Oct 04, 2018 9:52 am
by eradicator
Since chat color is now edited for better contrast it's no longer possible to print chat messages in the player color via lua. I tried default/red/green and they all produce different color output.

Code: Select all

hi!
/c game.print('eradicator: hi!', game.player.color)
Here's an example picture chat vs command:
color.png
color.png (48.96 KiB) Viewed 1670 times
As i'd also like to show the player name in custom GUIs it would be nice to have access to the "corrected" color, either via player.high_contrast_color or via exposing the correction in e.g. util.fix_chat_color.

Re: Access to "corrected" player chat color.

Posted: Thu Oct 04, 2018 9:59 am
by Klonan

Re: Access to "corrected" player chat color.

Posted: Thu Oct 04, 2018 10:07 am
by eradicator
Hrrng...please wait while i grab a shovel to dig a hole.
Thanks.