/* called by: entrance ctrl of the object 'track'
; i5 S& h8 w' w2 T*/# j2 X7 W) S9 r! G& _. i
is( ^. d6 |/ X9 c, s0 E# O
part, GlobalDistObj, assignLObj:object;row,Lan:integer;) _) j. f' O' y* u9 h, _$ r
do
4 c; N$ |) [4 t* M Lan := rootfolder.Internal.Tools.AOLlanguage;) @( E! A; u$ I$ d
if current = @.Destination -- else return
, c( s$ t4 A4 G& @" f0 R+ d then4 ^# c9 q7 h; N9 [, A/ _
@.Destination := void;
) F/ U: A0 C/ b/ ?4 |! y3 D if @.occupied then
+ l; w% ^& `; H part := @.cont;
) N- Z7 [$ ]: G" O+ ?" M+ b @.transpOrder := void; ]6 _% A0 w# I3 ] n. o
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,: M4 C' F% ~! j6 G. x5 j
@,root.eventcontroller.simTime);5 P* N! X0 }2 ]8 ~7 i& x. U. u
@.HasOrder := false;: k# b8 L5 \& i8 l
@.DrivingHome := true;& S5 c3 v5 D/ s
rgManager.tryToStartTransOrder;% ?+ o9 ]; X- Y3 R/ I1 `8 n
if @.Destination = void1 `- S. {# R3 `# x" l+ X
then -- no transport order for vehicle @) K; i7 Q9 W% R7 g& B
@.Destination :=
0 x) d/ m8 O7 I$ O2 I) q4 f2 e rgManager.nearestFreeStation(@,track.~);
& k& S( J0 K% o, y! y2 |0 ? newDirection(@); ' Y, T/ ~3 U+ s9 {4 `
if @.Destination /= void then
6 m* o& N; {0 |" f8 Z4 g @.Destination.NumReservation :=
$ Y2 L( i0 i% f @.Destination.NumReservation + 1; v! N2 O2 g) A$ G3 N
end;" E' u+ U& }" @3 I& R6 E; n- \
@.CurrIcon := "drivingHome";
( R5 z0 B R0 ^ j( X @.DrivingHome := true;
8 X$ }- ], C1 r# ] end;
. Z3 J ]; Z6 t0 w8 B else -- the vehicle @ is empty, both vehicle and part are in the same dock station
+ Y& Y: E$ \$ g part := @.transpOrder;+ `6 [+ x1 z [. y! g4 @
part.move(@);-- load part
! N3 K! a f% _6 q; ` @.CurrIcon := "load";
7 n* ^5 y# M3 F# y5 _$ ~8 ~# T! B GlobalDistObj := part.globDestination;
0 Q+ M; l' `; }; Y) P7 H/ w assignLObj := rgmanager.rgAssignL;
! {0 p# X: ?& a d6 h. N row := assignLObj.getRowNo(GlobalDistObj);
; }& E( ]4 C% K% n+ Z8 k if Row = -1 then -- since 70
. e2 h1 C8 p1 X0 c if lan=1 then
; Z& Q* H. p- ], |; \ promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
1 x8 k2 l7 L! Z4 V2 _# G7 r6 u+ `4 T2 Y to_str("in der Andockstation: \"",?.~.name,"\""));- N \: o( M3 ?$ d
else
5 L2 K' z% @& k promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
$ J& }( i+ K" m) m3 h to_str("in docking station: \"",?.~.name,"\""));
7 b, O, i' ~$ o3 J0 r5 ~7 { end;8 J j: w6 z: }3 J- s. r
else
; B9 s: h. k( b4 Q7 h Y& [$ o8 E+ J @.Destination := assignLObj[1,row];2 F& m4 K% U) V3 @* v. ~. Q' h
end; 1 ]0 ?5 D! c! J
newDirection(@);8 O$ X; B6 @2 U% U0 ?; o2 }
@.HasOrder := true; l! k& F9 d8 P- j& J
end;
' T8 X$ @1 V" M/ Q& @2 b; a8 u4 C end;; `8 y7 A! A9 R7 }: S0 g
end; -- of the method/ G/ s- I0 A# i V5 y" h0 ^6 B
|