/* called by: entrance ctrl of the object 'track'
' y1 N7 ?4 `" Q- g L*/
, O# l3 M# K+ ?is
7 U& G" O, u$ u2 E# S( n2 F part, GlobalDistObj, assignLObj:object;row,Lan:integer;
- [ J+ ~' C7 t9 ~. u; x5 f' Odo0 K& p2 V$ k- s2 n9 J+ W B! N
Lan := rootfolder.Internal.Tools.AOLlanguage;2 d" O2 m) w5 g p; r) S
if current = @.Destination -- else return+ i" l2 }4 W1 r# C/ ]( |, ~- j7 U
then! h( M% \( u- ?2 L7 h
@.Destination := void;
* ~* p. J ?/ @9 f' ] if @.occupied then& c0 X" ?! @" L3 p; E7 O' L
part := @.cont;
C Y% Y2 K$ H3 o$ \# v3 j6 Q @.transpOrder := void;
T8 S+ J+ N% M" D' K" ] part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
/ P; `4 G- s/ B: y @,root.eventcontroller.simTime);- m1 D' D' S6 H2 U7 R! g" ]; z
@.HasOrder := false;( K2 V) b& a( H" |: D
@.DrivingHome := true;
# z+ P5 j+ s/ R rgManager.tryToStartTransOrder;
; h' P1 a' `. D2 X$ o5 I! y if @.Destination = void! w+ O7 H. d m# ?+ U1 t
then -- no transport order for vehicle @
: ~8 n- D! @: M" Z @.Destination :=
% S6 k7 |+ F3 \/ ^1 o rgManager.nearestFreeStation(@,track.~);
2 J* }9 @( O" l8 [2 [' a newDirection(@);
b* n; z. {. p. n: z) R1 e4 ^ if @.Destination /= void then
( z W" U' P2 q3 F0 `1 \ @.Destination.NumReservation :=, a$ \4 F' e/ S5 G( s& i" X* C
@.Destination.NumReservation + 1;5 r/ w: x! h; Z8 f
end;
- E( U( _, o7 e @.CurrIcon := "drivingHome";; P: P* I: c0 m4 L$ `7 v: g8 X3 X' I
@.DrivingHome := true;
) G/ r, w% n5 g( U! z: M E end;
! q5 c/ V; L/ v8 q else -- the vehicle @ is empty, both vehicle and part are in the same dock station
- ^2 S+ p$ s6 c7 `8 K part := @.transpOrder;
z& b. d( Z. S8 c- p* T; g: b2 C part.move(@);-- load part1 m1 b- U. O# f8 i$ J0 Q" D
@.CurrIcon := "load";
: Z1 O% ]4 z0 x( R7 h1 q y GlobalDistObj := part.globDestination;
6 r2 J) Z6 x0 M$ p, ~) E assignLObj := rgmanager.rgAssignL;
6 Q1 f. Z8 d$ j' @( O9 R! U row := assignLObj.getRowNo(GlobalDistObj);
) s' j3 ]) E% f$ J6 [% j# {& [ if Row = -1 then -- since 70
+ a/ B _$ l/ P, f, } if lan=1 then9 m+ m' O! S/ ^6 K, s
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),. Y3 M/ t% W% @1 ]
to_str("in der Andockstation: \"",?.~.name,"\""));
: F' I/ O! V* W2 i' N$ |; E else0 s$ o/ V5 s& F3 O8 A
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
" h4 v8 q! A+ L; N' ^ to_str("in docking station: \"",?.~.name,"\""));
; Q! {$ J! D# K9 r6 a end;
j( ^5 J6 n4 _/ M else
/ c7 E+ g; k; Z3 {* p @.Destination := assignLObj[1,row];/ O' S4 \' P5 v4 c" X+ A
end;
- c2 u9 K' `+ Y1 y: w- Z" e newDirection(@);( o' X' F6 Q5 x5 i i9 F' j/ p
@.HasOrder := true;
@' K j- M; X' X7 Q [ end;+ K. c! ?# r( q3 o q8 l: ^
end;" k4 p% f/ K: p8 e: B. [6 R
end; -- of the method
- }! K6 V+ }( g |