/* called by: entrance ctrl of the object 'track'
0 Q/ q/ ^( L" h, f' o*/
1 Y; u8 K% ]$ }. m( his! `/ y7 V% o; D
part, GlobalDistObj, assignLObj:object;row,Lan:integer;
; _9 X q: {& f+ z T. fdo
4 l/ h3 {, z4 t4 k! [0 Q( k2 ? Lan := rootfolder.Internal.Tools.AOLlanguage;
% K% P V7 U% o if current = @.Destination -- else return$ o5 C- w: `% ~$ ?
then* F# k# s' q' R7 f( \9 U, k$ y8 D
@.Destination := void;
( e5 v* E. J7 s1 a, A if @.occupied then& X3 T7 x% w' r8 ]
part := @.cont;
# |) ^8 n6 L1 x2 K! e2 X @.transpOrder := void;% g" U4 h4 \2 u, V2 `. R% T4 B
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,: c1 G9 w( K4 r6 x+ }! _
@,root.eventcontroller.simTime);* u) |% y$ W' x7 y7 i( q
@.HasOrder := false;4 B/ w+ c) D' I0 {
@.DrivingHome := true;
% @9 m1 I6 n- t0 _6 b rgManager.tryToStartTransOrder;9 o6 \; } {' `& N3 K
if @.Destination = void! Y4 [( _/ p1 h: ], K
then -- no transport order for vehicle @3 G, {# H9 j$ X, k
@.Destination :=$ Q5 O& |, u$ `# c* ?
rgManager.nearestFreeStation(@,track.~);
8 t6 K+ L/ ^ @! _1 R0 [6 J newDirection(@); ( i' A1 Y7 l. W, l8 D% Y2 \3 v$ j
if @.Destination /= void then0 [ p& G- u6 f0 P" D
@.Destination.NumReservation :=
9 Y/ }$ T$ T; X2 g6 q7 h* v @.Destination.NumReservation + 1;
1 U6 V. m. i" G+ ` end;
! n) R6 m9 `5 l! `( O6 g @.CurrIcon := "drivingHome";
^! Q0 B4 p1 }! u$ \$ f8 [ @.DrivingHome := true;" l6 p' h( d- e" Q3 O% w
end;1 o4 X% W( P% q6 ^. E
else -- the vehicle @ is empty, both vehicle and part are in the same dock station% b+ I% S9 }+ E4 r
part := @.transpOrder;: ^- Q2 |% z7 s0 }' H
part.move(@);-- load part
N4 o0 R; s8 K( t: u @.CurrIcon := "load";
) ?1 |1 D; I& O! H! V3 g/ T. ? GlobalDistObj := part.globDestination;
. P! o+ d! w- U- ?+ j+ L assignLObj := rgmanager.rgAssignL;
: G$ P# s9 [+ U( j/ f' n- U row := assignLObj.getRowNo(GlobalDistObj);
$ N$ K! \' q1 a( P- u! c if Row = -1 then -- since 70
, G$ \% m+ f& h if lan=1 then; P2 }$ C2 a2 X1 X
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
) j% `7 t5 l! U3 f0 a2 D/ c. B, D to_str("in der Andockstation: \"",?.~.name,"\""));9 F8 n7 X' u9 i k& X: \
else
5 _7 n: K, o: g) J% o promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
$ B7 Q6 ?4 O: g7 u+ h* E to_str("in docking station: \"",?.~.name,"\""));
. o' v" D' m2 P6 n, @+ h) p end;
! w _8 {; f; I6 B) ? else
# j* T+ w: M( X, i @.Destination := assignLObj[1,row];" C7 |, }( {( I# L. Q
end;
7 d" P& `( n# M U3 k- C3 }+ { newDirection(@);
5 Z2 F8 V3 @4 D% F @.HasOrder := true;
. |3 u" R8 i t) X end;. z2 W: e2 |3 \2 n! S* u+ P0 u
end;1 p" s6 X$ y* q# f
end; -- of the method4 z0 s6 n* a$ B' E3 `6 F- e' z
|