/* called by: entrance ctrl of the object 'track'. z6 S2 z: r. C3 U
*/" k. o5 C: Z& t
is
9 T+ `, }9 \8 _. y" f part, GlobalDistObj, assignLObj:object;row,Lan:integer;
" V6 l) ]6 v7 Jdo
9 T/ W) @3 X: _8 d8 K" `6 Q Lan := rootfolder.Internal.Tools.AOLlanguage;
/ A# k, t& o6 o5 n6 E! T; q if current = @.Destination -- else return+ R) C" y+ b! _1 p* u) h* J
then0 ~# E& ^( B. l: ~2 V9 c3 }
@.Destination := void;
" s- l5 l* l- F$ d& T* l if @.occupied then
6 A/ s' i2 i1 F2 q' ~) @- V part := @.cont;
( g/ D, W3 A. k! R' S1 z- S3 x @.transpOrder := void;6 p: [4 s1 r/ c
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
2 w$ B9 ]. I$ |9 n @,root.eventcontroller.simTime);
; I2 r2 T$ |7 b, c @.HasOrder := false;
* Y+ v' \+ L- \: e V! H @.DrivingHome := true;
- D4 k8 q4 z2 L rgManager.tryToStartTransOrder;
8 b8 g% t9 ?! T l( l" S if @.Destination = void3 s9 A* v4 |5 a# [& W; v U
then -- no transport order for vehicle @
! i; q& j: Y+ T/ }$ q* b/ q @.Destination :=
( n1 R: A, _" @* G: q5 i rgManager.nearestFreeStation(@,track.~);" O5 ^8 r, I, u7 K2 x# U3 [
newDirection(@); : u4 W& E% z' x. P
if @.Destination /= void then: i0 O# Q4 ~* ^1 G9 A, y
@.Destination.NumReservation :=
. N# M) J8 n7 I- K @.Destination.NumReservation + 1;" e9 C3 R: l' J* x: Z' Q8 x4 i X
end;
0 i7 D$ I" Q/ I: S @.CurrIcon := "drivingHome";) {; o2 T3 f' M. c1 K( l6 N- `, m
@.DrivingHome := true;
+ r$ K5 R3 m2 W! L: } end;" z6 _0 h/ y3 r
else -- the vehicle @ is empty, both vehicle and part are in the same dock station( C/ f; s# S' t0 W
part := @.transpOrder;
/ g) P1 P2 }6 y" H; p. H part.move(@);-- load part
4 a- j( F) S+ R @.CurrIcon := "load";; B" c9 y( K5 |# z7 S4 [; r* \
GlobalDistObj := part.globDestination;
' ?& f+ ?( e( c( q1 v6 |$ e! \ assignLObj := rgmanager.rgAssignL;
& c+ k1 l6 g! {' R& J& } row := assignLObj.getRowNo(GlobalDistObj);5 M; c( @. [, b- s" ?; ?* D& c
if Row = -1 then -- since 70
. n- a8 ^/ Q+ R1 E5 w if lan=1 then
o: V* G: K& M/ U4 r1 O* A promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
2 U; `& n, ~! }: a# v1 a to_str("in der Andockstation: \"",?.~.name,"\""));
- \8 t/ k3 \3 Q0 z" z else7 Y" f& X+ j# V5 Y' j
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
8 Z7 t& x8 A8 Y9 o to_str("in docking station: \"",?.~.name,"\"")); ' \& M7 k" A% u5 v" S0 I
end;* J3 l/ I2 S& l# j8 m, f; N8 v/ k
else
/ q2 b9 E: U' ^! W3 L @.Destination := assignLObj[1,row];
* \/ A) K. C% H- A* G2 J. @" H7 } end;
8 G" m7 o6 ?, o2 X0 {+ P newDirection(@);0 u. M* C+ U9 v$ J' k1 S( y+ M# } Y
@.HasOrder := true;# ?* m1 O$ _" P
end;
$ |0 z7 e0 ^1 S9 s end;
7 r* B+ P0 F. x! u3 tend; -- of the method
& W4 V7 A( s0 r4 ]- }1 G3 B+ a |