/* called by: entrance ctrl of the object 'track'
5 ~8 G: I% G# o# |# t*/; L. I: X0 g- p, d
is
) ~) U: t( g m& m- N2 F- r9 N part, GlobalDistObj, assignLObj:object;row,Lan:integer;* T$ l) S7 j, @9 v9 C/ F
do. G% N+ o+ M; e+ J# B5 Q: w7 `, j% i
Lan := rootfolder.Internal.Tools.AOLlanguage;. u7 n0 \) F7 N' J6 O5 b" V( L8 K
if current = @.Destination -- else return! F9 w6 n8 e$ d7 `+ ]3 \" N: d, I
then3 Z% v# q: l6 ?" ?! ~3 ~+ [6 K
@.Destination := void;
+ T J9 C2 x# o$ ` if @.occupied then
( v: c" e: z7 K% _4 Q part := @.cont;* w+ d7 i/ }& i( C- H, N. F/ `
@.transpOrder := void;
) R2 |0 ~) V; f# z part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
$ g% \$ r- t: o3 T @,root.eventcontroller.simTime);* F( ^1 S- B' e- g/ n
@.HasOrder := false;3 p5 |7 D ^$ I" j/ v$ A: A
@.DrivingHome := true;
1 d2 r+ [2 ` o( l6 W rgManager.tryToStartTransOrder;
: W4 y8 y' Z2 h! O% q4 y if @.Destination = void
/ W0 E5 V8 ?# H8 _9 h+ r' l then -- no transport order for vehicle @, B& k h) s+ p5 V
@.Destination :=# A. ]1 @; |- v/ s: b; n
rgManager.nearestFreeStation(@,track.~);
3 v/ e0 V0 L6 ]' Y9 P; O newDirection(@); 1 @; E1 k3 G! @
if @.Destination /= void then# g$ C3 K9 v6 ? E" s, `; D3 o+ X
@.Destination.NumReservation :=: x- D; V& z% }- w% k
@.Destination.NumReservation + 1;" @8 T! a: L3 S5 q. Y. ?4 x
end;, `$ L& U: O- V2 n R9 X
@.CurrIcon := "drivingHome";% i) k* N8 I0 C; ]$ u- O! i2 V% r
@.DrivingHome := true;' V- V* J& i' s7 T% B0 c
end;
6 K) W2 @( G3 B else -- the vehicle @ is empty, both vehicle and part are in the same dock station
. @$ m' D# N" b+ E) X part := @.transpOrder;
; O+ H! p: F! y/ }/ ^ part.move(@);-- load part
5 Z/ W& A. Q: V5 ] @.CurrIcon := "load";/ \. j2 Q9 ?9 Y S% A
GlobalDistObj := part.globDestination;; d0 Q/ R8 E5 N- _& @6 P5 ?( v
assignLObj := rgmanager.rgAssignL;& C% m9 D% ^! x% f/ [
row := assignLObj.getRowNo(GlobalDistObj);
2 l* T+ s$ d; v; W& {) O; _3 `, P if Row = -1 then -- since 701 {0 l: t- \! c2 T. t5 A
if lan=1 then
, Q/ i- k1 u& |/ Z8 _; @ promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
. @, f7 F; l! {! J; k to_str("in der Andockstation: \"",?.~.name,"\""));
8 y* J) t1 Y- S' Y7 v9 Q else
1 [5 u+ L$ u8 V promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),9 }" ?/ u" i. b( J3 k
to_str("in docking station: \"",?.~.name,"\"")); & l3 |" M: _( ^7 I
end;$ G3 S5 s, H5 o2 l* H
else+ G; w) s% K7 b5 [6 K; D/ T" _
@.Destination := assignLObj[1,row];
" X+ Y; p }2 j4 [ end;
' u3 q0 z+ T4 _5 V newDirection(@);4 \- h0 X2 N- d1 T8 a
@.HasOrder := true;, y- e1 P4 e: F
end;
|3 |: A" j9 M/ _& p: p; |! A end;6 k8 v8 q9 f% b- v+ t2 w
end; -- of the method6 R, {* ~0 C8 I3 q6 Q/ p
|