Elvas Tower: Wait Points - Wait Until Activation Level - Elvas Tower

Jump to content

  • 2 Pages +
  • 1
  • 2
  • You cannot start a new topic
  • You cannot reply to this topic

Wait Points - Wait Until Activation Level Rate Topic: -----

#1 User is offline   scottb613 

  • Vice President
  • Group: Status: First Class
  • Posts: 2,973
  • Joined: 06-July 09
  • Gender:Male
  • Location:Downeast Maine (soon)
  • Simulator:ORTS
  • Country:

Posted 06 May 2018 - 05:19 AM

Hi Folks,

All of Carlos's work on the advanced wait points really add a whole new dimension of enjoyment to activities... One feature seems obviously missed (might be due to technical limitations) - - - could we have a wait point set until and event activation level (trigger) is set ? There are quite a few dark routes out there and it would make meets on a single track main much more realistic - wait until play gets to this point before AI will proceed... The other feature that I've thought of in the past is it would be nice if we had a location event that could be triggered by the presence of an AI train...

Just a suggestion - thanks for all you guys do...

Regards,
Scott

#2 User is offline   mirekkr 

  • Hostler
  • Group: Status: Active Member
  • Posts: 91
  • Joined: 18-January 15
  • Simulator:ORTS, MSTS
  • Country:

Posted 19 May 2018 - 10:07 AM

Excellent idea, Scott!
Some time ago, I was trying to resolve this scenario: After 2 hrs of driving, I'll need AI helpers to make it up the grade. They are waiting at a siding, and after I have arrived, they connect to my rear (works fine in OR). OK, but - what if I'm late?
This proposal of yours could solve this - in a perfect way. And more situations too.

Thnks and regards,
Mirek

#3 User is offline   Csantucci 

  • Member, Board of Directors
  • Group: Status: Elite Member
  • Posts: 6,986
  • Joined: 31-December 11
  • Gender:Male
  • Country:

Posted 19 May 2018 - 12:55 PM

In effect this seems to be a good idea. I have an activity where I have Mirek's problem too. You could open a Trello box for it, but I don't promise I'll have the possibility of implementing it.

#4 User is offline   scottb613 

  • Vice President
  • Group: Status: First Class
  • Posts: 2,973
  • Joined: 06-July 09
  • Gender:Male
  • Location:Downeast Maine (soon)
  • Simulator:ORTS
  • Country:

Posted 20 May 2018 - 07:58 AM

Hi Folks,

Thanks for the feedback - will send to Trello...

Regards,
Scott

#5 User is offline   Csantucci 

  • Member, Board of Directors
  • Group: Status: Elite Member
  • Posts: 6,986
  • Joined: 31-December 11
  • Gender:Male
  • Country:

Posted 21 May 2018 - 05:53 AM

I have created a blueprint here https://blueprints.l...-syncs-ai-train , and prepared a beta version.
Here the .dll files to be replaced within x.4137:
Newer version available
Here a trivial demo activity, in .apk format, for route USA1
Attached File  TesteventWP.zip (3.35K)
Number of downloads: 261
and here an extension activity file, to be decompressed in an Openrails subfolder within the Activities folder of route USA1
Attached File  TesteventWP_extension.zip (373bytes)
Number of downloads: 279

To check how the simple activity works, start it and select the Dispatcher Info HUD. You will see that the AI train has as expiration time for its WP 15:00:00.
When the player train reaches the platform of the station, an information message (triggered by a location event) is displayed. At the same time the expiration time of the WP is anticipated to about 12:02:00 or near value.
So in this case the feature is used to manage a passenger connection between the two trains, even if the player train is delayed.
Another use is that of an AI train coupling to the player train, either to act as helper or to couple or uncouple wagons.

Here is the extension activity file available above
SIMISA@@@@@@@@@@JINX0a0t______

Tr_Activity (
	Tr_Activity_File (
		Events (
			EventCategoryLocation (
				ID ( 1 )
				ORTSContinue ( 3 )
				Outcomes (
					ORTSRestartWaitingTrain (
						ORTSWaitingTrainToRestart ( "TesteventWP_AI" )
							ORTSDelayToRestart ( 60 )
							ORTSMatchingWPDelay ( 31500 )
							)
				)
			)
		)
	)
)

The ORTSRestartWaitingTrain outcome has three parameters:
ORTSWaitingTrainToRestart contains the service name of the AI train to restart
ORTSDelayToRestart contains the delay in seconds from actual time to restart of the AI train (expiration time of the WP); it may also be equal to zero;
ORTSMatchingWPDelay contains the original delay of the WP as inserted e.g. with the MSTS AE, and is used to guarantee a correct match.

Notes:
the AI train must be already waiting when the player train hits the event;
if the WP is of absolute type (like the one in the example) OR adds the delay to restart to the actual clock time, rounds it up to the next full minute and sets it as new expiration time. If the WP is standard, rounding does not occur;
the ORTSRestartWaitingTrain block may alternatively be added to the base .act file (the one in the Activities folder), however in this case the addition is lost, if the activity is modified by tne MSTS AE.

I hope that TSRE5 will manage this addition in a near future.

#6 User is offline   scottb613 

  • Vice President
  • Group: Status: First Class
  • Posts: 2,973
  • Joined: 06-July 09
  • Gender:Male
  • Location:Downeast Maine (soon)
  • Simulator:ORTS
  • Country:

Posted 21 May 2018 - 06:25 AM

Hi Carlos,

Holy smokes - that was fast - I'll give it a shot as soon as I am able - I know your plate is MORE than full around here - much appreciated - sir...

Regards,
Scott

#7 User is offline   mirekkr 

  • Hostler
  • Group: Status: Active Member
  • Posts: 91
  • Joined: 18-January 15
  • Simulator:ORTS, MSTS
  • Country:

Posted 21 May 2018 - 02:52 PM

Thanks, Carlo!

I did some tests:
- my "helper problem" is 100% solved. I tried standard WP, absolute WP, and even steal-cars WP - ok.
- your activity works also fine.
But situation gets a little tricky if your AI-Acela train has a scheduled station stop at Baltimore:
If I'm arriving in time, the AI train sits on the station (AI status = STA) and therefore it is not at the WP, that means the WP is not reset.
Where to put the WP for the AI?
- if you place it after the station stop, and I'm not late, the AI will wait at the WP till 15:00 (in your act)
- if you place it before the station stop, and I'm late, the AI will wait before the station - thus, it is late too
So, we have to be careful and not use station stop and WP-reset feature simultaneously.

Anyway, I'm really happy about this new feature! I'll do more tests next days...

Once again - thanks!
Mirek

#8 User is offline   Csantucci 

  • Member, Board of Directors
  • Group: Status: Elite Member
  • Posts: 6,986
  • Joined: 31-December 11
  • Gender:Male
  • Country:

Posted 21 May 2018 - 11:20 PM

Mirek,
that's good.
As I wrote in my post above, the AI train must be already at the WP when the player train triggers the event.
I am already considering whether to remove, at least partially, this restriction (if not too complex). Can you attach here the modified test activity where the WP isn't yet touched by the AI train when it stops for a station stop?

#9 User is offline   mirekkr 

  • Hostler
  • Group: Status: Active Member
  • Posts: 91
  • Joined: 18-January 15
  • Simulator:ORTS, MSTS
  • Country:

Posted 23 May 2018 - 10:29 AM

Hi Carlo,
see attachment (this is one of more possibilities I've tried).
The WP for AI-Acela is placed between station marks, and is set to wait until 15:00.
AI starts at 11:55 and has a scheduled stop here: 11:57 to 11:59.
To see what I wrote about, stop the player train before you enter the Baltimore station and wait till the AI occurs; then continue to your station stop (this simulates arriving later).
Now - F5 displays "STA" for the AI (it is loading passengers). After having done, it proceeds to the WP, which is set at 15:00 absolute time. And it will rust here until 15:00 :-)

As for your idea of removal of the restriction: wouldn't it be enough to modify depart time in the same way as the WP time? In this case, no WP would be needed, but the Location event should refer Station/Platform name. (This sounds a bit crazy.)

Regards,
Mirek

Attached File(s)



#10 User is offline   Csantucci 

  • Member, Board of Directors
  • Group: Status: Elite Member
  • Posts: 6,986
  • Joined: 31-December 11
  • Gender:Male
  • Country:

Posted 31 May 2018 - 08:50 AM

I improved the feature. Now it is able to modify the WP value even if the WP isn't yet reached by the AI train, and is still running towards it or stopped, but with no other stops in between.
Here are the revised .dll files to replace within x.4141


Here a demo activity, in .apk format, for route USA1
Attached File  testeventwp_longerpath.zip (3.71K)
Number of downloads: 258
and here the extension activity file, to be decompressed in the Openrails subfolder within the Activities folder of route USA1
Attached File  TesteventWP_longerpath_extension.zip (409bytes)
Number of downloads: 283

Running the activity regularly the player train reaches the Baltimore station, and the location event, before the AI train. Therefore the AI train arrives, makes its regular stop and then immediately restarts.
If instead the player train is stopped before the Baltimore station, and the AI train arrives and makes the station stop, when the passenger loading time expires the WP enters in action, and the AI train restarts only when the player train is restarted and passes the location event.

2/6/2018: .dll files removed because feature committed

  • 2 Pages +
  • 1
  • 2
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users