Hi there,
And my apologies for having to ask for help. I have been wanting to create a simple train track scenario with many track junctions and a bidirectional behaving train with no train cars but the ability to go in any direction. First thing I noticed is that the example E12 is designed for one way operation only because I tried to, and it just would not work in reverse direction with a second controllable junction. I was hoping that E12 example was using a generic train controller I could use but it does not appear to work. So, I have attempted to create my own solution based on your scripts, but I have hit a snag! I have managed to get the train controller to behave correctly when a junction is only made up of 2 connected splines but anything more than 2 (3+) then I get odd behaviours in track selection. I am not the best coder and I am sure it is my fault but any advice you can give would be appreciated.
I have attached a document with some pictures and text to help explain the two scenarios that I have been testing.
E12 Track Junction testing.docx (Size: 942.76 KB / Downloads: 4)
I know that the solution is to not use any more than 2 splines but there are going to be situations where I need to have more than 2 connections and I need to figure out how to get the train to work generically for any number of connections, within reason ofc.
If you could read my doc and then give me some pointers or maybe there is already a generic train controller on the forum that has already been written?
Thanks.
Dan
And my apologies for having to ask for help. I have been wanting to create a simple train track scenario with many track junctions and a bidirectional behaving train with no train cars but the ability to go in any direction. First thing I noticed is that the example E12 is designed for one way operation only because I tried to, and it just would not work in reverse direction with a second controllable junction. I was hoping that E12 example was using a generic train controller I could use but it does not appear to work. So, I have attempted to create my own solution based on your scripts, but I have hit a snag! I have managed to get the train controller to behave correctly when a junction is only made up of 2 connected splines but anything more than 2 (3+) then I get odd behaviours in track selection. I am not the best coder and I am sure it is my fault but any advice you can give would be appreciated.
I have attached a document with some pictures and text to help explain the two scenarios that I have been testing.
E12 Track Junction testing.docx (Size: 942.76 KB / Downloads: 4)
I know that the solution is to not use any more than 2 splines but there are going to be situations where I need to have more than 2 connections and I need to figure out how to get the train to work generically for any number of connections, within reason ofc.
If you could read my doc and then give me some pointers or maybe there is already a generic train controller on the forum that has already been written?
Thanks.
Dan