/* called by: entrance ctrl of the object 'track'
8 c0 l$ m1 ]; \: G: ]0 @( s*/
( O+ e/ U1 L2 E. k% pis
4 x: n0 {: h1 I part, GlobalDistObj, assignLObj:object;row,Lan:integer;* h0 s2 T B; K' j. H3 U
do; H9 H4 A* ^7 _, c
Lan := rootfolder.Internal.Tools.AOLlanguage;# ]) c% K% T8 O/ \" M
if current = @.Destination -- else return
9 w8 _% G ~ c) l9 I A1 Y then2 w6 ^' V8 M) n& h' Y% ~' Q. H
@.Destination := void;
4 X0 Z; i6 r2 c5 z if @.occupied then
* J- ~( @% U' ~* n0 O$ o part := @.cont;0 X+ d9 O( z( c5 r) ]& C3 ~
@.transpOrder := void;
@8 D4 S. l- r2 o! y part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
& w# s/ N8 l, c) s @,root.eventcontroller.simTime);
8 ~1 w& ?8 M- }; |8 | @.HasOrder := false;
6 \. _/ P5 E+ o$ |( E! G* M @.DrivingHome := true;
2 q" \( F. I# R4 O9 e1 J rgManager.tryToStartTransOrder;
1 o4 I* ^2 G$ N' ~6 q z3 H0 V if @.Destination = void) p( _$ X$ X3 ?- X3 A/ C. G
then -- no transport order for vehicle @
# @9 R1 M0 l% e7 K @.Destination :=
3 p0 R+ w; T. q. \2 }- ~# t) p: | rgManager.nearestFreeStation(@,track.~);% L# a: [. F" l8 N7 k. }% v
newDirection(@); ) Z" k: s* K: G" v j7 a) Q$ ?. M& L; c
if @.Destination /= void then t9 Y) y' n3 @# x" h8 K( N
@.Destination.NumReservation :=
$ c6 V) W9 Y2 X6 T, {0 p @.Destination.NumReservation + 1;. o) [" m& s5 O6 w
end;- h3 x: H/ b* E" m) ], y
@.CurrIcon := "drivingHome";& M/ R; @7 K6 g e' \
@.DrivingHome := true;
/ Y+ H. X! @0 }1 y/ X0 j* b* B end;; n7 k+ c Q4 D5 L
else -- the vehicle @ is empty, both vehicle and part are in the same dock station% n% G; l- _" H- w# R. f1 O }
part := @.transpOrder;$ n5 `$ ^: g, w" G% ^6 B: [
part.move(@);-- load part
7 g) M2 \' j3 K8 c9 ^ @.CurrIcon := "load";
6 y+ I8 \' w- ]% U& T" ? GlobalDistObj := part.globDestination;1 U) g3 }$ s6 s8 a
assignLObj := rgmanager.rgAssignL;
0 H: i! z. K$ A+ J* | row := assignLObj.getRowNo(GlobalDistObj);2 w# i, X; Q4 M+ X
if Row = -1 then -- since 704 A) n" e& K$ s: @' M
if lan=1 then
* R' ^* m! d* g7 J! m. ~8 \ promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
5 F/ ]1 e) F4 v1 F) n to_str("in der Andockstation: \"",?.~.name,"\""));% [9 i$ Z- T8 I' V# P; X: j4 q
else
& F& p& H x- Q4 a* |% v promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
+ f/ n( H- G( ?! W to_str("in docking station: \"",?.~.name,"\""));
4 t& o2 p l, n/ a# F end;
4 a( z0 R$ z6 v* R0 e- I9 T+ w else
( K# B3 i, ^- V @.Destination := assignLObj[1,row];
G6 _* e( {0 v# ?2 F" U end; / }, }( G: k# a+ U) H
newDirection(@);# ]2 `6 o2 z& v) U, w" ?% B
@.HasOrder := true;
: O3 e1 P8 v& g. [& M' e5 w end;) Q+ Y. g8 S7 n# r! P/ w/ F9 h+ ?
end;
. i% p9 q% P- q% v- |1 pend; -- of the method
7 H3 Y- z" g- D9 a |