/* called by: entrance ctrl of the object 'track'
* K* ~" `! W" x*/
r/ m' ?1 y5 P& w4 X* ois) d3 u' M" ^9 Q* |5 }
part, GlobalDistObj, assignLObj:object;row,Lan:integer;
* m4 j3 r9 R9 j, z+ H/ ?2 bdo
- g' t8 `: |( m7 q Lan := rootfolder.Internal.Tools.AOLlanguage;* v- C: h1 j- ` k& ^6 G' L
if current = @.Destination -- else return* b7 p$ A0 R2 E, ~/ q$ s; a
then0 C" Y0 r2 V+ D# T7 \& c+ j. w" U
@.Destination := void;9 H0 |) Q# V' X/ |8 o
if @.occupied then
& m0 m/ b) F/ R part := @.cont;
2 E8 i. K; r4 \2 B2 F$ p, o! V @.transpOrder := void;
) m7 d' x/ }3 U/ S part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,0 ^ G: J! i ~: I. _ [
@,root.eventcontroller.simTime);
+ {' b" \1 V7 p" Y" |+ { @.HasOrder := false;" Z; D0 S" G+ M8 f$ t: S) \% R
@.DrivingHome := true;
% U5 [% ^% Y. x% h2 Z" J2 ] rgManager.tryToStartTransOrder;2 X# s6 G: _# c) O% t$ [
if @.Destination = void
; @4 N1 C% X% v: L7 X- \ then -- no transport order for vehicle @
5 r! j- s1 U: E# X3 W @.Destination :=( ]: R- F: n" A3 ?
rgManager.nearestFreeStation(@,track.~);
$ O; }- Y5 n( ~2 R; ?4 Z9 i. G; }6 G newDirection(@); Y3 t9 L% O9 J0 ^) d
if @.Destination /= void then
! f h% y. t. V3 V: i6 \( {8 w, Q @.Destination.NumReservation :=
n& G5 g* @- V1 M @.Destination.NumReservation + 1; G8 s- H0 J# A6 I& K1 w; C* ~
end;& H) T L7 N2 q7 H. f
@.CurrIcon := "drivingHome";- A' G. u) ^# U9 v) l( H$ ^ Z
@.DrivingHome := true;. v/ T8 s4 [; ~" r
end;
( {- \8 X( x/ o3 X! C) \4 [ else -- the vehicle @ is empty, both vehicle and part are in the same dock station g4 |4 A+ a3 [6 s
part := @.transpOrder;, p" u" a Q/ {7 i3 c
part.move(@);-- load part
* _5 V; ]9 M0 R- @7 q# @* C! u @.CurrIcon := "load";
! X/ [. O" I, D3 L: r GlobalDistObj := part.globDestination;
/ z% l* X |8 r assignLObj := rgmanager.rgAssignL;7 T8 \* x- E* L) W' y
row := assignLObj.getRowNo(GlobalDistObj);
" ~! b5 {- [- t, _- o if Row = -1 then -- since 70
4 C& S2 ?- z: w- {4 z+ w) t, K0 s if lan=1 then" v, g+ a3 D' R8 j9 o
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),5 n0 @( X# [& }$ i! e$ t; J
to_str("in der Andockstation: \"",?.~.name,"\""));# ?# Q5 r0 M+ z" n8 [
else
n" T# r4 H V: E- D% u k promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
4 m3 n' D# `( i to_str("in docking station: \"",?.~.name,"\""));
: a( { N9 F% P; c* X& Y end;- C) E3 L. ]3 m- e
else
$ N* m( W$ m7 o, W3 x: j' {6 B6 S @.Destination := assignLObj[1,row];& Y9 X! ?# J6 l! s- n6 J0 @
end; & u( ^/ L" p! B8 H7 a
newDirection(@);
; A' E( P, C, B @.HasOrder := true;0 V6 A2 s! g6 @$ G1 {
end;& }6 L; F# o' q" }% F. d
end;: n2 ~. S9 }# z1 D2 K8 B
end; -- of the method" C V# ^; V1 k9 ?2 c- ~( i( R/ X# Y/ @
|