Lighting definitions
#11
Posted 04 February 2015 - 01:42 PM
So apart from Headlight(7) not being implemented, I can't see any issues here.
Edit: Unless the MSTSBin manual is wrong, of course.
#12
Posted 04 February 2015 - 07:00 PM
#13
Posted 04 February 2015 - 07:05 PM
Should be, and works in MSTS.
key “h” is not pressed = OFF
key “h” is one time pressed = ON
key “h” is two times pressed = ON
Cheers Ross
#14
Posted 04 February 2015 - 07:37 PM
James Ross, on 01 February 2015 - 05:08 AM, said:
- 0: Ignore
- 1: Off
- 2: Dim
- 3: Bright
- 4: Dim or bright (MSTSBin)
- 5: Off or dim (MSTSBin)
- 6: Off or bright (MSTSBin)
There's one more value, which MSTSBin labels as "DimBright", which we don't implement because the MSTSBin manual isn't clear on how it works.
As far as I can see, all of the values listed above work in Open Rails. If you don't think they are, you need to very clearly specify which cases are not working - it is not possible to tell from your post what you are actually testing.
James, looking at this thread it has become apparent to me that there are two different things going on in this one parameter and that is:
- The starting condition of the lamp.
- The sequence of keystrokes.
IMO there is no sense trying to change anything before 1.0 but longer term it would make sense to change the parameter list in Light() to separate these two data with the keystroke sequence being relevant when the player is in control (several possible combinations) and the starting condition being relevant to both AI and player controlled locomotives (probably being off, dim, and full). I think it would make sense to call the later parameter Headlight() or HeadlightAtStart() if you want and then something entirely new for the other parameter name.
For AI trains Headlight() would be the only in-game setting. For player's trains Headlight() will start as specified and then whatever Keystroke set was specified would be granted to the player to execute as needed.
#15
Posted 05 February 2015 - 02:54 AM
rosssweet, on 04 February 2015 - 07:00 PM, said:
Should be, and works in MSTS.
key “h” is not pressed = ON
key “h” is one time pressed = ON
key “h” is two times pressed = OFF
Ross
If that is a Headlight(6) working correctly then the MSTSBin manual is wrong. However, I am concerned that something else is wrong or interfering here because you said originally that Headlight(1) doesn't work - and that's a basic MSTS value which I confirmed works as documented: it's only visible when the headlight is off.
I'm going to run my test locomotive in MSTSBin at the weekend and see what I find, until then there's no point doing anything.
Genma Saotome, on 04 February 2015 - 07:37 PM, said:
I suspect we could get away with making AI have the headlight off during the day and bright during night, in the mean time. Not sure what MSTS does but we should probably stop having AI headlights on during the day by default. :rotfl:
#16
Posted 05 February 2015 - 03:37 AM
James Ross, on 05 February 2015 - 02:54 AM, said:
In Hungary the headlight must be switched on at daylight too, so there might be a option added for this.
#17
Posted 05 February 2015 - 04:15 AM
Looks like we are on the same page now.
Checked Headlights, (0) to (4) correct. Except
Headlight (5)
Should be, and works in MSTS.
key “h” is not pressed = ON
key “h” is one time pressed = OFF
key “h” is two times pressed = ON
In OR X2833 not matching MSTS
key “h” is not pressed = ON
key “h” is one time pressed = ON
key “h” is two times pressed = OFF
Headlight (6)
Should be, and works in MSTS.
key “h” is not pressed = ON
key “h” is one time pressed = ON
key “h” is two times pressed = OFF
In OR X2833 not matching MSTS
key “h” is not pressed = ON
key “h” is one time pressed = OFF
key “h” is two times pressed = ON
Headlight (7)
Should be, and works in MSTS.
key “h” is not pressed = OFF
key “h” is one time pressed = ON
key “h” is two times pressed = ON
In OR X2833 not matching MSTS
key “h” is not pressed = OFF
key “h” is one time pressed = OFF
key “h” is two times pressed = OFF
Thanks a lot, Cheers Ross
James Ross, on 05 February 2015 - 02:54 AM, said:
I'm going to run my test locomotive in MSTSBin at the weekend and see what I find, until then there's no point doing anything.
#18
Posted 05 February 2015 - 04:39 AM
gpz, on 05 February 2015 - 03:37 AM, said:
Hmm, maybe. I'll see if I can see what MSTS(Bin) does, so we can default to that for MSTS content.
rosssweet, on 05 February 2015 - 04:15 AM, said:
Headlight (5)
Headlight (6)
Okay, it looks like 5 and 6 are backwards because the MSTSBin manual is wrong:
Quote
Headlight (5) = Headlight (1) + Headlight (2) = Off + Dim
Headlight (6) = Headlight (1) + Headlight (3) = Off + Bright
I'll test this out to confirm and we can then update Open Rails to match.
#19
Posted 05 February 2015 - 11:33 AM
gpz, on 05 February 2015 - 03:37 AM, said:
There is already a parameter in Light() that controls when and surprise surprise! it is called TimeOfDay().
As a side note, AFAIK, most railroads in the US did not require headlights to be on until the arrival of diesel road locomotives... and not even at the start but a bit later I don't know if the change was mandated by the government of the railroads figured out that they had been relying on a plume of steam exhaust as a warning and that wasn't there anymore.
#20
Posted 05 February 2015 - 12:50 PM
Genma Saotome, on 05 February 2015 - 11:33 AM, said:
It is a rule here for trains and also for all road cars outside cities to have headlights always on while moving, even at summer noon in sunshine. By statistics it considerably reduced the number of accidents, at least in case of cars. :shock6: