/* called by: entrance ctrl of the object 'track'
9 f* u- ?$ U/ r# v6 [: x*/
. l+ t' I/ ~( ]0 eis* W5 s2 x9 K0 x0 l( j
part, GlobalDistObj, assignLObj:object;row,Lan:integer;/ N4 K# Q9 z' m& T- `9 X. x. E0 t
do
! ]/ y9 m+ Z' v* S3 L: e" Q" D Lan := rootfolder.Internal.Tools.AOLlanguage;3 G- |+ k" R; b' ~; W8 L5 c
if current = @.Destination -- else return1 B: f# E9 ~% Z& Z j! X
then
: w, W) } c, q @.Destination := void;
% G8 w3 p. B: R. J! o+ }, b if @.occupied then$ i; m8 V! w8 f. _
part := @.cont;
# d6 l, h- _0 g& r' m. Q @.transpOrder := void;' S' t" h2 ]: { E/ v* U
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
: T2 O) \# B" c1 ~ @,root.eventcontroller.simTime);) z# k4 B3 C, C2 h1 u; B6 @
@.HasOrder := false;
! u4 ?9 y. R) q' }# G# T @.DrivingHome := true;0 G: \( \7 t9 D# a
rgManager.tryToStartTransOrder;
4 N( Z0 H' Y/ l- x) e if @.Destination = void# B( c9 l! s2 s# O D
then -- no transport order for vehicle @; Y4 u# v8 e! [& T
@.Destination :=- _4 _) a" E7 n0 D
rgManager.nearestFreeStation(@,track.~);
0 A! s/ H3 K+ c7 _' m& c) K newDirection(@);
; v- W# V; \) l w if @.Destination /= void then
( Q1 q# ^# q4 |+ V @.Destination.NumReservation :=7 {+ {; D8 e T3 L+ w$ l
@.Destination.NumReservation + 1;
/ ]( Q* J' n7 I+ i( S) N end;6 V; t# a9 j$ p! U2 {- O" ]: q4 ]
@.CurrIcon := "drivingHome";
) Q+ N5 ]( _# L# j @.DrivingHome := true;
' M/ L6 ~5 F; W( T; r end;
5 {& V/ a" W7 u9 o, ?' A3 J else -- the vehicle @ is empty, both vehicle and part are in the same dock station9 d7 p9 v M& E8 U* g4 b( @! b; Q
part := @.transpOrder;% `: Z; H" ?3 q m, A9 ?0 l
part.move(@);-- load part
5 x5 H; j6 A# z0 F1 C @.CurrIcon := "load";
" |$ W( D; y# } GlobalDistObj := part.globDestination;" a: d: q; u: b' K
assignLObj := rgmanager.rgAssignL;8 S8 x% P2 C9 M; |+ K, }3 Y
row := assignLObj.getRowNo(GlobalDistObj);
h" \+ }" n" y2 N if Row = -1 then -- since 70: @0 P/ q/ R8 m6 W+ }& X
if lan=1 then
0 a# K7 o( v3 E, H5 |8 H+ G promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
- p( _ G! ]3 k, C to_str("in der Andockstation: \"",?.~.name,"\""));8 K0 I9 G0 W: K. t
else
( N0 ^5 ]4 P9 C9 y2 A( l r7 Y promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
" t8 r: ~- ?# @9 ?& ] to_str("in docking station: \"",?.~.name,"\""));
/ e! v S" e$ j2 r" @: B' ~ end;
* S% ]2 q$ ~6 W# R5 I else
( w% Y" k( {4 z; S. a: r, f/ ~3 l. a @.Destination := assignLObj[1,row];
* x( a7 U7 x; u9 Q1 n end; + X+ J/ A3 W1 T! _! _3 b! M
newDirection(@);: \! _3 s) r7 y" ~
@.HasOrder := true;
. n3 C- V& q! O2 Y9 { end;( B* O! Y( k4 X: a
end;& R. d5 C! H- b$ U" }
end; -- of the method. L; k8 ^/ _% ~% }
|