/* called by: entrance ctrl of the object 'track'
% |3 l( T8 T+ `, ^*/4 m/ L- z$ k& ]: v( B
is
( v0 ]: D/ s' k9 ?, x2 V part, GlobalDistObj, assignLObj:object;row,Lan:integer;- h5 f" Z1 e% \
do, x, a) V ]# I3 o% J/ T5 _' R* M
Lan := rootfolder.Internal.Tools.AOLlanguage;' |# c, |# a* i5 M: L+ s1 ^( r! {* O
if current = @.Destination -- else return
/ Y! N$ @% H4 q5 j2 S then+ Y) R. N' X/ X
@.Destination := void;
/ ], D% X9 U, [; Z/ q if @.occupied then
# |3 @, e" v+ E1 P7 P& k! Y part := @.cont;
" N) C' m3 J+ G @.transpOrder := void;+ x# y) v& b& H2 f/ @
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,8 ~& @$ e- R( T. l
@,root.eventcontroller.simTime);) D6 ^7 z n: K4 y. X
@.HasOrder := false; Z8 i( a! j; Q( o# c
@.DrivingHome := true;, [; ?, U( y8 A8 }+ I: U
rgManager.tryToStartTransOrder;0 v! c/ U& h# H
if @.Destination = void
. k. d& F, K7 e+ N6 u then -- no transport order for vehicle @
/ h6 [ c% [- O+ } k @.Destination :=. d+ K% K# u* A7 p. X( c
rgManager.nearestFreeStation(@,track.~);
) U: @7 Q# X' A( q0 @& R0 \ newDirection(@); & m2 M+ r; B: U. ?# _% l
if @.Destination /= void then, B+ j w5 H$ z; t* V0 u
@.Destination.NumReservation :=
- G0 B+ N& h5 [6 w( p @.Destination.NumReservation + 1;! I* r. y6 Z" o6 u0 P
end;
( ]" N _+ Z0 t1 |9 ?8 F @.CurrIcon := "drivingHome";
, w0 T4 U$ e$ w" ?; } @.DrivingHome := true;- h8 c- X% ]. V
end;
4 e5 |) q: R1 Z5 c else -- the vehicle @ is empty, both vehicle and part are in the same dock station
' Y7 z$ b$ F% B6 W; D part := @.transpOrder;
/ \7 [1 i4 l! ~& a part.move(@);-- load part; \0 d( Y( v6 j0 G9 Q
@.CurrIcon := "load";& Q' Q+ ]; J1 ]. W
GlobalDistObj := part.globDestination;
/ ~0 g$ w+ D" t+ k9 X5 d assignLObj := rgmanager.rgAssignL;
/ e. t9 t* b7 I0 X/ @ A row := assignLObj.getRowNo(GlobalDistObj);
1 g0 z" i5 ^' g- K/ ? if Row = -1 then -- since 70
% P+ x2 R' q _8 a if lan=1 then2 J% O9 _; P! s9 ?
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),( p* Q8 T" c# {, j8 k
to_str("in der Andockstation: \"",?.~.name,"\""));& I0 T5 {$ J* N& H
else; q7 k) U& t: Y) V4 w/ S
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
( Q' L3 a6 T0 Q& p to_str("in docking station: \"",?.~.name,"\""));
+ r+ g- U; ]- Y8 E& I end;
7 v- r/ r% E0 U. l8 t2 c1 H1 m else! U# D/ {4 l/ }
@.Destination := assignLObj[1,row];& {8 `+ ?2 I/ }
end;
8 P. d8 z% C' Y' M# q+ j newDirection(@);
e' q! _- e; @2 @6 x2 G* Z @.HasOrder := true;8 a% j7 }+ g: ?( C; _" C% a3 [8 v
end;* F! j8 }9 D# R! k) O1 p! a) D
end;
! S5 y9 G! {( b' f4 \end; -- of the method
- u1 t0 `3 M! K5 q |