@@ -318,6 +318,79 @@ for the purposes of calculation.
318318- ``MU ( 3 ) `` Locomotive must be in a different group to the lead locomotive
319319
320320
321+ Multiple type locomotive light glows
322+ ------------------------------------
323+
324+ Introduction
325+ ''''''''''''
326+
327+ As a default all OR (and MSTS) locomotives use the same texture to reproduce
328+ the glow of their lights. This however doesn't allow to easily implement non-round
329+ or LED array lights, neither to provide special glowing effects.
330+
331+ This feature allows to specifiy customized light glow textures for the locomotives.
332+ If nothing is specified, the standard light glow texture is used. Moreover in the ``Content ``
333+ folder, two light glow textures are present: the "historical" one, and a new one,
334+ more realistic. As a default the "historical" light glow texture is used, for backwards
335+ compatibility; however adding a line to the Lights block in the .eng file the "new" light
336+ glow texture is taken. Customized light glow textures can be either used for all lights
337+ of a loco, or only for a subset of them. Different lights in the same locomotive
338+ may have different customized light glow textures.
339+
340+ Detailed spec
341+ '''''''''''''
342+
343+
344+ 1) In the ``Content `` folder there is the default ``LightGlow.png ``, which is displayed if
345+ no changes are done to the .eng file.
346+ 2) In such folder there is also an ``ORTSLightGlow.png ``, which is maybe more realistic.
347+ 3) adding a line within the .eng file it is possible to select either ORTSLightGlow.png or any other .png.
348+ Here an example for the legacy Acela loco::
349+
350+ Lights ( 17
351+ ORTSGraphic ( "ORTSLightGlow.png")
352+ Light (
353+ comment( Sphere of light )
354+ Type ( 1 )
355+ Conditions (...
356+
357+ The code first searches for the .png file by building its directory starting from the directory of
358+ the .eng file; in this case the line could be e.g.::
359+
360+ ORTSGraphic ( "ORTSAcelaLightGlow.png")
361+
362+ 4) The ``ORTSGraphic `` line can be added also for one or more ``Light() `` blocks. In that case the
363+ .png file is used only for the related Light block. Here an example::
364+
365+ Light (
366+ comment( Head light outer right bright )
367+ Type ( 0 )
368+ Conditions (
369+ Headlight ( 3 )
370+ Unit ( 2 )
371+ )
372+ FadeIn ( 0.5 )
373+ FadeOut ( 0.5 )
374+ Cycle ( 0 )
375+ States ( 1
376+ State (
377+ Duration ( 0.0 )
378+ LightColour ( ffffffff )
379+ Position ( -0.5922 2.4037 9.63208 )
380+ Azimuth ( 0.0 0.0 0.0 )
381+ Transition ( 0 )
382+ Radius ( 0.60 )
383+ Elevation ( -50 -50 -50 )
384+ )
385+ )
386+ ORTSGraphic (BigLightGlow.png)
387+ )
388+
389+ OR searches for the file as it does for the general file for all lights, as explained above.
390+ If the ``ORTSGraphic `` line is present both at the top of the ``Lights() `` and also in some
391+ ``Light() `` subblock, the line present in the subblock prevails. So it is possible to have an
392+ .eng-specific graphic for all the lights, except the ones that have an own ``ORTSGraphic `` line.
393+
321394
322395Tilting trains
323396==============
0 commit comments