/* called by: entrance ctrl of the object 'track'
0 {5 J( l+ \! U' e: B z+ \4 f" X*/! U& k n8 i% i' t+ i
is
& |2 j0 z. F7 S7 l7 ?6 w part, GlobalDistObj, assignLObj:object;row,Lan:integer;
* ]8 u" ~$ e" [2 v" @2 j4 ?8 ado
5 s6 W# W0 C( b! v Lan := rootfolder.Internal.Tools.AOLlanguage;* W* y7 X# o! O' y$ e; S
if current = @.Destination -- else return1 d; H5 a; h7 ~6 @! C% d, a* h
then. x$ \# a v/ M1 u# X- L
@.Destination := void;
6 ~7 n" d/ g n1 L; @ if @.occupied then
% g$ _! K2 m( X+ Q6 a9 @; i7 c9 G part := @.cont;
4 Y3 l9 e& _& u, e @.transpOrder := void;
/ u3 ^, ?$ z2 q( u+ o0 `- e8 { part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
- I. s S$ _% T# @" i/ x% ? @,root.eventcontroller.simTime);# @& @ ^ p& o& ^& c& v/ l, c
@.HasOrder := false;$ S6 O5 v5 o7 r# t; S. K
@.DrivingHome := true;
5 n; d' D% \9 j, y; l rgManager.tryToStartTransOrder;
' m, N& M/ |5 T8 [9 v if @.Destination = void
! A, w% F% Q$ M; ~4 j& V then -- no transport order for vehicle @
( ]1 M& U& k! ?* I# N @.Destination :=: b. i9 d1 A4 {$ A' L4 y# `+ L
rgManager.nearestFreeStation(@,track.~);
8 i# \3 ^' a$ L: y# j" U newDirection(@); * S0 i: ^% `* _% f0 `2 q7 A
if @.Destination /= void then
' J. |+ a1 Y1 } @.Destination.NumReservation :=+ F; D8 {) J& Y8 C
@.Destination.NumReservation + 1;' u) Y! B$ h: ~! Z7 c" ?" o, V" n
end;- ?- E* s) F+ u/ ^7 @6 ^4 W2 H
@.CurrIcon := "drivingHome";5 h; R8 U: p; a) k
@.DrivingHome := true;5 K9 `+ U0 m& u! z# Z4 j
end;
9 k4 E1 `8 L% j& Y$ b else -- the vehicle @ is empty, both vehicle and part are in the same dock station g" x" z Q5 n l
part := @.transpOrder;+ W# D; \% ^' P
part.move(@);-- load part$ F6 b& z; \5 C
@.CurrIcon := "load";
7 C7 @ c: j; u3 l6 k" i- L GlobalDistObj := part.globDestination;
' s, B6 ~; }6 B% K$ \ assignLObj := rgmanager.rgAssignL;8 g: A* ]- T. b4 {4 O2 e0 A
row := assignLObj.getRowNo(GlobalDistObj);9 o3 W* O! o# P3 a. z$ q
if Row = -1 then -- since 70
$ R& u4 W: F2 Z4 _& Y6 P9 g if lan=1 then3 y! O3 q* C3 ?9 f8 w/ b- V. P
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),* p4 X, C! j/ g" D1 ]
to_str("in der Andockstation: \"",?.~.name,"\""));; Y0 h! q6 Z2 P7 ~2 w+ {2 C
else; Q% }5 N7 V8 {1 N
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),9 {5 {/ h0 z$ w. V2 R. G2 ]
to_str("in docking station: \"",?.~.name,"\""));
" f- }6 ^1 L7 v end;- T4 N0 I6 g4 b. H5 x
else- N" P; q9 m, \& f7 @! P9 S- l
@.Destination := assignLObj[1,row];
& ~! I( g. y0 [+ m; H1 ~ end;
" F, v; W: o3 J; ~( J newDirection(@);! } }7 N4 I0 m. j x Q
@.HasOrder := true;7 V+ R$ t8 v- x& A% V- ^% @) S% P
end;
0 a- @. l7 \* x% u end;5 M) m; s/ _& E' @# L- b
end; -- of the method$ r$ k+ `7 r0 P% N! H( |/ T
|