/* called by: entrance ctrl of the object 'track'0 s' L) d6 e$ _3 v" V6 x! O
*/
. f8 b( n& S- ] Z- gis
; v2 e) ~- ?2 ^3 F: B part, GlobalDistObj, assignLObj:object;row,Lan:integer;0 x% t7 L: S& ^8 e
do
! b6 s, [9 S0 B Lan := rootfolder.Internal.Tools.AOLlanguage;" b3 H8 a, e5 Z
if current = @.Destination -- else return
5 k+ u! A* o+ m/ y* q6 j# _# } then
2 F2 G! x% a& x3 n& _* L @.Destination := void;& b N% v% u( e. Y( t$ d
if @.occupied then
$ W6 [6 g8 _4 q; a part := @.cont;
6 Y2 T) v" ]- X9 E. k2 a @.transpOrder := void;
1 q) ~ z$ e5 U2 P: m part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
1 ]/ B! ~1 D/ _# ^ @,root.eventcontroller.simTime);
0 a$ Y( y) h* m+ y- H' i9 t: | @.HasOrder := false;
/ ?' P* i' c- _/ _7 \0 L, w @.DrivingHome := true;
# m! `0 d1 M7 P7 g1 e9 s& d rgManager.tryToStartTransOrder;# g0 {) R' h7 P$ K1 Q* P1 F
if @.Destination = void9 V; F2 B, t# s) ^5 t. J
then -- no transport order for vehicle @7 r g. S9 @+ U. z" k
@.Destination :=
/ h2 ]- I/ @) E2 y- m4 T8 ~' X rgManager.nearestFreeStation(@,track.~);
; ]" W% z3 @6 n$ x, X, T newDirection(@);
& w1 x/ M# ?* J7 Y. l6 I( } if @.Destination /= void then6 a z* q: q; [* }# J5 v+ K
@.Destination.NumReservation :=- N% y5 T! j/ F& l
@.Destination.NumReservation + 1;
+ X% V8 T& ~1 l1 N# ?+ t end;
) }9 h! W: R% u+ Y% Q @.CurrIcon := "drivingHome";; H3 @- z$ T4 H# J0 a
@.DrivingHome := true;
' }& ~/ }4 d! X+ l/ ]5 y. _/ L end;
5 u {1 C n$ Q else -- the vehicle @ is empty, both vehicle and part are in the same dock station! p0 M9 y- o5 @0 q
part := @.transpOrder;
2 C% D+ b9 m) Z, Y5 G. S. K part.move(@);-- load part1 b+ C, _' O7 ^# D/ l
@.CurrIcon := "load";( K4 T5 J A* U( [4 V/ t: |1 d
GlobalDistObj := part.globDestination;
5 _# F8 s7 @4 n+ G2 H; P assignLObj := rgmanager.rgAssignL;
A7 R1 F. d* x3 L row := assignLObj.getRowNo(GlobalDistObj);
3 n# c* j1 V+ j8 O* I3 U if Row = -1 then -- since 705 i3 r% H- H$ A* N% b
if lan=1 then e0 p: U, R, O: {
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),, [; b5 i4 C. k0 x( W1 J+ G
to_str("in der Andockstation: \"",?.~.name,"\""));
4 v4 f* X8 }1 p; t. x else
4 B3 {5 F8 _; q# C& d promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
2 q% u# h& K6 a! l; x$ L6 {8 s to_str("in docking station: \"",?.~.name,"\""));
7 E( U; @. I4 \8 c2 s; U4 s, R1 z end;
. \8 d1 p) z! D8 e. A1 f5 B7 l b else. d" P) }& G* r' m. W
@.Destination := assignLObj[1,row];
' K! ?! C) z/ a! w% j. w3 h end;
: L6 S7 s" \' ]* n( d( ?( E newDirection(@);* k2 _7 ^0 j( ~) a( ?( L, H h
@.HasOrder := true;; k r/ R9 J t! U; `
end;/ m9 w3 S7 b) z1 m8 y
end;
6 d0 Q x. a* }) \; t& Nend; -- of the method. h9 [! m E! [* M3 {. p
|