/* called by: entrance ctrl of the object 'track'4 ]! l. D/ K. v5 {- l0 B
*/
; C0 N* `! ~- {0 v6 O7 N$ {is
8 T/ a) ^' D; x( Q part, GlobalDistObj, assignLObj:object;row,Lan:integer;, b d c6 i0 L
do
) {0 @! ~2 z. l9 \8 L Lan := rootfolder.Internal.Tools.AOLlanguage;
& C$ P' } T& z3 m- s3 n if current = @.Destination -- else return
& T+ v/ L% ~& G9 r6 _ E then
' N9 g) W7 F! q3 G) w @.Destination := void;9 l5 s2 v3 q! h7 z2 S
if @.occupied then& [( h+ A& S) q2 E
part := @.cont;1 h. Y% ~$ K" v+ K7 L" N4 G! N
@.transpOrder := void;" }4 x% o- K" _% s6 B* n
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
4 j" ~; A( n1 c* M. A# | @,root.eventcontroller.simTime);' t2 M7 h# J- _7 s
@.HasOrder := false;9 T$ X4 b! M, q
@.DrivingHome := true;9 p1 I8 S! v* x0 B6 u
rgManager.tryToStartTransOrder;
: n) M3 p% t( V* M; u3 \) r$ s if @.Destination = void0 @/ @* V6 x( S) r! U% W
then -- no transport order for vehicle @
( d& a8 H4 o4 y7 j3 `, A: _( H- X5 p+ B @.Destination := q5 j7 M/ q5 M% b
rgManager.nearestFreeStation(@,track.~);
2 O( c1 h% |. A$ W9 [2 `* T4 ` newDirection(@); 3 m! f1 B. D5 y# F1 S9 u$ d$ p
if @.Destination /= void then
' T2 y. G9 y f" P( l5 R) A. U$ Q @.Destination.NumReservation :=+ w8 M: Z/ K! j. w
@.Destination.NumReservation + 1;
) y, t- b3 x5 S) l2 k( X# V9 l. I8 k end;
* ?2 _/ H+ o+ G- [4 s) t, E9 E S+ d @.CurrIcon := "drivingHome";$ L2 f( V2 \( m( H+ X, c% C9 O
@.DrivingHome := true;! j) ^+ K, a7 [. l4 b
end;' l9 D7 I T1 c# r- m7 k
else -- the vehicle @ is empty, both vehicle and part are in the same dock station/ W* s2 o# H6 G, ~0 O5 E
part := @.transpOrder;" q( G2 B2 D' m; h
part.move(@);-- load part
+ J/ k& U2 J- l! W; A* Z @.CurrIcon := "load";
% e, j: i1 I8 z! k2 Z# y GlobalDistObj := part.globDestination;
7 k$ l8 h, ] `+ K* A s. f assignLObj := rgmanager.rgAssignL;. W9 Z8 e+ X" t I# u7 X$ A/ z
row := assignLObj.getRowNo(GlobalDistObj);
7 {" p/ K; Q8 r5 a if Row = -1 then -- since 70) \9 b% M8 n. m0 Z0 }2 U& m
if lan=1 then: T' a D, Z, _, s0 ]
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),9 s2 V" i- D; y/ J
to_str("in der Andockstation: \"",?.~.name,"\""));/ r+ b( T" b4 X2 v
else
, o0 R1 Q8 U/ p( d2 K4 x promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),; V( U' U+ ]0 E' \& E
to_str("in docking station: \"",?.~.name,"\"")); 0 L3 t( E |: w. b
end;! F* G: {% q' Q4 M
else
+ d% |) h) a# [ Y @.Destination := assignLObj[1,row];; Q2 y# G3 O+ h I4 {- {
end; ; j+ v% U7 p, A; r( e9 g7 m" J! g
newDirection(@);& S K9 _, Q. u
@.HasOrder := true;% ^- m: i' W+ v6 C
end;( R7 e# V7 h: I1 q# x
end;
& k% x, N o- T, {/ s* H1 X# h2 H& vend; -- of the method# k! x/ A9 T; R
|