/* called by: entrance ctrl of the object 'track'
4 P) l3 m1 a2 U: [0 n; N; M9 a2 H*/
) p# }. k. e" a. X: eis
) Y& v( E6 _$ F. T part, GlobalDistObj, assignLObj:object;row,Lan:integer;! B# |+ i* Z8 W, w8 i, ~' ^
do
+ t' Y O- x+ J9 a& j+ q Lan := rootfolder.Internal.Tools.AOLlanguage;
3 y" `. g9 @0 j9 K# b5 v if current = @.Destination -- else return
- G0 e9 g, X0 _. ^$ z+ \ then
# p6 L/ {1 }7 ?9 t8 r% y7 F8 y8 G @.Destination := void;
: y$ V$ ^" | e8 P0 f. F. Z if @.occupied then) }, n4 K; h! u# L
part := @.cont;
) H* S: b2 \; p% e @.transpOrder := void;
; i% F7 g, z. U9 ] part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
/ X: E/ i) P, `2 C# p+ h @,root.eventcontroller.simTime);
! P: M7 H/ M. m) M4 H @.HasOrder := false;
9 \1 V6 K/ G% ]/ ]+ P @.DrivingHome := true;: t. n+ _3 q% a6 I+ [
rgManager.tryToStartTransOrder;
# ^4 B4 s7 |; l9 y2 g if @.Destination = void: F I g) a& E. h
then -- no transport order for vehicle @2 W; D/ E6 R* p& u0 S5 g# p
@.Destination :=
3 }, V- w3 k* L1 t/ C& N! j1 {% m) ^ rgManager.nearestFreeStation(@,track.~);
$ B, I2 z8 ^0 ]; O% D: ]6 A" a$ ~ newDirection(@);
# P& `7 E) w z+ J' V' o5 b if @.Destination /= void then
6 p* x2 J+ h5 A, b @.Destination.NumReservation :=$ A, c7 s4 b+ p0 g
@.Destination.NumReservation + 1;
/ B4 v7 U, ?2 g% p" x end;
$ s" F! u8 G; ?* y7 Q5 X) [$ [ @.CurrIcon := "drivingHome";7 |1 }$ z4 }# N" \ J5 {# @/ |0 {
@.DrivingHome := true;. K9 e) G) ?: i
end;, Q1 u$ V, |0 c6 ~% f% ?/ l( D
else -- the vehicle @ is empty, both vehicle and part are in the same dock station
( I0 p8 B+ {& I$ _7 p part := @.transpOrder;
- Q: |4 Q$ U0 X) d( s! \ part.move(@);-- load part
4 D( H9 u. g+ [; Y: Y2 R @.CurrIcon := "load";
- E5 ]2 y) z y: F GlobalDistObj := part.globDestination;
- t, B) K& ^. ?" B* j assignLObj := rgmanager.rgAssignL;
, D! W' u+ [ L row := assignLObj.getRowNo(GlobalDistObj);% T$ g- Q+ ?" u: I* k6 E2 C
if Row = -1 then -- since 706 q. v: G) F: P' U
if lan=1 then
5 g) i# l. x7 h8 s promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
3 l! t( j& z9 _! q to_str("in der Andockstation: \"",?.~.name,"\""));4 Z E. X8 q' Y& Q2 x. g
else1 [% q) Z, O, X( ~7 n* N2 c1 ^# L
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),# f. q! r7 ^9 X/ M& p4 c
to_str("in docking station: \"",?.~.name,"\""));
& B+ [$ u# T$ C2 k% I+ H; t end;
7 }8 K2 V! r0 ` else6 e7 g0 o/ O0 x6 L
@.Destination := assignLObj[1,row];
: m% w; G( a9 e) _8 X" x2 F end; $ b) E! ^1 H3 V
newDirection(@);
# U9 w0 @! t8 g) q2 d @.HasOrder := true;. i9 r& v) I2 w
end;& r6 d- j3 C1 D
end;$ [* k# V( s( D5 f5 a
end; -- of the method
, j6 J( j: I8 P* ]6 [/ P |