/* called by: entrance ctrl of the object 'track'
1 Q+ \1 r! O+ B b% G6 v*/
# l; @: [7 ~. u; Pis
7 j8 \; ^( n3 |: } part, GlobalDistObj, assignLObj:object;row,Lan:integer;$ m* {1 C o3 m/ \* r
do
' M5 [% z2 s! I D2 s F F Lan := rootfolder.Internal.Tools.AOLlanguage;
6 l k# R& f! i/ ~ if current = @.Destination -- else return
: S I \% Z L; L0 `& g3 F then
1 Q& X# z2 g2 T( v3 g1 c @.Destination := void;2 _+ `" D X2 O: x/ j8 ~
if @.occupied then
, V6 V9 W8 E6 [2 d, q# } part := @.cont;- @" c6 D7 R, C# j: q, G
@.transpOrder := void;. Q: z0 y3 M! o0 e
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
* X% o! V6 n0 U- {4 G @,root.eventcontroller.simTime);
# ]8 T( h3 o7 g @.HasOrder := false;
1 t8 {1 U1 q% }! U( {( @: G+ s @.DrivingHome := true;3 N+ Q! f- c6 z
rgManager.tryToStartTransOrder;# e$ e0 J; S, z1 ^' \
if @.Destination = void
7 m* ~$ [* H, c3 D then -- no transport order for vehicle @
7 h) F5 v$ m* ]2 k @.Destination :=. U! |1 m7 I7 n) @! |, ?
rgManager.nearestFreeStation(@,track.~);
- r0 Y- v# y' O- @) m: e newDirection(@);
' {/ H7 N ?% k0 \ p" k if @.Destination /= void then* a: @# g3 `" A# {$ W! D# b
@.Destination.NumReservation :=
% r" U( X) C. P" f; N9 s! j @.Destination.NumReservation + 1;
6 C! W$ m) j3 j0 p2 i0 i8 e. D end;
7 a9 F) h- L- E' S5 {# { @.CurrIcon := "drivingHome";
* a, w$ o9 H6 J) Y* P: }5 V$ Z5 p @.DrivingHome := true;) H1 Q; Z& M5 l
end;
5 K+ w. o h/ [- v else -- the vehicle @ is empty, both vehicle and part are in the same dock station& ?/ T3 p5 m7 y! `3 l v4 ?* S
part := @.transpOrder;
4 J3 B& d; h1 x3 L part.move(@);-- load part h* Z* r8 \8 q, e7 T
@.CurrIcon := "load";6 g8 {, R' E5 }( V. G2 \
GlobalDistObj := part.globDestination;, y, d- N% q+ F8 y7 [/ j1 D- x
assignLObj := rgmanager.rgAssignL;
' c! R1 i" f2 x3 b! ]: H& I; I row := assignLObj.getRowNo(GlobalDistObj);. O, U% c2 S% }6 l7 g
if Row = -1 then -- since 70
8 F8 a/ |- P( t* h+ e. K if lan=1 then x4 ~/ E9 u' l8 ?& j* i
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),# x) X) a9 ?2 h
to_str("in der Andockstation: \"",?.~.name,"\""));
+ x: H* x+ @1 ]' ^7 X else
8 k, `; p/ g" W8 d! ^ promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
7 ~$ p, [/ K* f! V to_str("in docking station: \"",?.~.name,"\""));
7 ], F* }- f( v, v end;
% e7 V3 t8 V4 j1 V& H# M* Y else# w7 a L- ~ s
@.Destination := assignLObj[1,row];
* W, |$ v) z X- n {- E- ^% t' R end;
. q4 v9 @( Q- ~9 a/ [. Z" |0 @$ ? newDirection(@);
6 {. q* M0 G4 e, V2 Q @.HasOrder := true;! d1 S3 J" Y( `/ b r: \
end;
8 ~( s5 a0 h L$ } end;
3 w& ]4 Y+ [+ |, z9 M0 Iend; -- of the method
7 D) \! {. }/ M! m% J/ C4 u8 H |