/* called by: entrance ctrl of the object 'track'
' K5 @: q6 ^4 m) s*/
" D b3 F' F8 v2 k! Dis
: f8 }2 R6 L. G& _/ |6 J1 K! J. ~ part, GlobalDistObj, assignLObj:object;row,Lan:integer;( Q& N9 Y7 S1 P
do7 W( D, R, ^7 `3 [+ V
Lan := rootfolder.Internal.Tools.AOLlanguage;
# U1 \, N% q% ]; R if current = @.Destination -- else return- J; n1 Y3 Z- _9 I+ [
then+ J* Y. B& I) m5 }; V
@.Destination := void;
- s1 \$ ~7 X9 m, ~ if @.occupied then
( T U9 z* W) F' M; } part := @.cont;
+ K+ F0 B' x, V$ r' l9 \ W @.transpOrder := void;$ H% h8 e" N3 i" ?( E' N
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,% z1 ?- w) _; g, k; W: F5 Y: t& s
@,root.eventcontroller.simTime);$ p: S+ C; |6 D5 o) B' B/ F s/ c* |
@.HasOrder := false;3 I' G, X8 m' M7 R0 J
@.DrivingHome := true;, l( m4 L |, J% x
rgManager.tryToStartTransOrder;
, i3 Q- m( f2 X) L' W if @.Destination = void8 f# }; B+ T5 a/ ]' x
then -- no transport order for vehicle @9 |# b$ z& ?8 p' a
@.Destination :=7 x; O0 l/ A) ~( R' c+ b
rgManager.nearestFreeStation(@,track.~);* |9 v: |; v5 N9 e j6 S( Y. G
newDirection(@); : o( s( M, b6 u) G4 ~, e' J* o
if @.Destination /= void then& L/ }% r2 I8 ~- K
@.Destination.NumReservation :=% ?7 s! J2 X# C3 T+ x
@.Destination.NumReservation + 1;# f& K2 }& G; K' F: t# ^$ h
end;
/ L9 Q- x+ [$ Z9 ?+ p9 P0 ] @.CurrIcon := "drivingHome";7 U$ G- N' ?5 `$ @3 ~
@.DrivingHome := true;
5 o* {- c: g* Q* Q8 z end;$ S! c% L# e! t: d" u
else -- the vehicle @ is empty, both vehicle and part are in the same dock station2 P- H/ E$ ^& S/ l% m
part := @.transpOrder;! P' H3 o: c/ g' j$ O4 d
part.move(@);-- load part
$ P. q$ l4 i! W5 ]* f4 C @.CurrIcon := "load";! [, R9 j0 P. V/ T- R1 ^
GlobalDistObj := part.globDestination;
& ^/ k1 E6 S: l# H assignLObj := rgmanager.rgAssignL;+ E! g; w# h! b- a& W
row := assignLObj.getRowNo(GlobalDistObj);
7 d0 {8 A4 t+ a2 _ if Row = -1 then -- since 70
% |4 y0 B4 ?: l5 m if lan=1 then
5 u+ f7 b5 Y' a7 R( h( J0 ~/ y promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
' W( k0 L" U8 Q8 K$ S) O Q to_str("in der Andockstation: \"",?.~.name,"\""));# E4 x6 d V, i0 q6 a6 @
else+ b" Y2 w4 W: m+ _: {; v `+ ?
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),( i5 ^; g3 R! F
to_str("in docking station: \"",?.~.name,"\""));
% E, K, `3 e6 x) `% Z7 M; y end;
# e a7 w4 A/ z1 w/ C else' z. k) x5 y* ]- I) G
@.Destination := assignLObj[1,row];
8 ]5 j. W) r, f end;
) `5 Z# G' p( @1 x( n \% D newDirection(@);; L% _7 {) A! c! Q5 U
@.HasOrder := true;* I+ U8 f, E, k$ S- l8 C* S5 h
end;
% m5 y1 {6 P* G( a/ F9 t" b end;; B& X; N x% s- c
end; -- of the method
( X# L7 j. m& Q2 X+ w' y |