/* called by: entrance ctrl of the object 'track'
- L8 M1 a4 C( u$ x* a; s$ |* ?& A*/0 v9 s& ]' O/ ]( C
is
) ?+ q8 x! Q! E6 Y$ D0 f part, GlobalDistObj, assignLObj:object;row,Lan:integer;
8 V/ i) e$ ~. O7 e1 Vdo5 T) E5 c M6 ~8 w& O3 G$ |- Z" h
Lan := rootfolder.Internal.Tools.AOLlanguage;" F" K2 [- f' K' r4 K9 S/ ?
if current = @.Destination -- else return
4 e# ~* J: X4 x( p then
* m6 e1 E$ o$ y* M. S- A @.Destination := void;" h. Q4 ^- y! o
if @.occupied then
1 \4 b- E D) l/ W4 t8 s part := @.cont;( H2 P* R: u8 W
@.transpOrder := void;! F+ O2 _) ^6 V. p. [- d! ~) Y g
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,0 {; U9 J( i8 G3 g- l
@,root.eventcontroller.simTime);
6 ~3 [ H8 G! O- Y4 \9 j" d. a { @.HasOrder := false;
' K" @. l# z0 e+ G5 i$ b: X6 a# j0 v( v @.DrivingHome := true;% p( [2 ~' e% S. o5 R
rgManager.tryToStartTransOrder;
8 _/ t5 e7 @! ^5 f; O( }$ Q if @.Destination = void
3 \; E7 c& i6 ~) \; q+ H R8 q then -- no transport order for vehicle @
9 h( S, n, R. M# u$ i9 v* h @.Destination :=
. ~/ Y" i+ R( f8 O! z rgManager.nearestFreeStation(@,track.~);0 `) g7 j( ?6 m+ P- M2 Q0 n
newDirection(@); & k) G! f# g" j3 A z: i! k
if @.Destination /= void then) o% d W2 Q# L0 {* N2 a/ T8 C
@.Destination.NumReservation :=
; f5 s7 e( K1 ]5 [! J3 t% Y @.Destination.NumReservation + 1;" |. r& t5 \3 P0 V$ i* E
end;
+ ?: N& ~) _/ f6 o* |' ?+ w4 ~$ M% C @.CurrIcon := "drivingHome";
5 H4 i( i/ v7 y @.DrivingHome := true; N1 U' c0 {' h6 v; ^8 O4 h
end;* v' }4 Z: J( w$ S6 x6 x. X$ h2 ~+ p
else -- the vehicle @ is empty, both vehicle and part are in the same dock station( x5 A+ {0 \+ l7 p9 g
part := @.transpOrder;: }% \% m0 d) p k8 p
part.move(@);-- load part% X# {4 V% B1 D8 }9 j; t4 Z
@.CurrIcon := "load";
' I2 m; T& @( x4 o9 L GlobalDistObj := part.globDestination;/ T& Z. U5 k: U; M) N$ x% J
assignLObj := rgmanager.rgAssignL;; o4 |8 A5 }; W, W, p
row := assignLObj.getRowNo(GlobalDistObj);# n4 c7 _( K j k' j* t* T
if Row = -1 then -- since 700 C& _4 l" P! w* }; G; k+ u1 M/ {4 I
if lan=1 then% {4 c# W+ x3 x) r! X$ h$ k
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),2 p# _& R5 Z" C1 q
to_str("in der Andockstation: \"",?.~.name,"\""));
& A" j2 C$ N* U a% d else
3 I4 a3 P* b. q promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),9 a. m X' ~# [! D# b7 X! }
to_str("in docking station: \"",?.~.name,"\"")); & O0 U2 j7 H. g5 Z
end;- W& d2 E' r3 C% ]* B
else
/ f% }5 x6 H2 f% k9 ~" a @.Destination := assignLObj[1,row];
: b% V: g) U, Z# f6 q5 @ end; 2 l0 c( n0 E" ?6 M0 V' H
newDirection(@);! }% V! o, [: w0 p4 q0 n& C( j8 ~
@.HasOrder := true;
3 I! A% q/ [( I4 G$ _+ z7 g# J end;
5 G2 f7 t+ ?* ]$ L end;& R9 w* _/ V9 Y
end; -- of the method
4 o! F2 Y" S) S |