/* called by: entrance ctrl of the object 'track'
3 a' D9 i: C- H0 Q7 G) U6 } k4 E/ o*/9 X: {& y [2 W8 b2 f. J# B
is
8 d. s; @) P) @8 F( U( n part, GlobalDistObj, assignLObj:object;row,Lan:integer;
% H. T2 B' H& e5 o3 `do8 v! ?& h! C1 F
Lan := rootfolder.Internal.Tools.AOLlanguage;
( a( g: [4 L8 u/ K4 P if current = @.Destination -- else return: X; b! x& b* R, T% X& s/ N
then
; z& U6 c+ }; ] @.Destination := void;
5 b: P1 w: _/ y- x7 t! q) [ if @.occupied then5 Y" ^+ l) |0 J- D( p" W! x# I: S+ _1 C
part := @.cont;% B7 w2 J) Q6 s7 ^+ ~: X
@.transpOrder := void;
9 l. a* f; i) u6 w/ c part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
! f+ b- }6 |8 k- D4 ?( e9 ] @,root.eventcontroller.simTime);
: C+ d* e4 L$ }% e+ g @.HasOrder := false;& n) `1 d7 h# w3 s# q3 i0 J# L( j
@.DrivingHome := true;. s; q' O+ g y P% Q( u
rgManager.tryToStartTransOrder;
) u" t) Q4 ^. u7 I0 M$ G, y if @.Destination = void9 R) T( u! x Y) M* A" [3 t) Q
then -- no transport order for vehicle @6 _$ ~9 Y/ k9 Z2 y6 I% f
@.Destination :=8 }0 o+ S* k, E: [
rgManager.nearestFreeStation(@,track.~);
}9 @* Q; H& `) d4 i$ ] newDirection(@); $ o2 s3 Q q; d# |: `
if @.Destination /= void then
7 u. T. |6 | v* T3 x4 t4 F; x @.Destination.NumReservation :=! m1 O+ [' f# b5 }0 ~2 m
@.Destination.NumReservation + 1; D/ C2 i% r9 K! e0 `; B' D8 A
end;
" j" Q% ]& c6 J' o8 m9 _0 _ @.CurrIcon := "drivingHome";; d( ^9 ?8 x2 q3 F2 l$ [7 _- i
@.DrivingHome := true;0 v( m& n. u4 W* P
end;$ S; u. m3 d( D, D4 ]7 V! A
else -- the vehicle @ is empty, both vehicle and part are in the same dock station0 M3 ?+ x' d0 m: r
part := @.transpOrder;1 u: ~% X$ S- K5 W5 [+ ?6 H/ L0 e& x
part.move(@);-- load part
" U3 s7 p) b0 f& U% B @.CurrIcon := "load";
* p& A* l, B# [+ E GlobalDistObj := part.globDestination;
# k- J2 A- r5 Q4 Q& b2 \7 I assignLObj := rgmanager.rgAssignL;
- G0 c0 h g2 [+ B row := assignLObj.getRowNo(GlobalDistObj);# d# f2 D) T3 d' D! U
if Row = -1 then -- since 70, q$ ?5 Q+ `! s, ]; K( o5 o4 H
if lan=1 then# @- @+ y; y/ J' ?$ q, D
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),% K$ M, V* R7 x
to_str("in der Andockstation: \"",?.~.name,"\""));8 K! o" a# D6 z- E1 ~
else
7 X( v) ?0 |7 j! Q# n promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),; \% V2 l* [: L& p, g5 F( ^, Y
to_str("in docking station: \"",?.~.name,"\""));
1 f/ F! t& P/ [6 \0 J end;
! S2 M/ c5 g# t$ D* |8 R. j) T else b% k5 a0 i$ I& _& C) e
@.Destination := assignLObj[1,row];6 k1 B n4 o! W4 g, H
end; 5 X) q6 e0 n# ~3 x9 S/ g7 L
newDirection(@);
, E6 l0 E4 C G- J) c, s3 @8 w' P/ ` @.HasOrder := true;
1 Q6 r5 u- e8 K0 ] end;; _' Q7 ^4 G9 X' A9 q6 \
end;1 w# F m6 k# l& _
end; -- of the method- B/ A6 \+ V) `6 P4 G3 l' A% O
|