/* called by: entrance ctrl of the object 'track'
$ ?9 W5 j1 E# w) @& ^5 S+ d*/% [9 g0 T" b3 ~1 j
is
- C3 ~. R7 c! A$ \& ?* X part, GlobalDistObj, assignLObj:object;row,Lan:integer;
% O: v6 \0 W& `+ A9 {do
6 L: |' A _3 u Lan := rootfolder.Internal.Tools.AOLlanguage;
% A8 O' S" ~, y$ q) v3 P; y9 z if current = @.Destination -- else return
+ Q- w- M5 S+ K then
# E( W8 Y5 }! [3 V! C @.Destination := void;
: _: o# e, N2 B5 X% f+ Y2 ~ if @.occupied then& t/ N8 {6 S* y5 t7 f
part := @.cont;0 P$ c3 }! ?$ T$ g3 k7 ?/ D
@.transpOrder := void;
+ R0 v& V8 v( `* o! B part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
, C$ ~. P% a+ A5 ?! L @,root.eventcontroller.simTime);: { J: a7 W9 e, [* m
@.HasOrder := false;3 k; w# m% V: k
@.DrivingHome := true;
/ @! M: f! M n' o' l# e rgManager.tryToStartTransOrder;; {3 n8 X; B2 R' l1 m) E4 l
if @.Destination = void6 n( {( R- F0 ` r9 _
then -- no transport order for vehicle @* c6 P c% _( o' Z' s, O& H
@.Destination :=
, F) j$ h% |; j4 g; O% V' G1 ] rgManager.nearestFreeStation(@,track.~);5 r8 e, O1 V e9 D
newDirection(@);
# o" y" m% b5 o4 g; h) y9 V8 w2 G# S if @.Destination /= void then5 Z# P% e) [) H& D+ O3 B$ i
@.Destination.NumReservation :=
p: Q$ l. @$ c' Q& H& ~7 Q @.Destination.NumReservation + 1;$ P( N" X3 v2 @, _
end;2 N1 B t- m6 `4 Q; q
@.CurrIcon := "drivingHome";. I4 D+ u7 Y- {: p, F/ p
@.DrivingHome := true;+ [4 Y7 Y; ?; \, p" H; I4 A
end;6 {" F) S5 t- S0 E4 f
else -- the vehicle @ is empty, both vehicle and part are in the same dock station
( u% p+ [& n. ?2 w% c part := @.transpOrder;
) S& a: O* O; c5 | part.move(@);-- load part9 _( e* N% k, q4 u1 l
@.CurrIcon := "load";
2 M7 X* S7 M' }0 ?" b: q5 g GlobalDistObj := part.globDestination;
; D$ J- j0 X1 c3 j1 u# } assignLObj := rgmanager.rgAssignL;
. ~% p' e* X5 ]1 D( S9 s3 ` row := assignLObj.getRowNo(GlobalDistObj);
: z# u+ f5 h* W5 J" z0 p if Row = -1 then -- since 70
. \, u, d/ D, t" @% Z$ k S( H if lan=1 then) [8 p7 e/ R1 d. @
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),4 m c$ b& ?. S; G
to_str("in der Andockstation: \"",?.~.name,"\""));
; P9 A/ O' ~7 L( c$ a t9 t else
2 k+ N+ s2 e' u promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),' q4 }! B; L0 i) c& L
to_str("in docking station: \"",?.~.name,"\"")); b. @3 C# ~$ L O/ z1 {: h
end;$ H6 |# L: c+ r8 |1 ]
else
5 M3 C2 a: A! G4 u9 K+ E @.Destination := assignLObj[1,row];- c/ y7 X5 t7 [( r
end;
{6 Q" V1 I9 r1 ]# O% C( I1 I newDirection(@);" ^" k7 t) G9 M
@.HasOrder := true;
6 R6 w8 p5 z" }( G2 }& Z6 \* A* ^ end;) q+ _! r8 P6 o& D6 f: P
end;
1 F+ O. A9 G' E. `# Y8 iend; -- of the method B) z+ z2 G/ l5 @/ f' L0 _: }* g
|