/* called by: entrance ctrl of the object 'track'- h4 D( { }( W1 F
*/+ h- ~. p: ?8 e* Q4 [1 q0 ^$ \
is
. U6 |0 C3 ^7 Z& \' Q. o* F5 ?) a# p K part, GlobalDistObj, assignLObj:object;row,Lan:integer;/ U7 G2 o) |7 M. \
do
2 S5 G- {& P/ z+ m% C2 h6 U Lan := rootfolder.Internal.Tools.AOLlanguage;
( i; W' X' o" c# ]9 C0 `2 s8 N0 S/ [' R if current = @.Destination -- else return
! K: l) X2 T f1 S then
; f: [5 v5 x7 H- Z" L9 K( s @.Destination := void;
, d/ y+ C% y2 E# P" |" L if @.occupied then+ r5 |; n0 F& m) h
part := @.cont;, Y$ E# z6 o X! i) O
@.transpOrder := void;. Q9 D7 ~' Q5 Z/ V
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
. q& w: B" [8 Y4 W3 t2 i0 ? n4 s$ W @,root.eventcontroller.simTime);$ P+ `9 U4 Q0 \5 z: b/ q `0 m! h4 x1 z' @
@.HasOrder := false;
2 P7 w% \: b4 A# ^! J @.DrivingHome := true;0 i+ |' w8 ^* d9 Y3 S
rgManager.tryToStartTransOrder;' W) M! a1 ? h
if @.Destination = void
+ I6 D, `1 {/ v ?' q then -- no transport order for vehicle @
& u1 |# }; h" G @.Destination :=, A# k9 d' l+ g1 i4 R
rgManager.nearestFreeStation(@,track.~);% m- r$ ~! A! \1 P2 J
newDirection(@);
( K" i' c a u# X, H; w if @.Destination /= void then% u8 e R4 x* T' i, I
@.Destination.NumReservation :=
+ |" o) N; W' W! B9 B/ o @.Destination.NumReservation + 1;
. Q% {$ E* m- w1 {. R end;5 c/ j# ]- Z+ G7 u- G5 E
@.CurrIcon := "drivingHome";
) W4 i7 T* B* p6 o: e; F @.DrivingHome := true;3 i6 ?" G& b `- w H
end;% N# {$ [/ I4 }, w- G, a
else -- the vehicle @ is empty, both vehicle and part are in the same dock station
! t- T5 }" f9 s0 q part := @.transpOrder;
E1 w7 R# n" u ?& ?$ N+ _$ k part.move(@);-- load part
9 @, t' F& C2 Q# }0 x @.CurrIcon := "load";' h. Z9 B: B( p4 o0 r+ m* e
GlobalDistObj := part.globDestination;& K# n% @0 _& `$ k: a# X
assignLObj := rgmanager.rgAssignL;* Z6 s; u: k+ J4 Z
row := assignLObj.getRowNo(GlobalDistObj);# V( {% h1 |- V1 M; r5 W5 f
if Row = -1 then -- since 70
2 g; d' v( {5 v& j E if lan=1 then: a0 [ p$ p9 u ~
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),% } ]: o; H$ d
to_str("in der Andockstation: \"",?.~.name,"\""));
8 Z9 e3 P" f( E5 V. a% C$ H else
; a; a) v! o* F9 e promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),) f6 s6 G% v+ N2 _3 q [3 ~+ B
to_str("in docking station: \"",?.~.name,"\""));
7 {+ M2 {, q9 j end;
) b$ b, t/ C, f3 y6 m. x" y else, S1 u& V) e. ^) W
@.Destination := assignLObj[1,row];: _* I5 u0 w, K! f9 A U& A
end;
7 e$ R# Q* y* M newDirection(@);
. W6 `8 p& L2 c! m6 t3 b' V4 f6 L! G @.HasOrder := true;
7 A+ ~0 f4 \/ T- D, a# l0 B7 N end;
- f) o6 U; H6 Q" @* i; H) P7 ^/ l end;
8 n8 I1 Q" c6 h3 P8 mend; -- of the method- y9 g5 O# t- F, s
|