/* called by: entrance ctrl of the object 'track'
9 g- p: P& N" E5 d$ h5 }*/6 P! S( I: M7 k/ A5 w/ s0 B
is+ Q' R2 i! w$ D2 E
part, GlobalDistObj, assignLObj:object;row,Lan:integer;
) J9 f: K6 C2 \do
( n" L; A" V4 i Lan := rootfolder.Internal.Tools.AOLlanguage;1 v* }$ w) c q
if current = @.Destination -- else return0 J/ G+ M, g. a G* ?5 M" `
then
7 z/ b% w3 N7 h" [: ]9 d @.Destination := void;
- Q& a" O2 c0 s; e# N2 m if @.occupied then
. g; }) ]2 U7 E0 o$ k* Z. L part := @.cont;0 o$ H8 v% {7 Q: n3 @9 V
@.transpOrder := void;6 B6 @5 u3 ]% X
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,' Y4 U/ ~" H9 y ]/ D
@,root.eventcontroller.simTime);& i# T( M) k; g* t6 ?
@.HasOrder := false;
3 f$ R& m" Z- I" r @.DrivingHome := true;6 K6 z, [+ H! O. \0 L
rgManager.tryToStartTransOrder;
+ d8 Z j5 u- I/ N. T! `( r! p if @.Destination = void
2 | R; F7 y( f% F% }0 X6 p7 T then -- no transport order for vehicle @
. I6 J+ o$ i: a% X( h. m, J @.Destination :=4 h% {& N% H$ r- e) D' i6 g
rgManager.nearestFreeStation(@,track.~);) S. z$ _, x( O( @3 q
newDirection(@);
6 M* n* E6 Q% d if @.Destination /= void then, [+ i' {( \& [: k! G8 g
@.Destination.NumReservation :=
0 `5 N& }( c: j# [; u @.Destination.NumReservation + 1;
1 {8 {5 \' s9 C; q8 Q$ Y! X! v; o8 G end;4 [% H( E' l( C, n/ O$ {
@.CurrIcon := "drivingHome";7 q0 M& J L9 j& I; N/ x
@.DrivingHome := true;6 U3 p6 r/ C1 n
end;( M" W; ~) k5 I$ ]: n
else -- the vehicle @ is empty, both vehicle and part are in the same dock station
4 |; J3 u" v/ ] @ part := @.transpOrder;0 T. @: h- q: G# N1 g( X* W
part.move(@);-- load part
' k0 b3 I- g0 q+ A' U4 T7 o6 H2 m @.CurrIcon := "load";/ H3 d! n# \# }+ Q
GlobalDistObj := part.globDestination;/ P. q5 A' ~' [4 Q1 L
assignLObj := rgmanager.rgAssignL;4 T0 `: _: a% J+ K" q7 A
row := assignLObj.getRowNo(GlobalDistObj);
- ?/ B3 m/ [. O6 S$ f3 W& ?7 m if Row = -1 then -- since 70
7 J* ]3 A* i- R- @9 a if lan=1 then
2 s7 J1 c9 H; ? promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
6 H. c, u q" {8 a. D( K! Y to_str("in der Andockstation: \"",?.~.name,"\""));
: r% q- N: R4 Z5 T! ? else1 s# o; X3 U! W, _$ V
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\"")," e4 N; ~6 O8 z) g: A' i2 d
to_str("in docking station: \"",?.~.name,"\""));
" {! r! M5 A4 q" w- ^- O3 U end;' u& L/ f* ^5 X9 U6 o6 V$ A8 b
else+ O% D8 A; T; ]* S _3 x* c) k- W
@.Destination := assignLObj[1,row];
& J% U/ t8 p% f2 s- b2 d( Y end;
) T) t8 D8 F# w8 x% h: k' l) _/ d newDirection(@);
/ s8 ~& l) _4 f$ m* i, b1 b @.HasOrder := true;
) d. e# C6 @9 H end;0 X' ^" T$ M& C( `% U: ?
end;" m9 @8 v: z' o2 _* G% @7 U
end; -- of the method; {( |- S+ |2 z4 C& x( z3 d
|