/* called by: entrance ctrl of the object 'track'
8 f' |/ {+ l# H$ K% j- G1 f2 C*/
* m5 t- D, a' Q2 y) _# A6 T- xis
3 d+ r$ O3 Y' ~( I& z. L5 j part, GlobalDistObj, assignLObj:object;row,Lan:integer;; }: s5 k0 i- C" M, d/ ~+ y
do# S5 |8 |9 h0 h. q* F
Lan := rootfolder.Internal.Tools.AOLlanguage;
0 Q T. K# g: J+ b if current = @.Destination -- else return# ?" c3 z4 g( n8 m& H
then& M! q0 F. h, p X( y
@.Destination := void; p3 k z9 _. l0 }
if @.occupied then' \! y' n$ N- V1 z
part := @.cont;0 X- N( e; h* G3 z5 h
@.transpOrder := void;' S1 E2 \, \9 S- H6 f
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
. p; w2 S' J7 O7 Z @,root.eventcontroller.simTime);. K9 f1 N/ j7 x
@.HasOrder := false;
+ J& U% Q" S7 r0 q3 ]& [/ N @.DrivingHome := true;) w5 Z& \+ y) m
rgManager.tryToStartTransOrder;! a8 t2 E$ y! @9 a9 r0 z4 F, s
if @.Destination = void
; a- E) P6 {, K& N% o& U# K; h then -- no transport order for vehicle @2 y" o0 z) E4 N t6 |6 Z$ `1 n0 V
@.Destination :=/ O: P6 X* j' ]! M
rgManager.nearestFreeStation(@,track.~);
2 x/ u- ~* c' Y! X* }, s newDirection(@); ( b h/ n; y' j1 j5 R/ Z3 h
if @.Destination /= void then
7 j1 H3 m5 S7 {+ j! ?6 f0 a @.Destination.NumReservation :=5 w1 _5 `, P9 k+ o5 d' p
@.Destination.NumReservation + 1;
7 Z6 g" ^! u, U end;
- \+ t- ^" f$ V; h- x @.CurrIcon := "drivingHome";# h+ ^! o' I4 J
@.DrivingHome := true;
; j( h X5 L5 d* j; p: S end;
5 T. S1 M! \1 c4 r6 a) p else -- the vehicle @ is empty, both vehicle and part are in the same dock station, @) I% v$ H% y1 K
part := @.transpOrder;) J, v4 Q' Q2 m' [& E7 A: B
part.move(@);-- load part. v6 R4 H9 t: b
@.CurrIcon := "load";
+ m( M% M' S4 X' P; M* W" r1 v GlobalDistObj := part.globDestination;
6 \ Z4 H- N; G" |: n6 P assignLObj := rgmanager.rgAssignL;
; {4 z) Z G5 c. L. F- U: N+ @! { row := assignLObj.getRowNo(GlobalDistObj);# m% N3 ]1 U5 @( y1 e- s0 b
if Row = -1 then -- since 70
j. t3 e3 B' @ if lan=1 then
( ]3 W* S* [: }( L promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
; K+ `# }0 T6 D) f0 c to_str("in der Andockstation: \"",?.~.name,"\""));
7 A+ `5 p! T, H0 H E! m, L: r. R else
( n/ h2 l2 _/ k. L. F4 \ promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),6 a! F6 K4 _' o2 v/ p5 X
to_str("in docking station: \"",?.~.name,"\""));
+ U6 h1 \2 o7 a) j9 T/ V end;! T+ t% o Y( I! X
else# Q3 a7 C7 N2 V4 [
@.Destination := assignLObj[1,row];5 D1 ^! A. k6 ]- g9 x" n
end; - A$ U2 I/ w% d+ @/ S5 v* ?
newDirection(@);: M( K3 r8 x- R0 S3 @) R3 o
@.HasOrder := true;" G% L) G0 b5 w% ?3 O
end;
7 N9 H1 X! F: q* { end;) A* n2 {' g; {1 ?& G
end; -- of the method
( h& B! c5 W7 C2 F$ G |