/* called by: entrance ctrl of the object 'track'
* T1 t0 z6 r% {& I9 @1 ~8 m0 o/ S- D*// J7 s0 C; X( ]$ L, \ T
is
, N& {. ?8 X8 \) f: C0 @ part, GlobalDistObj, assignLObj:object;row,Lan:integer;
Y. b/ M, _' |; c4 o- a) O9 \( zdo
. z+ u: L. s3 p Lan := rootfolder.Internal.Tools.AOLlanguage;
" |7 V# r2 J3 t4 Y/ N if current = @.Destination -- else return' V5 {# G5 Y9 o* E) N
then
5 c0 l3 M; ?& h* j* ~* _/ x @.Destination := void;
# |* F' k! z* ?1 c4 ]2 m& u if @.occupied then6 G- P% G+ d5 o9 M1 D
part := @.cont;
* c0 A/ [; h" k @.transpOrder := void;+ N$ H2 |- [ I8 l2 L
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,# ?& h/ R! s2 W6 l- b- [
@,root.eventcontroller.simTime);3 I, v9 |0 z( F4 r
@.HasOrder := false;. ~6 l/ ~1 s' b$ z! I
@.DrivingHome := true;
5 W) O, R4 m" o7 d; ~ rgManager.tryToStartTransOrder;
0 h2 _0 ?: d( y' \ if @.Destination = void
* x3 a" _9 F, h" f' y then -- no transport order for vehicle @
6 X# r" E h" E, o; E @.Destination :=+ G" o0 T- E5 j1 J
rgManager.nearestFreeStation(@,track.~);
( }) [- I! |6 t0 r1 A newDirection(@); / p; u0 [0 Y, b+ N
if @.Destination /= void then
1 y! \+ }$ ]5 h! V0 i8 ~8 m @.Destination.NumReservation :=; Z' Y4 F# w' g5 C$ G
@.Destination.NumReservation + 1;/ W9 j. J. n' C- \7 P
end;
& _& o6 j" e' f) Q @.CurrIcon := "drivingHome";+ @5 `' c5 A( n
@.DrivingHome := true;! O; \4 L2 H9 T8 r7 m$ j3 e
end;+ H+ g h" Y' z1 T' }/ P
else -- the vehicle @ is empty, both vehicle and part are in the same dock station
1 C& b* ~1 H/ X2 L part := @.transpOrder;" C A ?' j5 ^5 s7 \5 W0 q0 L
part.move(@);-- load part
. y' {+ c& I' O" O0 H @.CurrIcon := "load";. G8 m( @' ?5 l$ O0 L1 i! ]) e1 G$ D
GlobalDistObj := part.globDestination;* Z4 d7 x8 |5 _ L
assignLObj := rgmanager.rgAssignL;
% o; r- Q8 L9 g( t row := assignLObj.getRowNo(GlobalDistObj);8 l, L _. ?- o5 S
if Row = -1 then -- since 70
|5 _" |+ C0 G if lan=1 then6 F4 S5 Z& [9 X4 D8 d( s7 f# y
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
' Y: h: s' r8 _1 O to_str("in der Andockstation: \"",?.~.name,"\""));
2 b$ z& i2 S& ^& X9 L C- D else/ [1 R1 p6 ?' H$ t D. g$ W
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),% s8 q6 c/ O* E0 L+ J
to_str("in docking station: \"",?.~.name,"\""));
2 F* S" i( m) r7 b& n# V end;
4 d7 L! s6 \* |. G" r% G else( i1 C8 a/ }4 X7 ]0 E
@.Destination := assignLObj[1,row];
# N) L7 W. ]" {* U4 X3 t9 j* `# } end; . T+ y2 }7 p- r3 j! L' p
newDirection(@);& W; B9 m, {* _" N1 N; ]! d( n6 ~4 s
@.HasOrder := true;
- S& \' r+ D) G% | end;
3 ]$ v' l& `4 A! n1 c0 b, ^4 C end;" O, ~* Q) D; E0 h- R; E: |
end; -- of the method
3 Z7 r( [$ t8 k, u2 a1 R/ q C0 g |