News:

Simutrans Sites
Know our official sites. Find tools and resources for Simutrans.

r11737: Ticker messages in player color have rendering issues

Started by Nazalassa, August 10, 2025, 09:06:33 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Nazalassa

When the ticker bar appears because of a new message, the first few pixels of that new message are colored black instead of the correct player color (if it is in a player's color).

Steps to reproduce:
  • Use a player which player color is not black (e.g orange).
  • Rename a vehicle so that its name starts with a big character (e.g # or B or M), to see the bug well.
  • Ensure the ticker bar is hidden! The bug only happens for messages that trigger the ticker bar.
  • Send it to a depot.
  • Look at the message that appears in the scrolling ticker above the status bar.

Expected results:
The ticker message should be fully written in the primary player color

Observed results:
The ticker message is written in the player color, except for the first few pixels.

ticker-color-bug.png

Attached is a patch that fixes the bug: when the ticker appears, it does not check whether the message's color is a player color or not (and assumes it is a regular color).
Making paksets since October 2023  |  pak48.bitlit | pak32.box | MLM for pak64 | Empire F7 cars

Life is like a multi-tasking OS: you know you'll eventually get back to everything, but you don't know when.

FLN

Occasionally it is not only that one strike of the first letter, but ~20% of the text's beginning part.

Nazalassa

Quote from: FLN on August 10, 2025, 11:40:58 AMOccasionally it is not only that one strike of the first letter, but ~20% of the text's beginning part.

From what I could read from the code, it affects the part of the text that is shown on the very first frame the ticker appears (and only that part). So if simutrans freezes, the message can be already quite far away by the time the ticker appears and its first frame is drawn...
Making paksets since October 2023  |  pak48.bitlit | pak32.box | MLM for pak64 | Empire F7 cars

Life is like a multi-tasking OS: you know you'll eventually get back to everything, but you don't know when.