/* called by: entrance ctrl of the object 'track'
) s! x4 R+ T5 G' Y& d" p*/) p5 `$ e- f9 T0 d. L
is* A# t0 E2 R+ |& }0 ~) o" l
part, GlobalDistObj, assignLObj:object;row,Lan:integer;: f7 C; D. i( G' w: l
do, H. P) \* d) c: Q. d4 Y
Lan := rootfolder.Internal.Tools.AOLlanguage;
% ?! E* R$ z" ^9 Q if current = @.Destination -- else return
% c- [+ s, T7 ~" _ then& R( q: I* l9 p X. c j
@.Destination := void;6 |, V: _8 A; L. ~. f# R8 \# R
if @.occupied then$ f/ E K1 M' Z7 A* C
part := @.cont;
0 J3 y1 \0 M+ X; w5 z+ j2 m; U @.transpOrder := void;# ]: B* P& r+ F, @- V
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,2 N/ z* b8 P! c# z" m8 K
@,root.eventcontroller.simTime);/ t9 j0 E$ V: a' }8 ]! h3 K8 s
@.HasOrder := false;$ H+ p7 B* [4 G1 R
@.DrivingHome := true;
2 ~" O1 `7 P; n& m" o7 H; t6 k6 [' n7 q rgManager.tryToStartTransOrder;
8 G7 I8 b s; S( J8 q if @.Destination = void
# z9 d% s1 p; @1 q9 o' B: R7 m* K then -- no transport order for vehicle @
$ b* w8 r2 Q! P8 N2 b9 ` @.Destination :=+ X: E" V; Z/ l5 |& o
rgManager.nearestFreeStation(@,track.~);; q+ P( k- y- y7 D" Q0 z
newDirection(@);
% D0 T' _3 i- W* j if @.Destination /= void then
% i. q* M$ |* }7 D5 {& n @.Destination.NumReservation :=
. W9 C* j1 ]2 n4 v5 g) l% a8 a @.Destination.NumReservation + 1;
" P4 i) }- n; j! l" N- S. W end;
' z( o; o# {/ }5 l, Z% b; w @.CurrIcon := "drivingHome";( \6 j0 D( I6 K m: u6 `7 d
@.DrivingHome := true;% V& |4 Z2 j! u1 Y8 D! y2 I! \
end;
$ `( C. Q" j; I: o" z1 |9 D( K0 W else -- the vehicle @ is empty, both vehicle and part are in the same dock station
- l! m, X6 _; v! Y: b/ n part := @.transpOrder;
/ j! R6 y% X n2 i" ?) o% X5 N part.move(@);-- load part
/ A$ T8 }9 |5 n3 P @.CurrIcon := "load";
$ p( a( X4 E# d4 o8 {0 Z6 [* L GlobalDistObj := part.globDestination;2 |( ^. y$ r+ k& M& k9 ]
assignLObj := rgmanager.rgAssignL;- k. I. A7 Y p& A
row := assignLObj.getRowNo(GlobalDistObj);
2 I+ ]1 w5 d+ T* U8 [ if Row = -1 then -- since 70
' E6 J! O C1 D" N" S0 k if lan=1 then* ]9 k- a4 Z# d- r! S) u4 M2 {
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),9 ~/ Z* X& \: U
to_str("in der Andockstation: \"",?.~.name,"\""));9 s- _. \- s2 _
else
8 o* {( S- U- W: U8 `7 V7 W promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),0 j2 L0 l" i3 x, I- Z3 k; Z' T
to_str("in docking station: \"",?.~.name,"\"")); / H: h% ~' q. @3 _
end;
% U6 B- G/ h, A' Z$ U else% q& e) Z& w, m9 O. j+ [
@.Destination := assignLObj[1,row];
- @9 f! h4 T, D1 r, g! T end; % H% H5 F5 i; E$ J1 L: |
newDirection(@);" E# N7 d9 N9 v# I, f8 e) @
@.HasOrder := true;( G6 c4 ]1 v" r# T% f( i
end;
9 C8 }: L- ~; D& ~9 E$ P end;* x: U! e2 C3 y5 P* W
end; -- of the method
& b D, g1 B1 A" Q g9 b( Y, c+ T |