/* called by: entrance ctrl of the object 'track'
$ U$ v5 H) _4 e4 o1 n*/
( J+ u! r, @9 }' }# uis
+ n/ u' r/ b- s+ n4 \( `/ N& @; ? part, GlobalDistObj, assignLObj:object;row,Lan:integer;' d3 B& ]$ o1 a* \+ D' e8 d
do; a' O* h6 K8 r) S3 n
Lan := rootfolder.Internal.Tools.AOLlanguage;
2 N' K$ A! B& ^- m7 F if current = @.Destination -- else return
0 m$ V# g$ N% k% T then
4 `: @( v6 B8 r! d" |/ C1 x5 B @.Destination := void;
' S1 [! ^4 Y+ w) H! h1 ~& O i if @.occupied then) t9 e4 H( U' R# Y
part := @.cont;
4 f1 X2 F: Z4 G' @% q @.transpOrder := void;
1 W. i$ a8 a5 K1 ^ part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,' ~0 @7 s* ], t2 v! d9 Q* T
@,root.eventcontroller.simTime); s$ I! z! \: e1 E7 x; Y& l
@.HasOrder := false;7 k! _& e( R6 ]; Y W J3 c
@.DrivingHome := true;
- M% U4 @: N6 ?8 g! u6 p rgManager.tryToStartTransOrder;" \& @& h2 G- Y1 Z
if @.Destination = void
# i7 C% M& h& E/ j then -- no transport order for vehicle @
1 C8 x/ A* L8 y! c# ?$ { @.Destination :=
0 s7 } n* l! p* `6 }5 F. j' ? rgManager.nearestFreeStation(@,track.~);
7 i# O; A: w T; `+ I newDirection(@); . h/ R- m! m T. k+ \
if @.Destination /= void then
% |) b% r9 O4 M, t; U @.Destination.NumReservation :=1 c4 P4 `9 I3 t ?6 H
@.Destination.NumReservation + 1;) z/ ~8 `& g! h3 n
end;
* j8 D" y" ]) S @.CurrIcon := "drivingHome";2 ?: I% B0 D6 l$ W
@.DrivingHome := true;& C* A3 `$ e' A; A
end;
! S) r6 s+ l- q/ D else -- the vehicle @ is empty, both vehicle and part are in the same dock station
" z4 y5 h0 f) p4 m! ^5 ~1 _9 k8 x part := @.transpOrder;& z% ?+ F' E7 @4 q; f' r
part.move(@);-- load part& o" I" S4 s, M/ q/ Q3 p2 a
@.CurrIcon := "load";
3 l5 T& F" Q1 L0 ~& o GlobalDistObj := part.globDestination;
" R8 p2 F7 E. r) E1 V assignLObj := rgmanager.rgAssignL;9 p( d3 L$ B) o& [. r
row := assignLObj.getRowNo(GlobalDistObj);
" I0 F# E* l" [4 b if Row = -1 then -- since 70
A" w1 o% A) m. A) o% w if lan=1 then$ z7 E8 n. y* g0 r) m
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
! G ]- L9 `. q, X to_str("in der Andockstation: \"",?.~.name,"\""));
2 U* A: E7 `8 ]- `( {. M8 w else
' ?9 \/ |1 G7 v6 e4 T promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
* ]0 t) R3 V/ l, N1 e# {9 P/ H to_str("in docking station: \"",?.~.name,"\""));
3 D. o: P! [& {; H end;) o4 A3 J7 t( b" K+ T" n, p7 k
else
: P: B( ?5 `9 h! i/ |) o& o @.Destination := assignLObj[1,row];( ~" l: m- w+ N+ B2 I0 D! y
end; ! }# k& N X, r" `$ n( N, j; t
newDirection(@);
4 g3 {, N, i/ B9 J @.HasOrder := true;! Z- O! d+ V6 Y* E" }
end;, H% K* \) I3 W5 i
end;
, G" x1 L8 r- A+ S! Z d, ?6 ?end; -- of the method
) f% {: z- n' n) l, t9 Z7 ~ |