/* called by: entrance ctrl of the object 'track'
, V7 c9 | U% |6 ]& C*/
6 x2 p4 B: L+ J* h3 V% A6 _is
- Y+ N6 `# O' D$ \ part, GlobalDistObj, assignLObj:object;row,Lan:integer;
# Q- q" z1 c6 U! Ydo
z' J+ S- {% {- [+ P5 p0 q5 J Lan := rootfolder.Internal.Tools.AOLlanguage;
/ J' p$ c& G/ |9 v7 y if current = @.Destination -- else return; }. z2 { {0 d: K1 J" [
then1 F. M1 A3 r1 b1 C" y7 N( i
@.Destination := void;
* g N8 }9 b: m9 L. I9 w if @.occupied then) K% g; N1 p! i6 P
part := @.cont;
+ @# n/ C5 y9 P4 V9 G- n0 q @.transpOrder := void;
# ?* M+ k$ C2 ?% f% E! R/ C2 m8 R part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
% e. r Q" u/ { @,root.eventcontroller.simTime);
6 e+ [ K9 \/ u @.HasOrder := false;/ w) _& { P, \8 R
@.DrivingHome := true;" b% `. {/ P3 _7 Y5 n% c. U) Q
rgManager.tryToStartTransOrder;
* Z$ l) D1 ]: N4 R# p if @.Destination = void
. }% t3 j: I- L; ^) T# R! N then -- no transport order for vehicle @' e% t% T( j" _9 S6 D! H
@.Destination :=
* P3 ^5 a3 \4 v! p1 ~ X rgManager.nearestFreeStation(@,track.~);- b6 ?4 {; [& D* e
newDirection(@);
! r. P5 e6 F9 F2 T5 D. m$ y Q if @.Destination /= void then1 q: L0 l! t, H! k- d
@.Destination.NumReservation :=
9 Z C! [# ^8 O2 \ Q1 H @.Destination.NumReservation + 1;, P+ B! P. W2 w6 V6 Q. f; T
end;
$ f- d2 d. o7 q3 C2 q @.CurrIcon := "drivingHome";0 U5 U' N D1 j1 I
@.DrivingHome := true;9 {( D: N% F2 M5 }2 r9 z
end;
0 i) g' t& z4 c+ [# w else -- the vehicle @ is empty, both vehicle and part are in the same dock station
! R# ]+ q+ A6 k( X% e part := @.transpOrder;( ~) k5 I. [, b+ i
part.move(@);-- load part
& K' }( p( ?* L4 u k3 E4 s @.CurrIcon := "load";
E# X0 @9 C6 j. l# x+ o GlobalDistObj := part.globDestination;
" k1 d; h, C9 U! H+ T assignLObj := rgmanager.rgAssignL;- Y% w" D+ |3 p q2 z3 t" i
row := assignLObj.getRowNo(GlobalDistObj);
# A9 f1 B1 Q+ ]" G7 M; T" a" [& y if Row = -1 then -- since 70
0 f5 X0 W- w5 z2 O7 L if lan=1 then
2 d$ Y% C' B) J/ p/ a' Y promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
2 ]* G4 W) U+ I9 X! c6 V to_str("in der Andockstation: \"",?.~.name,"\""));+ J' e9 m' M$ X$ F. y1 [& S" y; j5 H
else j1 a: O$ g! Q' y
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
& ]7 S- z' A; y( \3 p2 h& s to_str("in docking station: \"",?.~.name,"\""));
/ a6 b( [) i) R& N& U4 p end; L' m* s4 c+ ]5 s
else
% Z" u1 C/ u5 |- G2 b4 o @.Destination := assignLObj[1,row];, Y2 s% Q/ H/ ?% L
end;
- V( P7 x0 N9 |' ?- R newDirection(@);1 v% i" P- Z& e/ M+ l1 e
@.HasOrder := true;# u/ p, \6 S! p8 F' x8 `# A9 G
end;+ h! j/ ]. J y* G
end;+ v4 g+ U1 b8 B) X
end; -- of the method
; z' ?4 R) _/ u" E- t" i |