/* called by: entrance ctrl of the object 'track'
/ b. m f, I" X- e, p*/$ N* G% x: D+ F) y* K) q
is
5 f/ @ |' [, t3 X( U. \ part, GlobalDistObj, assignLObj:object;row,Lan:integer;
+ ]& b" R r" g' h/ ?do
% b7 v, g$ C' A Lan := rootfolder.Internal.Tools.AOLlanguage;
# d7 q6 b# U4 m, Z if current = @.Destination -- else return Y4 C7 T& W3 F v: {
then
' E! @: u( ^ s) G0 L7 O @.Destination := void;
7 n4 @6 P) @4 R) d% q' O, M- G0 X0 l' H if @.occupied then' l+ ~" J4 C0 R( F6 |
part := @.cont;
( ?: s; t" W/ ^: Z: f6 `0 m @.transpOrder := void;- l g* d: C1 p! T) G) `7 M
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,. T7 j4 e9 p# T$ X
@,root.eventcontroller.simTime);! C$ y% o1 [8 {- E3 |3 b2 y
@.HasOrder := false;: O8 j5 h1 [* |4 Q2 X9 q
@.DrivingHome := true;
N' T: V7 A6 w# N1 P9 A+ I8 a rgManager.tryToStartTransOrder;
) A1 s0 S2 s+ b u- t! s if @.Destination = void, {. B% }$ G$ k: [3 u4 i, x& E4 L. a
then -- no transport order for vehicle @
2 K8 D3 O, R5 y6 _ @.Destination :=$ F4 }6 {) D' c* [* I! K5 H; y' i [
rgManager.nearestFreeStation(@,track.~);
3 w( G: \& I: ?- s4 _ newDirection(@);
5 A- s" q- {4 t1 x: C- N. ~ if @.Destination /= void then
Q* R$ G8 R; U/ D d! w @.Destination.NumReservation :=
7 }. A3 Z( r% Z8 j6 q: Z | @.Destination.NumReservation + 1;! P% Y- I- f7 t5 U* [2 B8 q
end;8 j$ ?! t2 `3 s9 D" ]! c) | p; @
@.CurrIcon := "drivingHome";5 E& l8 ]+ F. A9 |8 l1 ?' s
@.DrivingHome := true;
3 t+ E L, E+ W end;6 n6 S9 D2 i: o
else -- the vehicle @ is empty, both vehicle and part are in the same dock station
+ W" f5 }4 Z! p2 A- v' p part := @.transpOrder;
* L- a$ S; }& J& U8 I part.move(@);-- load part- z, b4 Y+ E. _* g
@.CurrIcon := "load";& V( f; l- T3 l7 ]8 H
GlobalDistObj := part.globDestination;* L! p5 S& i1 J0 y
assignLObj := rgmanager.rgAssignL;# {# b+ A1 z; G/ d- x, z1 s }+ q
row := assignLObj.getRowNo(GlobalDistObj);
: ~: ]; p& v, Y- b+ L) U if Row = -1 then -- since 70
8 Z! O! i0 z$ x( F if lan=1 then4 G( c( e0 p4 r, e) r0 Y4 q
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
8 |. R$ t! {- Q4 Y* L7 Z to_str("in der Andockstation: \"",?.~.name,"\""));
" C) P _, m1 S' z1 J else' w8 L' W, V; ?; g
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
: j2 `) i* ]5 N9 [ to_str("in docking station: \"",?.~.name,"\"")); . y4 K2 A. P+ ?( A N' d9 B
end;$ U3 o: k# x+ _- g
else
1 H0 x0 g" x% c @.Destination := assignLObj[1,row];
4 p% Y5 Q& }. |5 I0 i; }# p) m# f9 v# | end; : o+ @% C- m: r
newDirection(@);
6 h! P ?* E2 d! r- a3 l$ q @.HasOrder := true;
- n0 T2 _6 x0 Y4 u8 {. T end;7 K& z& c3 }2 m6 {* {) z
end;
4 [' `6 W9 U; y, rend; -- of the method
0 j7 j6 ^( b* s& k _* O |