/* called by: entrance ctrl of the object 'track'
4 g1 O8 \' w# v/ h& P*/
+ x/ c) g( x$ qis
. r9 p2 ]) _8 e1 M- m part, GlobalDistObj, assignLObj:object;row,Lan:integer;
) \) r1 G9 e8 q6 V) T3 H8 \do! o# q3 }. U$ M1 U. |/ y: W6 _ Q6 E
Lan := rootfolder.Internal.Tools.AOLlanguage;
7 x) b* H7 I6 K9 n/ ]. D$ c if current = @.Destination -- else return
6 K8 u3 J2 Y o4 h then o: v1 ~" J" x. [9 t) Z8 J
@.Destination := void; c, @, I7 Q3 e& I- f
if @.occupied then, R' ~; T$ l1 R( p! W7 }
part := @.cont;- R4 s% J! _) F% f6 @4 X
@.transpOrder := void;. e H" q/ @- _9 q$ z7 f
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,/ b* q7 h" h( Q" P& w6 G+ A8 k. i- `2 e
@,root.eventcontroller.simTime);5 j) m V8 a1 s% {
@.HasOrder := false;
' n2 p( s6 O- N3 o" P @.DrivingHome := true;+ ]( }! c7 q0 G4 b8 _
rgManager.tryToStartTransOrder;! C' c W3 O) M0 |, O* C; p1 B" J
if @.Destination = void
P9 w7 y, Z3 a* l. V then -- no transport order for vehicle @
% V5 T$ u' F# U @.Destination :=2 l4 g6 r3 \% }: X$ @6 d
rgManager.nearestFreeStation(@,track.~);
+ s; _7 S( Q5 |8 `; |# r+ K newDirection(@); : t$ e4 y* }9 {
if @.Destination /= void then2 y, B% l' {" x. \) n& _
@.Destination.NumReservation :=7 O5 C: q- `3 k: w' M: J4 c, e
@.Destination.NumReservation + 1;# D W& s9 r5 Y2 N
end;+ }. ^ s8 t& ?: |* S
@.CurrIcon := "drivingHome";" H, P; z; O. n8 ]1 ~# |4 v, O
@.DrivingHome := true;
0 U+ O4 h* d% J" b/ T% t end;
. |5 V2 K' n5 S0 d else -- the vehicle @ is empty, both vehicle and part are in the same dock station
) @8 d' i" S. ~# e9 @ ] part := @.transpOrder;
# ?. {8 M9 q9 S* l part.move(@);-- load part
: K A- t/ k! r' Y @.CurrIcon := "load";
/ [( o$ j( j7 I$ y) F3 M GlobalDistObj := part.globDestination;6 O, b! E8 f- p; d% D/ Z8 r
assignLObj := rgmanager.rgAssignL;
2 Q6 u$ h; x/ v I% X row := assignLObj.getRowNo(GlobalDistObj);, o# L l9 |: ~6 k, j
if Row = -1 then -- since 701 y; b/ {/ w: Q2 p/ v5 \* Z
if lan=1 then. @* O: F# ^4 i- C, R/ y
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),, T( W. l6 K6 x
to_str("in der Andockstation: \"",?.~.name,"\""));
: b# R/ l6 c: E# A5 b! M( i* Z4 c else
1 p! c0 d' e/ p( z5 k9 `# x" q' d promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
% Z( Q5 B) P) h+ V b" f to_str("in docking station: \"",?.~.name,"\""));
# O& L* g2 R! J# g' w) a end;
" U$ V: ]- n- f% Y2 m else
- Q5 w: I: A# x. I2 Y9 U @.Destination := assignLObj[1,row];. b+ Q, n( v% \+ J9 a
end;
% Y0 v+ d! r* o9 N6 @ newDirection(@);
- D7 e5 ]( x; ]5 k. A. j @.HasOrder := true;7 m: \. f/ E0 r! q6 p( e
end;
, j6 l9 S, }$ ?* @3 z- p end;, N0 o0 }5 f, @8 S$ U- }
end; -- of the method; h u' v h3 X7 ]7 ^2 Z( Q* H' G
|