/* called by: entrance ctrl of the object 'track') {) z& D% e: [* {/ f& e; ?5 g
*/
. M. \ \) }! N& j/ Bis
; Z9 x& ]) X, Z; n R& [ part, GlobalDistObj, assignLObj:object;row,Lan:integer;3 p2 f9 [3 q" M6 m$ _) T
do
+ S' G5 T* U) u; C Lan := rootfolder.Internal.Tools.AOLlanguage;2 f$ {: B' g0 Z1 [1 M. S& A
if current = @.Destination -- else return
- B, o; t4 O; n' d6 v+ M then0 w8 k- _; W" g+ c# x$ j7 q- r! B
@.Destination := void;
; [6 V) I$ X- ]& H! _0 | if @.occupied then8 I$ Y6 I) L" n' Y+ a* K
part := @.cont;
: `4 j/ Q+ ^% h% J0 q @.transpOrder := void; U. G3 c( l1 a, i
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
% H# C6 V" n; q5 i @,root.eventcontroller.simTime);
) K3 s7 s' [# S C3 u/ F3 l: l @.HasOrder := false;
9 p" K; \$ `8 ]. t' d7 O @.DrivingHome := true;3 l/ w# e& i' `1 _, m
rgManager.tryToStartTransOrder;( ~$ h/ y* m) O; a
if @.Destination = void% I9 L5 M. i. U x
then -- no transport order for vehicle @- g6 A6 A& r+ q8 O
@.Destination :=4 \0 J& W& {8 l9 A3 m) d% D
rgManager.nearestFreeStation(@,track.~);
8 X# z g8 V9 e newDirection(@); 2 q* ~9 j0 _, B4 U
if @.Destination /= void then
s/ n5 j( j! s- V* d+ e4 _ @.Destination.NumReservation :=$ Q3 ?( B* v8 A! e6 T3 j! e
@.Destination.NumReservation + 1;
$ c! A4 j6 b% ~9 D$ t9 y4 j; { end;2 n& T. r+ T* c" t' X' N/ R
@.CurrIcon := "drivingHome";
& B$ q3 Z6 ]# v8 ]+ D8 k6 q @.DrivingHome := true;
& j( W! @# @2 u R6 m5 { end;
9 x* G3 d* Y. Y else -- the vehicle @ is empty, both vehicle and part are in the same dock station- I+ S+ ]1 B: W5 v1 Y/ n
part := @.transpOrder;! y' E5 a$ V# q* o) W4 b
part.move(@);-- load part% R8 B5 o8 @" N! a+ p4 @0 H( X
@.CurrIcon := "load";1 \* e) x, w+ T1 L# g' c4 w
GlobalDistObj := part.globDestination;
. v6 a9 _9 d' F) `! M5 ~7 R assignLObj := rgmanager.rgAssignL;
) |: c, [5 ?: m, U* H1 i5 G( T row := assignLObj.getRowNo(GlobalDistObj);
1 k8 e$ J* Y1 y' G) D# G) B9 Y if Row = -1 then -- since 702 k, F: R$ \4 ^ b6 w& S
if lan=1 then
8 }9 Z8 K- |1 t! _* Q: i; j promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),3 ^* L/ Y4 G* b" O
to_str("in der Andockstation: \"",?.~.name,"\""));$ E. C2 e5 K6 @& i K8 g7 T8 V
else E# v% i8 g- z2 A
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),8 \4 G4 S# a, G9 F8 x5 E! y0 f
to_str("in docking station: \"",?.~.name,"\"")); 6 D! b% ^: X5 B9 [( F
end;$ A+ d) {4 O1 O' B/ r$ w6 Y
else
^8 B/ j9 A, h+ w! Q- @ @.Destination := assignLObj[1,row];1 F' b2 e8 f* d7 g# `0 u3 d. T
end;
/ r/ `& L1 e M- e6 [ newDirection(@);
' ~ P. s0 X, D) c! J' L! s- g @.HasOrder := true;! Y: p! c* \! a
end;1 m" w& ]% M4 c/ Z( t% ~! n) }+ ]
end;
' T6 ^1 g4 k) jend; -- of the method
" @' u4 x0 w! J1 u* L& l |