/* called by: entrance ctrl of the object 'track'& Q) R' L. W+ \6 R
*/
! t2 D4 E* t. W! z' d4 Lis2 Q" U$ A9 |8 T, J6 H. L. t$ b
part, GlobalDistObj, assignLObj:object;row,Lan:integer;
' G0 b" W4 ?3 S. }! z4 Fdo
1 T9 [% x2 F, P9 \, Z; y Lan := rootfolder.Internal.Tools.AOLlanguage;
W' J' V% a O6 X if current = @.Destination -- else return$ y/ i' a& ]; X& i/ e1 p8 U
then) \( p3 a I$ Q3 D; M5 M% b1 u
@.Destination := void;
7 C2 |* i6 M7 V% K6 K& [ if @.occupied then
2 l4 C& d6 m# b2 E: v& d& Z part := @.cont;) s6 H. ]7 p( J, U
@.transpOrder := void;
' g( L& X' u/ `# [ part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,' y; h8 L* x& G
@,root.eventcontroller.simTime);/ T' c1 B% v0 z" i, \) q
@.HasOrder := false;, W7 T6 L& A$ x. e
@.DrivingHome := true;
: M) c: g* d1 F* z9 ^) P$ B rgManager.tryToStartTransOrder;0 G7 o% {& d" V# W; k- ?; ]2 S+ e
if @.Destination = void1 H0 H9 ~ i* Z$ X1 ~3 y
then -- no transport order for vehicle @
* u9 ?5 [* [3 B" q k @.Destination :=+ M' i, t4 I9 v$ L9 U7 ^* B3 ~5 y
rgManager.nearestFreeStation(@,track.~);0 S" r% B/ C, p
newDirection(@); $ G, X) @( F- a3 o& f; m5 x8 T* l8 m
if @.Destination /= void then
6 {1 b. e& Y* B! n! _4 t+ A5 n @.Destination.NumReservation :=
: t. }, @, J( H) j2 z$ j @.Destination.NumReservation + 1;
- X0 Q; `4 {& }5 ?. c/ Y, x$ ` end;& j% E, \: d5 d( K
@.CurrIcon := "drivingHome";
+ v$ K! j- O0 x; z8 M/ d3 \( V @.DrivingHome := true;% \+ c& A; D$ q+ U1 t/ D
end;
5 p$ j1 @- f" b( _9 S% Y else -- the vehicle @ is empty, both vehicle and part are in the same dock station. x0 Y& m, ]* v- l! E
part := @.transpOrder;
: t) Y! t: a& X e part.move(@);-- load part
" X, h0 r. h% |8 K) H6 M1 _ @.CurrIcon := "load";
' M5 ]# i2 x' N+ L/ b! B* I4 @0 G# c GlobalDistObj := part.globDestination;
* p# V1 f1 D V9 K8 I assignLObj := rgmanager.rgAssignL;
8 C& c$ q0 I0 K5 z, d8 W row := assignLObj.getRowNo(GlobalDistObj);5 S0 C9 x" l! q" r
if Row = -1 then -- since 70
5 ^; r4 i/ B! i1 A if lan=1 then' z) z/ ^7 i G2 A# ~. X
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),( O O. D: I, F& ^: x
to_str("in der Andockstation: \"",?.~.name,"\""));3 }8 \+ { P2 g7 U& \
else
) {) ]# g& ~! {$ h promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
/ Q0 j3 k1 b Z, `% ? to_str("in docking station: \"",?.~.name,"\"")); ; y! O2 n8 n/ J2 R9 g. {
end;5 f) H4 Z9 y! X9 X
else
6 o' T. y1 l; w+ X; S @.Destination := assignLObj[1,row];
1 @2 T4 m: d! n# S1 X end; ; Q( ^+ h5 o1 a1 U) {* }- ^7 k
newDirection(@);! q. Z |. Q' j" J; b
@.HasOrder := true;8 |4 e2 y6 d W1 c
end;
1 m9 b) k% j- c- y0 N end;2 {. _1 V9 K2 l7 e, T, y6 L
end; -- of the method
3 Q+ ?' {' b( K) Z' O- U8 T |