/* called by: entrance ctrl of the object 'track'
$ }8 L0 m; s5 H' X3 ?*/: ^" e$ J" f4 J; k6 n
is
0 U5 X {) h% A( `- S. e5 S- B part, GlobalDistObj, assignLObj:object;row,Lan:integer;
8 w" a4 \3 y: p a, }5 Hdo
) d. Z9 ?" u% \6 c1 j Lan := rootfolder.Internal.Tools.AOLlanguage;
2 V0 R6 C* V% ?# O if current = @.Destination -- else return
" s6 w( V4 D& ?% Z then6 | V" V6 H# g* G# T2 z
@.Destination := void;
+ S% ]/ R- |. F if @.occupied then
7 n8 S* }( j [* G9 r6 C. Q part := @.cont;
5 m9 O% U# _6 V7 u$ ^ @.transpOrder := void;) s2 J8 K+ @2 i: F; O" M/ O9 A
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
# `$ ~; }0 l' H. `/ U' n @,root.eventcontroller.simTime);; z. Y$ w, {) S2 Q, a: N: f
@.HasOrder := false;
5 }8 W3 n2 c; H2 F, {& |% I @.DrivingHome := true;
: e3 I; t2 J, z, m/ h2 h rgManager.tryToStartTransOrder;. k/ }9 n& H1 M7 ]0 q
if @.Destination = void! n, j- v# P* T
then -- no transport order for vehicle @9 f! j( N8 `2 o' ]1 \' H6 [: T
@.Destination :=( Y n; m0 T1 [7 a6 }
rgManager.nearestFreeStation(@,track.~);( \" e. X' e% ~ ^8 B$ j0 C
newDirection(@); 1 v, J: X- _7 S& }
if @.Destination /= void then
. ^" @0 l) C' C4 O @.Destination.NumReservation :=
! W; f0 |/ B2 V) C! L2 v5 } @.Destination.NumReservation + 1;; Z5 l. J# x% d1 ?
end; h. C7 l; {5 V, A7 W5 Y
@.CurrIcon := "drivingHome";
! B8 U. l, b* j$ q @.DrivingHome := true;
& Q' C0 {/ e! l end;
/ \# N3 Y; M2 H8 m5 d else -- the vehicle @ is empty, both vehicle and part are in the same dock station
% Z5 {, {1 x9 ], J part := @.transpOrder;
$ S* v5 r4 k/ |/ ]. J+ W part.move(@);-- load part' O1 e* c* |5 n
@.CurrIcon := "load";
1 |1 {; ~7 Q; r/ e; G GlobalDistObj := part.globDestination;
- ?' t8 `4 i% ~ assignLObj := rgmanager.rgAssignL;
6 H" f; H6 L$ G row := assignLObj.getRowNo(GlobalDistObj);
1 N6 r9 z2 |/ N9 b9 J if Row = -1 then -- since 70- ~; |5 i# n8 \4 b' f
if lan=1 then5 c- h* E3 w6 X5 z) Y) W5 z" M
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
% l0 G6 N, k. ?. r, D to_str("in der Andockstation: \"",?.~.name,"\""));
! d4 u0 Q' t* N0 u0 c* O else' y; F# q2 i7 O ~) w- i" x9 k
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
4 V8 M) C8 a$ ~ to_str("in docking station: \"",?.~.name,"\""));
7 z1 T$ F9 Y! a end;2 {% m( a% I% q8 W
else
$ v* f5 \4 x5 A! i% @- Q @.Destination := assignLObj[1,row];# S/ x- k9 @) m( d& f
end;
3 |, I8 l) N0 I/ O newDirection(@); U! n k! ?# b8 C! N- G
@.HasOrder := true;' P+ d$ J/ N4 }% P8 m5 b
end;
& ~* q' t# b# E/ F) n T end;$ p# r/ a$ `/ A2 l! N" I/ A
end; -- of the method
2 d. i4 x) O8 G8 a8 ?; p& M; G8 e( Y |