J Yelland Signal Scripts

J Yelland Signal Scripts

Postby Auscgu » Tue Mar 29, 2022 1:18 am

Andis,
I have been helping with signals for the NWC LMS 1930s route.
The route uses J Yelland signals and also A Brailsford LNWR signals.
The LNWR signals have been converted to J Yelland scripts to keep a common script for all the signals on the route.

The issue is when you add a extra route with a common arm the arm will not active for both routes.
The first route to use the arm will active and close, but the second will not.
If you change away and active the other route first then the arm works.
The GArmTable below


Code: Select all
--------------------------------------------------------------------------------------
-- COMBINED Home / Home / Home2 / Home Semaphore Signal with 5 routes
--------------------------------------------------------------------------------------

--include=Common UK Semaphore.lua
--include=CommonScripts\Common UK Semaphore Script - Multiple Routes.lua
--include=..\CommonScripts\New Common Signal Script.lua

--------------------------------------------------------------------------------------
-- INITIALISE
--
function Initialise ()

   -- Initialise signal as having 5 route indications
   DefaultInitialise(5)   -- Number must match highest index below
   
   -- Set arm anim names
   gArmTable[1][ARM_HOME][SEM_CHILD_NAME]      = "1Main"
   gArmTable[1][ARM_HOME][SEM_PROCEED_ANIM]   = "Clear01"
   gArmTable[1][ARM_HOME][SEM_BLOCKED_ANIM]   = "Stop01"

   gArmTable[2][ARM_HOME][SEM_CHILD_NAME]      = "2Main"
   gArmTable[2][ARM_HOME][SEM_PROCEED_ANIM]   = "Clear02"
   gArmTable[2][ARM_HOME][SEM_BLOCKED_ANIM]   = "Stop02"

   gArmTable[3][ARM_HOME][SEM_CHILD_NAME]      = "3Main"
   gArmTable[3][ARM_HOME][SEM_PROCEED_ANIM]   = "Clear03"
   gArmTable[3][ARM_HOME][SEM_BLOCKED_ANIM]   = "Stop03"

   gArmTable[4][ARM_HOME][SEM_CHILD_NAME]      = "3Main"
   gArmTable[4][ARM_HOME][SEM_PROCEED_ANIM]   = "Clear03"
   gArmTable[4][ARM_HOME][SEM_BLOCKED_ANIM]   = "Stop03"

   gArmTable[5][ARM_HOME][SEM_CHILD_NAME]      = "5Main"
   gArmTable[5][ARM_HOME][SEM_PROCEED_ANIM]   = "Clear05"
   gArmTable[5][ARM_HOME][SEM_BLOCKED_ANIM]   = "Stop05"

end
Auscgu
Passed Fireman
 
Posts: 133
Images: 50
Joined: Sat Oct 21, 2017 11:04 am
Has thanked: 12 times
Been thanked: 17 times

Re: J Yelland Signal Scripts

Postby AndiS » Tue Mar 29, 2022 8:09 am

For all I remember the Kuju scripts perform the open animation and the close animation at the same time. Therefore, you cannot do the trick with double entries in gArmTable that you can do with my scripts.

I confess that I did not check right now. I only remember a load of problems that I got because of my approach and that I got over them using a load of tricks, because I wanted it to look as if one guys operates one lever after the other.

It is much simpler to wait until the new path is established and then put all the arms into their new position.

Plus my approach depends on the animation time of the switches being greater or equal the animation time of the signal arms to look good.

Remember the problems we have with my scripts and diamonds. That is because the diamonds do not have this animation between "old path broken" and "new path set".
AndiS
Top Link Driver!
 
Posts: 736
Joined: Wed Apr 09, 2014 5:48 pm
Has thanked: 268 times
Been thanked: 308 times


Return to Route Creation

Who is online

Users browsing this forum: No registered users and 2 guests