Bug #2153

tubular brigde

Added by alocritani almost 7 years ago. Updated almost 2 years ago.

Status:ClosedStart date:2011-01-11
Priority:LowDue date:
Assignee:-% Done:

100%

Category:-
Target version:-

Description

the silver tubular bridge has gray track and gray ground "inside" the bridge

tubular_bridge.png (12.5 KB) alocritani, 2011-01-11 11:47

recolour_struct_concrete.diff Magnifier (2.37 KB) foobar, 2011-08-09 13:19

recolour_change_example.png (68.2 KB) foobar, 2011-08-09 13:19

tubebridge.png (42.2 KB) planetmaker, 2011-12-17 21:46

Associated revisions

Revision 650:7f9b4e3f1050
Added by planetmaker over 6 years ago

Fix #2153: Wrong, untranslated colour in some bridge GUI sprites
Note: The main issue of #2153 has been fixed in OpenTTd r22378 - r22380

Revision 650:7f9b4e3f1050
Added by planetmaker over 6 years ago

Fix #2153: Wrong, untranslated colour in some bridge GUI sprites
Note: The main issue of #2153 has been fixed in OpenTTd r22378 - r22380

History

#1 Updated by Ammler almost 7 years ago

and what is wrong about?

#2 Updated by alocritani almost 7 years ago

not wrong, but strange, all other bridges have brown ground near tracks. why this one should be gray?

#3 Updated by athanasios almost 7 years ago

Well it is a gray bridge...
What is really inconsistent or 'wrong' is that the heads of the bridge remain the same color with the other tubular bridges. They should be gray too. They simply don't fit.

#4 Updated by Ammler almost 7 years ago

so this would need new sprites?

#5 Updated by planetmaker over 6 years ago

  • Assignee set to planetmaker
  • Target version set to 0.3.4

#6 Updated by planetmaker over 6 years ago

It's an OpenTTD issue it seems; it also happens with the original base set...

#7 Updated by planetmaker over 6 years ago

Differences must be found between recolour sprites 0x321 and 0x323

static const PaletteID PALETTE_TO_STRUCT_YELLOW = 0x321; // Sets the bridge colour to yellow (suspension and tubular)
static const PaletteID PALETTE_TO_TRANSPARENT = 0x322; // This sets the sprite to transparent
/* This is used for changing the tubular bridges to the silicon display, or some grayish colour */
static const PaletteID PALETTE_TO_STRUCT_GREY = 0x323;

#8 Updated by planetmaker over 6 years ago

  • Status changed from New to Closed
  • % Done changed from 0 to 100

Applied in changeset 7f9b4e3f1050.

#9 Updated by planetmaker over 6 years ago

  • Status changed from Closed to Reopened
  • % Done changed from 100 to 80

The silicon bridge still has a few untranslated pixels in the / view. Check also the pillars.

#10 Updated by foobar over 6 years ago

  • Target version changed from 0.3.4 to 0.3.5

#11 Updated by foobar over 6 years ago

It came to my attention that PALETTE_TO_STRUCT_YELLOW translates all 10 "bridge-brown" colours, while PALETTE_TO_STRUCT_CONCRETE only translates the middle 8 of those colours. This is basically the reason why the tubular bridge works fine in yellow, but shows ugly brown pixels in grey.

One solution could be to repaint the bridge and loose some detail such that it only uses 8 colours. The other (IMO correct) solution would be to modify the colour translation table to actually translate all 10 "bridge-browns" to concrete-ish colours, like yellow does.
A patch to this extent is attached, as well as a screenshot showing how the bridge looks now and how it will look with the patch applied.

It has to be noted that other OpenGFX sprites (as well as third party NewGRFs) possibly rely on the outer two brown colours not being translated. If that is actually the case is not too easy to establish.
We could go ahead and apply this patch and announce the change at the forums. If no bugreports pop up and nobody else complains about the new behaviour we can leave it in, otherwise we have to resort to repainting the bridge. If no problems occur, I'm in favour of applying this also in OpenTTD's "fix TTD sprites".

#12 Updated by planetmaker over 6 years ago

Well, cannot change the recolour sprites, as that needs to be a base set independent sprite or the colour translation result will be different on different base sets... except we fix the openttd.grf as well...

It actually can be argued that the default recolour sprites could be taken out of the base sets for this reason, but that seems to be not be worth the trouble... tmwftlg

#13 Updated by planetmaker over 6 years ago

  • Target version changed from 0.3.5 to 0.4.0

#14 Updated by planetmaker almost 6 years ago

  • Assignee deleted (planetmaker)
  • Target version deleted (0.4.0)

#15 Updated by planetmaker almost 6 years ago

It's not only colour... one bridge end sprite seems broken:

#16 Updated by planetmaker over 5 years ago

  • Status changed from Reopened to Closed
  • % Done changed from 80 to 100

Applied in changeset 7f9b4e3f1050.

#17 Updated by Ammler over 5 years ago

  • Status changed from Closed to Reopened
  • % Done changed from 100 to 80

closed during refetch of redmine update

#18 Updated by planetmaker almost 2 years ago

  • % Done changed from 80 to 100
  • Status changed from Reopened to Closed

Applied in changeset opengfx-dev:opengfx-dev|commit:7f9b4e3f1050.

Also available in: Atom PDF