/* called by: entrance ctrl of the object 'track'
5 \3 r/ _9 o* Z- Y*/
1 J$ s8 U! @2 F5 ~' v ?* ais3 }9 p! T/ | f
part, GlobalDistObj, assignLObj:object;row,Lan:integer;8 X: x$ t/ y/ F) `, f
do7 @8 p7 a9 H$ r3 n" F/ K
Lan := rootfolder.Internal.Tools.AOLlanguage;
+ y' s* {8 X F; L; F6 M8 R if current = @.Destination -- else return
! G2 \+ W& @/ O o) Q- ? then: `4 C7 D- I* \) H
@.Destination := void;
% L, Z- w; V% }: i) i( [. \# r if @.occupied then5 a* a! b) m) q0 K* p9 A
part := @.cont;, ], ?7 f2 B4 \1 Y1 B
@.transpOrder := void;7 n% c. f! [8 W0 V: V
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,# ^# |8 w/ u6 Y8 B
@,root.eventcontroller.simTime);/ L" S, Z( |0 I
@.HasOrder := false;+ V3 c/ X+ t" Q/ ]4 M" v
@.DrivingHome := true;( _$ ^- }8 W* t; l+ v1 \4 m
rgManager.tryToStartTransOrder;7 e+ \, w* H8 t3 j
if @.Destination = void
3 ~+ [' M; G# O* d. ], [+ R then -- no transport order for vehicle @2 J+ _9 O2 n7 \6 V" s8 s c4 a
@.Destination :=: |4 G% h. Q% {8 I3 T r
rgManager.nearestFreeStation(@,track.~);- x0 C1 ]" C3 c4 C P
newDirection(@); 0 B: A, u" | r9 N* I9 [9 u- F- @
if @.Destination /= void then
* k: u$ |5 h f5 g @.Destination.NumReservation :=
3 s& L# D3 f) t4 h+ Q$ s @.Destination.NumReservation + 1;
; ]) N4 o1 E b/ e) W& N end;
$ W5 | U% |$ }9 W @.CurrIcon := "drivingHome";
% S3 L* \! r% ?0 e# {0 ~ @.DrivingHome := true;
) n/ y! o, `" r' D8 {5 G! U end;
6 Y: O9 W0 `& s. F) v2 }0 u$ [6 [+ u else -- the vehicle @ is empty, both vehicle and part are in the same dock station- c% U6 g3 K! E* ~4 l+ J, e- w
part := @.transpOrder;( V1 {. d5 V" d- }( w3 i1 ?
part.move(@);-- load part4 G7 z3 T8 Y P" Q
@.CurrIcon := "load";
x4 c% k1 ~7 s k$ X GlobalDistObj := part.globDestination;
! ?/ N/ M9 F7 c% ~, X/ h6 B, R assignLObj := rgmanager.rgAssignL;
6 q L, ]( V. A& Q8 V8 I# u' r row := assignLObj.getRowNo(GlobalDistObj);$ w8 C2 S2 k: {& X( W" E+ {
if Row = -1 then -- since 70
) D% J* l' P; O! t" s if lan=1 then
6 W- n$ j: v, Q9 N: a8 ~ promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),6 s/ t0 z' z. c3 _ @6 M; I) n
to_str("in der Andockstation: \"",?.~.name,"\""));7 M! m7 g+ W: W
else
; W# l. A% V- s6 L/ L( F promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),3 A+ r3 c8 g) z0 t; E F/ m
to_str("in docking station: \"",?.~.name,"\"")); # m" J5 a& V0 F2 j
end;# o' W2 Y( Y, c: a: Y) t, t2 R
else& a0 M0 l7 W: U1 h( y
@.Destination := assignLObj[1,row];
* J: m, b# {+ j. m1 l# l end;
/ i, H5 z) `* }. f newDirection(@);. Y+ V G. D' j: g/ e
@.HasOrder := true;
% E* a) C8 u: a- A end;
8 c1 ~& \ _& @! \& L# o3 ]* K end;' X2 \: |+ N2 b& r
end; -- of the method
+ X6 _3 S% ]# I( a4 ?) }5 a% [ |