New Track Object: play the bell for some time

ffccnn

New member
This is a new trigger that when activated by a train it will ask the train to play the bell for some time.

The time to play the bell is specified in seconds.
The trigger can be active based on train priority.

This is the configuration screen that you would invoke with the ? buttton from the track object tab in surveyor.
I added a label to see in Driver where the trigger was located which you can see in the video below. The label is not part of the trigger it is there only for the demo.


Uploaded with ImageShack.us

As you can see I am borrowing some gadges from existing assets (the green trigger and the check marks) (owners are Auran and Boat) and until I get their permission I won't be able to upload it.

Here is the demo: http://youtu.be/Ppk_UZhInHo

cheers,

José
 
Last edited:
Very cool! When you get permission, I will download these. They will be good for trains exiting stations or approaching crossings. Nice work!
 
Very cool! When you get permission, I will download these. They will be good for trains exiting stations or approaching crossings. Nice work!

what the heck, I modified the interface to eliminate those dependencies, now it is not too fancy but it's functional, no black letters on dark green background and greasy-bifocals friendly :hehe:



Uploaded with ImageShack.us
 
I upload this new trigger using the same model as the built-in provided by the game (the green trigger), I am doing my own model in Blender now and I will update it once it's ready.

BellTrigger.cdp
Date Received: 24th Dec 2012, 03:01:12 (AEST)
Upload Mode: Standard
Waiting to be Processed.


Merry Christmas to all


José
 
Last edited:
A small request or suggestion: Can you make an option to play the horn too? In Europe trains don't use bells, but have a combination of "toot's" (as in N. America), when doing different things; Ie: Crossings, station departure, etc. That would be very cool. Thanks.
 
please do i needed something like this for ages,i to was fed up with inserting "horn"many times and it wasn't continuus be great to hear the steam loco's on the whistle whilst flying through stations,will keep my eye open for further anouncments......well done
 
please do i needed something like this for ages,i to was fed up with inserting "horn"many times and it wasn't continuus be great to hear the steam loco's on the whistle whilst flying through stations,will keep my eye open for further anouncments......well done

Did you try the new Driver Command HornzExtended on one of your steam locos? it may be what you need.

To be honest, I didn't test it on a steam engine, oops :eek:


Converting that driver command to a trigger is not too hard and I am planning to do it soon.


Merry Christmas
 
Ok, I finished the model for this new trigger after some cups of coffee and many web pages of Blender :clap:
I am very happy with what I am learning, nice IMHO


Uploaded with ImageShack.us
 
This will be very useful! It's prototypical around here for trains to ring the bell as they pull into a station. I'm downloading it now and will see if I can configure it to ring long enough while entering a station in my layouts. Another prototypical behavior is to run the ditch lights along with the bell. The reskinned P42 loco I use has a working ditch light function. Would it be possible to make this switch to also activate the ditch lights along with the bell? I know everyone is making requests of you now! But this is a really useful tool. Thank you!
 
sure, good idea but first I would have to figure out how to turn the ditch lights on/off...

yeah! got it, see here: http://youtu.be/DqN4kobbiMw

There is a note in the game code that says:

Code:
 // Note: 
 //     When the headlights of a train are switched on, only the front locomotive's headlights
 //     will actually be visibly switched on and affect the world in %Trainz.

I don't know what they mean by that but I observed that the ditch lights do not always flash, go figure it out.

Happy new year

--José
 
I just wanted to drop a note to say that I finally got to try the bell trigger and it worked great. Figuring out the proper length of time to have it on so it stops when the train stops at the platform took some trial and error, but it's working well.

I'm not sure what you mean by the posting about the game code? Is this something I can change at my end? Or something you configure in the trigger?

Anyway, thank you!
 
yeah! got it, see here: http://youtu.be/DqN4kobbiMw

There is a note in the game code that says:

Code:
 // Note: 
 //     When the headlights of a train are switched on, only the front locomotive's headlights
 //     will actually be visibly switched on and affect the world in %Trainz.

I don't know what they mean by that but I observed that the ditch lights do not always flash, go figure it out.

Happy new year

--José

Jose,

If you are using a "SendMessage" command, you can use the command "ditchlight" to activate/deactivate the ditchlights.

This does not work on any JR trains I own so far, but I believe that is because the JR train ditchlights are actually programmed and therefore do not respond to the command.

Thanks for taking the time to help out the community, I know there are a bunch of folks that appreciate the effort.

Travlar
 
Last edited:
Jose,

If you are using a "SendMessage" command, you can use the command "ditchlight" to activate/deactivate the ditchlights.

This does not work on any JR trains I own so far, but I believe that is because the JR train ditchlights are actually programmed and therefore do not respond to the command.

Thanks for taking the time to help out the community, I know there are a bunch of folks that appreciate the effort.

Travlar

Hi Travlar,

I didn't find in the TS12 game code any reference to a SendMessage (or PostsMessage) for a major "ditchlight", all I found was this list:

Code:
 In vehicle.gs
// Vehicle object messages:
// {[ Major      | Minor        | Source             | Destination  | Description                                      ]
//  [ "Vehicle"  | "Derailed"   | derailed vehicle   | broadcast    | Vehicle has derailed and can no longer be used.  ]
//  [ "Vehicle"  | "Coupled"    | coupled vehicle    | broadcast    | Vehicle has coupled up with another vehicle.     ]
//  [ "Vehicle"  | "Decoupled"  | decoupled vehicle  | broadcast    | Vehicle has decoupled from another vehicle.
//                                                                    This message is not currently functional in 
//                                                                    <bi TS2006>.                                     ]
//  [ "Vehicle"  | "BadCouple"  | coupled vehicle    | broadcast    | Vehicle has coupled with another vehicle at too
//                                                                    high a velocity.                                 ]
//  [ "Vehicle"  | "Collided"   | collided vehicle   | broadcast    | Vehicle has collided with another vehicle.       ]}
/

Code:
 In train.gs

// {[ Major       | Minor                         | Source  | Destination  ]
//  [ "Train"     | "Over speed limit"            | train   | broadcast    ]
//  [ "Train"     | "Under speed limit"           | train   | broadcast    ]
//  [ "Train"     | "Over advisory speed limit"   | train   | broadcast    ]
//  [ "Train"     | "Under advisory speed limit"  | train   | broadcast    ]
//  [ "Train"     | "Over floating speed limit"   | train   | broadcast    ]
//  [ "Train"     | "Under floating speed limit"  | train   | broadcast    ]
//  [ "Train"     | "StoppedMoving"               | train   | train        ]
//  [ "Train"     | "StartedMoving"               | train   | train        ]
//  [ "Train"     | "Entered red signal"          | signal  | train        ]
//  [ "Train"     | "Entered red signal notify"   | train   | broadcast    ]
//  [ "Train"     | "EnterTrack"                  | track   | train        ]
//  [ "Train"     | "InnerEnterTrack"             | track   | train        ]
//  [ "Train"     | "InnerLeaveTrack"             | track   | train        ]
//  [ "Train"     | "LeaveTrack"                  | track   | train        ]
//  [ "Train"     | "SlowingForTarget"            | train   | train        ]
//  [ "Schedule"  | "Complete"                    | train   | broadcast    ]
//  [ "Schedule"  | "Abort"                       | train   | train        ]
//  [ "Schedule"  | "Touch"                       | train   | train        ]}

Do you have the documentation for sending a message to turn on/off the ditchlights?
I'd need the specific major (and minor) so please let me know about it.

I am using the methods provided by the game interface such as


Code:
 public native bool GetDitchlightState(void);
 public native void SetDitchlightState(bool lightsFlashing);
 public native bool HasDitchlight();

thanks for your comments,

--José
 
Back
Top