/* called by: entrance ctrl of the object 'track'
- X* ^: z( l9 i3 s4 S*/
9 U7 U+ X h6 v( B1 `5 r5 Dis
. P$ C* m: x; z, ?* t( R3 | K part, GlobalDistObj, assignLObj:object;row,Lan:integer;
* u: s: }; c+ b3 o% ~/ _do
- L- F' T/ m# {$ t: Q Lan := rootfolder.Internal.Tools.AOLlanguage;" }' i7 s; }( d2 M' ]5 A& ~
if current = @.Destination -- else return
' A2 p* H1 A- d( A then
4 Z+ r* D1 _9 ] @.Destination := void;+ L( N3 }0 f: m' {6 b
if @.occupied then& M& K: y2 @: {6 n' T
part := @.cont;; T1 B, U2 Y5 O/ P
@.transpOrder := void;: ]0 W; Z+ z: m! W
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
- s7 C$ a! j- p8 M @,root.eventcontroller.simTime);
6 x+ P R& U# j) H/ p/ _) [ @.HasOrder := false;5 v7 v! T% ]6 k% Q& V3 Z
@.DrivingHome := true;6 [# \% s" b4 Z5 R! q, [: b3 e
rgManager.tryToStartTransOrder;- G/ w- {( H; A2 C: d" }
if @.Destination = void0 ?9 a9 d- ^/ G; e( x3 S1 j3 b
then -- no transport order for vehicle @
) q6 T# ~ u" D, W f1 U2 N. [5 n @.Destination :=
; s9 l3 z6 G1 F3 T/ u7 F rgManager.nearestFreeStation(@,track.~);% K2 v7 f# I" X5 `
newDirection(@); . ?/ V7 M& X" Q7 ]4 D/ B
if @.Destination /= void then
1 i0 E9 M3 }( U0 C @.Destination.NumReservation :=
. `& P1 o! `$ ] @.Destination.NumReservation + 1;+ P6 `2 r; {6 R% T8 U
end;
" H/ m% u. I6 Q& A2 ]$ Y @.CurrIcon := "drivingHome";
* M, |' v4 e5 b6 A! s @.DrivingHome := true;( E& c9 m6 K' a% @/ e8 Z! [
end;* G+ p& `6 D" E8 H6 W7 X5 _4 H1 r
else -- the vehicle @ is empty, both vehicle and part are in the same dock station
* V! `3 G3 K5 \4 c; m* S0 ` part := @.transpOrder;% {4 a3 K0 U' N/ L! F
part.move(@);-- load part
! d+ f9 E7 ~1 I @.CurrIcon := "load";; v; }, u5 n# C, B, @$ m) t& S
GlobalDistObj := part.globDestination;
. @* n! A2 q& @( B7 I# ] assignLObj := rgmanager.rgAssignL;
! t. W- u" S4 b row := assignLObj.getRowNo(GlobalDistObj);
# W: P4 C' e. L4 S" q2 ~1 d if Row = -1 then -- since 70
2 @; S' b1 n. t4 J- o if lan=1 then+ C8 E$ t4 F6 L$ `& K9 C
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
7 N$ J3 t' T. a' F$ ]# \ to_str("in der Andockstation: \"",?.~.name,"\""));& h4 L0 Z3 _8 V8 `" I& S3 o
else( ]0 \* U. i2 `( C( o
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
4 ]& S( M! W, ?+ \9 l" x) w to_str("in docking station: \"",?.~.name,"\""));
$ f# E* K0 z1 k" B0 C# r8 S3 @ end;
) R$ E5 a) y* b- J else3 D7 q) Z0 h% z% l) \
@.Destination := assignLObj[1,row];
: [1 D3 N; [: ] end; ) A1 W6 }" z# J
newDirection(@);0 L) ]% c2 _8 g& `2 j
@.HasOrder := true;8 n( o' q/ K1 u* A
end;
. n& L1 B% I2 _0 A7 g6 I6 a' H end;, x3 l2 g$ c9 e) A( L- O( x
end; -- of the method
6 V- m+ ^; h- b0 N: A |