/* called by: entrance ctrl of the object 'track'
- ~ {# A$ q6 X* c/ G*/
8 B: {0 k0 \- m7 o ~* c' a" ^is
5 i, |* @- [! N' i part, GlobalDistObj, assignLObj:object;row,Lan:integer;
2 W3 ]1 z9 @1 q6 h% Udo
, ~1 M" K: o6 M) a3 V Lan := rootfolder.Internal.Tools.AOLlanguage;
^; G2 [6 ^4 s# N% w& T7 a2 Y if current = @.Destination -- else return
% V5 }. _8 {! z8 [* _ then% Z: n4 z: n. W7 w; E
@.Destination := void;7 d& z2 z2 e) @* x5 ^, ^
if @.occupied then
# s+ @; Q- y, U8 N part := @.cont;
9 o" W- T8 K! g5 W T) [/ [ @.transpOrder := void;0 f! b* p& [- A# g
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,+ f3 D5 i, Q1 p* D0 ^ w! m
@,root.eventcontroller.simTime);
( V. a1 M) g9 y8 {0 D @.HasOrder := false;
" z- f; j* P+ X, ?- P+ s' _ @.DrivingHome := true;4 e7 B0 o% {+ h3 R% Z; J3 J- Y6 t% x, ]
rgManager.tryToStartTransOrder;
7 O! c4 W8 \. K! b+ V" ^3 Z) \ if @.Destination = void |7 Y' S6 e) L5 Q9 `
then -- no transport order for vehicle @
! U1 ^( k0 W2 I: i; G @.Destination :=8 |% r$ @+ Y Q: a
rgManager.nearestFreeStation(@,track.~);
& y& J4 K+ j. K4 ?- F newDirection(@);
; V' `/ P/ b+ Y if @.Destination /= void then) }8 Y5 q% ]2 ?1 N' M% Y% `6 k
@.Destination.NumReservation :=
3 v3 I f. S- n9 G: o( ~6 c) p1 o @.Destination.NumReservation + 1;
3 o+ T0 F; l; c, Q end;
8 S. k K1 h$ ~, J; r @.CurrIcon := "drivingHome";
. {3 L5 f9 O: A @.DrivingHome := true;4 A/ F' ?5 Y% C. e: W% E* a
end;
& o }0 Z& @! T/ H# [. q2 \! \ else -- the vehicle @ is empty, both vehicle and part are in the same dock station
+ m2 T( ~" l8 ?8 I6 o$ w4 i part := @.transpOrder;
5 Y3 {( O3 ^ I% s# A6 X) X/ T0 e- A part.move(@);-- load part& b/ O& G* P$ Z, ^+ |5 {* H! {
@.CurrIcon := "load";! H- D$ }5 d% n! k! s
GlobalDistObj := part.globDestination;: V( C* c4 Z3 Y; i
assignLObj := rgmanager.rgAssignL;
$ X+ X; L- }0 q9 Q& e0 y9 o row := assignLObj.getRowNo(GlobalDistObj);
) ^) Q6 q/ W9 u5 l) y5 A3 x% ?- ?4 x if Row = -1 then -- since 70
' K5 T3 ?8 E$ W# } if lan=1 then9 w- I; j2 J) y; o# G4 I9 b
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),9 K( S' A& A# N9 s4 a4 \& V# c
to_str("in der Andockstation: \"",?.~.name,"\"")); E( d7 a- Q7 C, g
else
5 D0 D2 I. Z Q promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),0 w0 G# M) f3 h: F+ F2 q
to_str("in docking station: \"",?.~.name,"\"")); + O7 e+ R; v- I5 D. W0 O, A
end;
" u Q! s6 K8 N& I. v5 v, { else
% A! b7 r! r; g2 C( O: E) U2 H9 r @.Destination := assignLObj[1,row];/ S4 Y* y2 r/ G$ l; r0 s$ ?
end;
* O% Y8 j2 h8 d3 a newDirection(@);
' R6 O% W/ s! ^+ M$ C/ Y( W @.HasOrder := true;
" A% P9 w; v ~ end;
+ u' s: h% u2 p! v8 f# ^, R# F end;+ c1 h' } y4 e; I
end; -- of the method
7 \- x9 e( [, w1 g) Y |