/* called by: entrance ctrl of the object 'track'
' m1 f- V! _( k*/
) y% z; m; i9 I; p" Pis F9 c. C: j3 B8 Q
part, GlobalDistObj, assignLObj:object;row,Lan:integer;
% ]) }) }. q7 U9 odo
4 b! ~6 j, I0 j: g) f) a0 F. X Lan := rootfolder.Internal.Tools.AOLlanguage;
( G0 y, F$ h( b8 ]5 q) p if current = @.Destination -- else return
' d/ \: k1 F1 I6 a2 h4 }0 _# g then8 M7 M3 Z; y0 B. l+ K
@.Destination := void;
, m Z# h6 s, k: N1 x) A if @.occupied then4 G1 y( Q, e7 V8 u% D4 R1 x
part := @.cont;
1 s, B4 ^% v% q# F& \8 n% {3 o @.transpOrder := void;
2 q2 o2 X9 a1 t$ h( X2 R4 O$ F, P part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
5 M" ]% @) A; i r9 n7 E1 d @,root.eventcontroller.simTime);
, u) l& G, Y( i; V& A, Y8 K! U8 z @.HasOrder := false;
) D5 L' i- v! ]7 s# y @.DrivingHome := true;' }+ J( S$ V( G) A: m N
rgManager.tryToStartTransOrder;0 ]0 {) I. x- S/ K
if @.Destination = void
! N0 I+ Y1 p! D5 ^ then -- no transport order for vehicle @
2 _8 Q" k: _% G: s( T; F @.Destination :=: T2 S* v) s" K+ ?, c
rgManager.nearestFreeStation(@,track.~);
4 c& b" l- x% Z' f2 Z: {, i9 k& V( b newDirection(@); 0 x2 c6 u$ Q$ N8 U: s
if @.Destination /= void then
+ Y6 i8 y$ J& N( T' M4 \# E, j0 N3 ~ l, I @.Destination.NumReservation :=
' K, H1 M% ?4 T/ H8 v4 r1 O1 p @.Destination.NumReservation + 1;& b: n; k# j5 `$ {
end;
6 }" w$ I4 ]# j/ @8 ^7 V @.CurrIcon := "drivingHome";
" Y' K0 R$ ] H7 l/ v @.DrivingHome := true;
$ A. h, y" Z0 m# P; X8 u! i! i2 A4 i end;6 E7 o) c8 M& b! E! `6 Q, r7 p+ W
else -- the vehicle @ is empty, both vehicle and part are in the same dock station4 j; R( B }; r1 J) b6 \
part := @.transpOrder;
2 E: d; @9 X2 N* Y3 p3 B part.move(@);-- load part% U+ K% d8 ~% R' P
@.CurrIcon := "load";9 @! m( ~, Y8 |9 r' y1 _4 U
GlobalDistObj := part.globDestination;
$ T- p" j8 f( h N0 q4 j$ o assignLObj := rgmanager.rgAssignL;
7 l2 j0 u. s+ H3 q+ v r' z2 g row := assignLObj.getRowNo(GlobalDistObj);& t% p3 \( K" F$ x# X1 j! k5 F4 a" g
if Row = -1 then -- since 707 W8 o5 [4 A& A6 @( g# E9 r
if lan=1 then
1 k$ q8 n& n. d promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
, m+ }# q5 L+ }" I to_str("in der Andockstation: \"",?.~.name,"\""));
# W& ~5 u. T5 q7 T4 V( ~ else
5 _1 q$ s. _3 Z h+ Y. B. h6 d& E8 m0 H promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),1 ^( x5 t2 w* L/ d1 s, l9 p
to_str("in docking station: \"",?.~.name,"\"")); ( O# c! N m0 m/ G% S( X( Z" j8 ~( X
end;
" f. e: F! X3 j! x$ h5 f; u else4 ~; Y% Y) {, Q4 e* \# i
@.Destination := assignLObj[1,row];3 p! y- O( K8 _* n6 h" f) I1 V$ J8 E
end;
4 e7 L) o% s/ K& M newDirection(@);8 \- ^4 [* c* V8 B4 _+ B( t7 J
@.HasOrder := true;
; S" F) D* X' O8 m$ @ end;8 J- b V ?5 y. _2 n3 f! B
end;: g0 q; k. P4 G) F. s6 r
end; -- of the method
/ B, ?4 }8 | A Q% W$ H$ k |