/* called by: entrance ctrl of the object 'track'
7 [- k: i6 |/ p* J$ I1 W*/
- z5 e$ L' F3 X& R; I: r. p8 Ais$ |4 T$ T H) M. K+ ~6 ]
part, GlobalDistObj, assignLObj:object;row,Lan:integer;
1 l6 b' J0 Z7 _& w5 | qdo
; h3 ^5 H/ Y L Lan := rootfolder.Internal.Tools.AOLlanguage;, Y9 H- Q& v/ d: k5 ^/ K# Y
if current = @.Destination -- else return
; Q% D5 A1 l" P6 _, d then
% b, U& n: t0 y3 r3 S @.Destination := void;
[" ?0 d. l, l# [$ C if @.occupied then0 Z# {. r$ e3 a6 e1 B
part := @.cont;3 v) X. r2 A, K3 U# ^# x
@.transpOrder := void;
* E. f' N* O! ? part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,* D. e4 ^/ ]' [$ U6 s# a/ l
@,root.eventcontroller.simTime);+ o6 z) h$ Q6 { [3 Z
@.HasOrder := false;
) r% J. U% u- [ @.DrivingHome := true;" Z5 l3 H; R: Y* C+ q
rgManager.tryToStartTransOrder;. J7 S1 z. d/ B7 Y T+ I5 \
if @.Destination = void$ E" O# ~9 P' k3 e
then -- no transport order for vehicle @' l1 Z6 H$ x& H
@.Destination :=8 u5 t) v5 y: s! L
rgManager.nearestFreeStation(@,track.~);6 h8 H' b* K* R
newDirection(@);
5 Z3 W: A1 X4 ^# D4 [ if @.Destination /= void then# [( u+ l+ A* K! j& D0 ]7 ]
@.Destination.NumReservation :=
+ |) x3 R( G. _' C @.Destination.NumReservation + 1;" ]9 ?3 g. E6 X% D4 b, W" ~
end;7 B' o3 ~: h, I
@.CurrIcon := "drivingHome";
$ ` y$ i9 K" G7 R' t3 [ @.DrivingHome := true;
+ @$ C8 B* U1 p$ y: W9 u* y end;# G+ o' U2 n3 z8 P4 `
else -- the vehicle @ is empty, both vehicle and part are in the same dock station
% I k$ D; g8 x; G: k4 Z5 a5 a U part := @.transpOrder;
& Q: a5 \, J6 h% A part.move(@);-- load part. a9 G! H: s4 i' f! V
@.CurrIcon := "load";/ v$ t) k( ~. N' b& N
GlobalDistObj := part.globDestination;
/ ~8 I8 B5 d9 U2 {- ^ assignLObj := rgmanager.rgAssignL;9 @$ t& c2 {9 }
row := assignLObj.getRowNo(GlobalDistObj);
3 N) { D, x* X9 K if Row = -1 then -- since 70
0 Z& i! Z0 u7 R if lan=1 then' G, |, Q H/ w' ~8 F7 A/ S
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
1 M5 f8 U9 E W3 C' z& L3 B$ n i+ u" _ to_str("in der Andockstation: \"",?.~.name,"\""));$ c% Y! ?, A( q: P
else3 A$ k+ P7 C' T' U/ O, c2 K
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""), u" `0 Z+ B b1 F3 \, G2 [
to_str("in docking station: \"",?.~.name,"\""));
) d# \$ ^+ Q7 h& a: V3 d5 L end;
@* Q, I x& N# r, M% ~1 U' M else% x. [0 m8 N* f2 w& m# H2 J$ `7 m
@.Destination := assignLObj[1,row];
* B& e( D* e6 K4 K end; - _. v/ K! i+ `8 Q( j, l
newDirection(@);! G6 n( j0 P8 T5 @
@.HasOrder := true;- R5 U4 T, F- g# k) Y
end;0 V( f" n$ g* `/ J5 K$ L
end;
+ I$ S" k8 `) l) Kend; -- of the method; ~7 {4 {# v, f, U! u
|