/* called by: entrance ctrl of the object 'track'; d" N7 g2 Q+ k2 X6 |
*/
3 Q5 e* v d4 K6 X! T- {is
G8 j' ?; h6 V4 [ part, GlobalDistObj, assignLObj:object;row,Lan:integer;
& c/ ]/ L: A1 h" W9 E5 x, Wdo, w' w3 C9 f/ O2 P
Lan := rootfolder.Internal.Tools.AOLlanguage;5 Q: N& s5 R8 U
if current = @.Destination -- else return ?* Q% D0 A1 b# o2 e2 z- h" f
then; r. \% l5 E/ ?1 {' O0 ^; o6 ]
@.Destination := void;
6 M6 a, e: s2 u, | if @.occupied then( i) ]- q5 J0 @! |* F; z
part := @.cont;
) o+ E: \) M v @.transpOrder := void;
6 S- v% a! u: _5 m$ x3 U1 i part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
9 e9 X6 v6 T8 u# P @,root.eventcontroller.simTime);7 [% P. c# H' d" V1 G: m
@.HasOrder := false;) `; |8 {* r4 X$ j, }( F T7 w
@.DrivingHome := true;
0 q+ w; C6 o4 S0 X, \: Y! u5 Z rgManager.tryToStartTransOrder;
2 N, e3 w* a+ z4 }" k+ [, X3 } if @.Destination = void- ~. Z' ^9 W. D2 K, `# e* w7 c
then -- no transport order for vehicle @% y0 N% @5 P' ^ T/ ~) M
@.Destination :=
m( T- S5 i) |2 _8 M6 i rgManager.nearestFreeStation(@,track.~);
! Z5 G# Z5 N. @' \* q3 j9 t: |; } newDirection(@);
* l# _' O9 X9 W+ P) J7 Z if @.Destination /= void then, |9 g/ _+ W2 }
@.Destination.NumReservation :=
. w6 s) f! a; Z# j! t8 I. w @.Destination.NumReservation + 1;
% v" ]) ]6 D' n/ j t) D end;4 G& O- ]. V7 U9 r" M& R! h
@.CurrIcon := "drivingHome";
4 |; C0 I. F* G* q/ S" v6 G- d9 X @.DrivingHome := true;
0 {, E2 P( Y" Y }0 s end;
( i6 l3 y9 f5 O; }8 ?+ C else -- the vehicle @ is empty, both vehicle and part are in the same dock station
1 U% o6 r. R" w8 f4 a- n$ Q. C& l& N part := @.transpOrder; g R0 u7 M3 c m3 C' W6 r m
part.move(@);-- load part
4 A& j }$ v) [$ L% _/ }9 F; M @.CurrIcon := "load";
% s0 H/ m7 @$ M8 R8 J3 M) p GlobalDistObj := part.globDestination; Q9 e7 F) G! x' `+ a& }% z4 B
assignLObj := rgmanager.rgAssignL;
2 L( z* p# ~. m4 t. D; ^ row := assignLObj.getRowNo(GlobalDistObj);. o3 ^+ z ~! y' M" g
if Row = -1 then -- since 70
. J* T* B. @) o8 o$ |: g if lan=1 then
! E* g* ?% u9 r" M promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
6 \8 C1 m: z! g ~% X. F" C6 h to_str("in der Andockstation: \"",?.~.name,"\""));/ t& u' L1 O# ~$ ~7 l6 t
else- b4 _+ g9 I0 P; g; d$ {; d
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
7 O7 `7 F9 T( o5 A5 W to_str("in docking station: \"",?.~.name,"\""));
. }& e6 Y; N+ Q4 w4 ]& W; x end;: T' o8 P1 {: ?$ m) s
else
6 s# N R7 ]9 S+ a; l4 r @.Destination := assignLObj[1,row];
" m u+ u" I5 Z- v- K end;
& x* W" x# O+ M% a1 z) Y, D newDirection(@);! e5 i2 t. d9 q9 T- j3 D$ o
@.HasOrder := true;
4 A" h7 p$ h0 \( Y' i" @ end;
' { H7 h1 ?+ k; c# r# E. n end;) u) g: n$ ]4 Y+ Q
end; -- of the method+ T9 @- W7 w U& e
|