/* called by: entrance ctrl of the object 'track'
P! G( P% `5 s/ {0 ` m" O*/
( |9 x6 p! s3 mis4 e8 w( v+ A3 B. o. M# s. x8 D7 X
part, GlobalDistObj, assignLObj:object;row,Lan:integer;% D6 p( y v6 U- N2 m+ i# A
do
; D4 Z$ ~$ f3 x% F$ h5 p( u# V Lan := rootfolder.Internal.Tools.AOLlanguage;6 d# v& S) M# S& q( {
if current = @.Destination -- else return
% o6 }( h2 b0 u% { then
3 [! K$ e) B! M* ~4 `! p @.Destination := void; P: ?6 g; n* Q' y
if @.occupied then& m4 } L" A9 V7 p7 t! x6 Y: r
part := @.cont;
- v/ A0 i- t+ A2 W- l8 Z/ V+ ` @.transpOrder := void;
% N( G( c6 a" i. e2 m' D part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,3 S2 y# r/ F, b/ Q) Y, H
@,root.eventcontroller.simTime);. s$ J) y/ {0 f
@.HasOrder := false;, G: b- x1 b' F% G$ F2 W/ W
@.DrivingHome := true;" D( I$ z1 _- |3 n! u m1 O
rgManager.tryToStartTransOrder;3 }7 P( k J5 | w8 C
if @.Destination = void( E5 M; M( B+ u$ O. m, O8 \5 P( \
then -- no transport order for vehicle @
7 {! s/ s& v6 j& Q' B/ e/ {/ w @.Destination :=
$ t2 B/ k* @ @7 D7 E K& P rgManager.nearestFreeStation(@,track.~);
6 e% K/ a9 _3 k3 J9 ~0 ` newDirection(@);
' M5 Q. H3 M" u5 ^ if @.Destination /= void then. C9 d* @+ |/ Q& \. c
@.Destination.NumReservation :=: m# m: T+ u5 i" y- q% W
@.Destination.NumReservation + 1;& J: x" |" p1 U
end;
7 A% k4 r' c/ J. H0 z @.CurrIcon := "drivingHome";" n4 D8 @: a- d: B
@.DrivingHome := true;
3 Z& y% c ?6 N c8 u# c: W' n( w0 d end;( ^* w# w% b7 q8 n8 w! B6 U
else -- the vehicle @ is empty, both vehicle and part are in the same dock station
+ {2 r! w" O3 [# q part := @.transpOrder;8 U% N& h) f, q. B
part.move(@);-- load part7 [# z1 @# C1 W" T7 p
@.CurrIcon := "load";
1 d5 |7 g( D' _6 L$ K! a7 }. i GlobalDistObj := part.globDestination;% V/ J% j2 P* t6 z C6 G
assignLObj := rgmanager.rgAssignL;- q# F/ R# o8 G* A7 K$ U
row := assignLObj.getRowNo(GlobalDistObj);
+ S) }3 Z7 r; [ if Row = -1 then -- since 70
* d8 o9 r+ j! [- k1 ^/ |3 d4 Q if lan=1 then f* i. H" A! U9 F; n
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
) z- h5 ^9 N9 _; G to_str("in der Andockstation: \"",?.~.name,"\""));
9 p0 K/ N& W' c. H% O8 s9 L' g else7 r4 [5 K. [* |# g8 L3 C5 O7 {( E
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),; y! ^, U) C4 f
to_str("in docking station: \"",?.~.name,"\"")); " {* @8 F0 T0 c' ]6 L5 J
end;8 p, f: j3 P6 t. z$ d) b M. [
else
) U. |' q, }: J1 a* F$ _( Q @.Destination := assignLObj[1,row];
$ W2 k: @8 P: U- x, {8 N end;
9 C0 H9 e$ j+ K9 } newDirection(@);
( h% i% ~- R8 o' g- [. \ @.HasOrder := true;, y- {7 Y/ n l2 E. U8 r
end;
: x7 l! Y7 a% N6 @ end;% b# ?; c6 K+ g) J; _
end; -- of the method
/ d4 z1 u# \( x- B. Z |