/* called by: entrance ctrl of the object 'track'( ] M$ d3 q4 R6 t) z
*/+ H! o! o1 h9 c
is" t; _% t2 A& {
part, GlobalDistObj, assignLObj:object;row,Lan:integer;
6 J* j6 {) a$ y. v5 f: jdo
5 C3 C" K, A1 u$ w) p" ]0 | k# s Lan := rootfolder.Internal.Tools.AOLlanguage;! s6 [) C/ j5 p0 A5 I Q
if current = @.Destination -- else return5 V1 R: h+ n' f+ p$ C
then
# ?9 u3 y$ U( R( {+ e @.Destination := void;* X2 j1 |* E: t( T) [* _
if @.occupied then& }1 V# b4 i' h
part := @.cont;
7 p2 s% I) t/ x/ I4 |! e% T @.transpOrder := void;( P1 N' }- \3 @8 f% Q
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,* P5 ]" ?1 g$ e( i) `6 |6 b
@,root.eventcontroller.simTime);& O+ g+ b) m; B3 _; m n P
@.HasOrder := false; A0 z+ t* d* g& _, |. a
@.DrivingHome := true;
: X) L) |* E, D: `* O- a rgManager.tryToStartTransOrder;
0 H2 A0 m' e$ h7 o- U3 j if @.Destination = void2 Y7 n$ H; X& w1 G, q+ F
then -- no transport order for vehicle @4 Z$ {8 T& e. t' d- b, E
@.Destination :=# Q; y+ m8 X4 ^2 t
rgManager.nearestFreeStation(@,track.~);
; M6 Y1 Q* a5 ?, o7 e. ^ newDirection(@);
8 f6 q; O0 ~( _" F9 k if @.Destination /= void then0 Z8 T# \2 \# O! U: k
@.Destination.NumReservation :=
# {- ?. S% L6 Q0 t$ u @.Destination.NumReservation + 1;) I* O2 L9 J! \2 o) e
end;! P7 Y) E. H Z. N
@.CurrIcon := "drivingHome";. w! K+ s$ x0 d8 j" J' V
@.DrivingHome := true;
4 o2 i& v+ g+ K: B8 D7 o end;
) G% Q& n# n1 M% K else -- the vehicle @ is empty, both vehicle and part are in the same dock station( S1 X! Q6 x) A [
part := @.transpOrder;; q& c6 x7 b( V9 f" m7 @
part.move(@);-- load part- e. a* e" E5 ^0 c
@.CurrIcon := "load";6 a( x; U, D: ^$ T& ]3 S
GlobalDistObj := part.globDestination;$ M! a9 G! Z) [; A. l. k
assignLObj := rgmanager.rgAssignL;
4 P, g0 ]" F; `" r4 c6 l row := assignLObj.getRowNo(GlobalDistObj);
9 d+ y9 ]; U1 ^9 w0 T: p; b if Row = -1 then -- since 708 { V4 T8 K1 O
if lan=1 then" z) s2 _- o5 c
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
6 j5 N" x7 G8 e0 n to_str("in der Andockstation: \"",?.~.name,"\""));% U# H1 B1 g2 w7 I1 H. X3 h ?5 _7 ]: e
else, x- v; U7 Y0 f9 P8 e
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),) M" F4 }- r6 _3 k s4 P
to_str("in docking station: \"",?.~.name,"\""));
2 b9 G! `" q( n% K( {' W5 ` C end;( s# h0 e9 v9 {9 \) }% u% _1 r
else# ~% {& t' d! e
@.Destination := assignLObj[1,row];
+ I$ k4 x) N. f8 e end;
% q) y- Z$ c( D# o* c. ^ newDirection(@);
) k) V8 [; A8 t+ B& o @.HasOrder := true;" B$ F# h2 }* \# |. f& K
end;$ t) Y' m* z9 S
end;" r& ]) K) ]. q' c4 T6 b9 e( }1 @4 a
end; -- of the method! ?7 b9 x) |( t& f" X6 f
|