/* called by: entrance ctrl of the object 'track'
; ~5 k M2 |9 w2 a. k( }*/
9 z; m; v" O$ R) Vis
, y# C1 ~# u) H) U a part, GlobalDistObj, assignLObj:object;row,Lan:integer;' N' r% E. @" o+ q8 o; W/ ]) |4 f* H: r
do7 V5 T- h6 C4 L+ t0 r5 H, t7 A
Lan := rootfolder.Internal.Tools.AOLlanguage;
) y/ u# T% w0 b2 o8 M' P0 F6 [/ G if current = @.Destination -- else return ?# F0 q! t9 _
then+ R0 {2 a; }: x. K
@.Destination := void;+ `/ @$ E! M* m- k- ^
if @.occupied then4 L4 ]) D; |/ Z- q2 `* G
part := @.cont;3 f/ S* S" V! |4 A& P
@.transpOrder := void;1 P, A' X7 T$ a$ u K( r
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
$ W1 O) `4 V, T4 i U' E @,root.eventcontroller.simTime);
4 d! S! O! X6 u7 D; [3 m7 L @.HasOrder := false;
, K, S6 Q4 M3 \( m @.DrivingHome := true;
, @' D9 N7 ?5 H rgManager.tryToStartTransOrder;& e. n. G" W, g! X* R
if @.Destination = void
1 f0 I V3 I; j4 A% \- T! |* S then -- no transport order for vehicle @9 W' s& `! A% k3 Q
@.Destination :=7 b2 ^" n) d! i) S* y/ H
rgManager.nearestFreeStation(@,track.~);9 B' I9 B" `* C+ w: d- Z2 T2 n- \
newDirection(@);
8 U" b, p, h$ t$ y& J if @.Destination /= void then
& V w2 Q& A+ q' _8 Z0 O1 Z" [ @.Destination.NumReservation :=
4 _; R7 V0 ]5 R @5 T6 U, ~0 i! D @.Destination.NumReservation + 1;, s9 f. x3 X* i4 ~# T
end;3 Q' I2 v! |' G: p7 e" }7 Q3 X
@.CurrIcon := "drivingHome";. [( f4 c Y, H, w+ G- L
@.DrivingHome := true;8 _9 \3 p0 k* \- C! r% e
end;
3 h' K. p, K" U$ Q5 Q3 b else -- the vehicle @ is empty, both vehicle and part are in the same dock station
( T+ h7 o- s9 O, I' V part := @.transpOrder;6 B/ y8 d) N2 \
part.move(@);-- load part0 ~2 }9 K/ c& [2 [, G
@.CurrIcon := "load";4 P M3 v8 a1 r, E% y& e1 [, t
GlobalDistObj := part.globDestination;3 P$ K$ f) Q2 S: X( p7 j
assignLObj := rgmanager.rgAssignL;$ G& d% D9 l* E+ u7 F8 d% n- [
row := assignLObj.getRowNo(GlobalDistObj);
! n* L+ |: J$ D: k$ Y+ `) h+ T x if Row = -1 then -- since 70& w; G& ]4 @3 B" L: f3 _+ _4 N' z4 t
if lan=1 then
( B* E8 _$ X- Y promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),* ~# J+ X# B- M f
to_str("in der Andockstation: \"",?.~.name,"\""));
6 C$ P# o8 d. i else
; [* g1 s: J4 A; {8 P2 [ promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
" m/ ~- ~; v6 v: ~' j to_str("in docking station: \"",?.~.name,"\"")); . c N! N; o2 V; f: J8 {3 g
end;
1 P7 y% p; `4 q' D else
7 R5 l$ u$ Z! M. G! A. Y @.Destination := assignLObj[1,row];" _% c4 T D; e
end;
; D: i# O* G( J newDirection(@);5 s& I) k2 @/ ?5 W$ W: h$ |
@.HasOrder := true;5 P( }! N, t4 c4 y2 d
end;
6 A' z- |# ~# w% N. ^ h end;& A( N) c1 Q! |" V' O/ ^
end; -- of the method
: D) J9 |# f {- ] |