/* called by: entrance ctrl of the object 'track'% Z; w& }2 x5 E! K! r. [5 N$ i
*/
w' E- o" f+ z+ J6 ^is
, R# }# A; |+ U( q part, GlobalDistObj, assignLObj:object;row,Lan:integer;
: l {% G4 O! Y6 E% Kdo
& U! K& g. x% j Lan := rootfolder.Internal.Tools.AOLlanguage;1 L- f" l' ]/ W8 u t# ^
if current = @.Destination -- else return
$ l9 `+ s1 c0 _( @3 X& { then
! h( a% J; C# E* T% q @.Destination := void;
9 } N$ H) D- D/ t if @.occupied then
- m$ \( |' [9 z; b2 P7 h part := @.cont;
3 G1 K. `+ H" k: U @.transpOrder := void;
- \& a( c# k" U8 l; n& }' \* U: M3 m part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,; R4 X e3 ^: B& j) \, r2 ]
@,root.eventcontroller.simTime);+ _: Q' K) o* r
@.HasOrder := false;
/ v* Y5 k# v+ Q- H @.DrivingHome := true;
8 P! w- c$ S9 s) b rgManager.tryToStartTransOrder;
6 |, g, F: ~( W$ [) j if @.Destination = void" A; S& Z/ k# `4 n7 @7 L
then -- no transport order for vehicle @
# Z" }2 W2 h6 [' x @.Destination :=
, x- |$ K# d: l* h: B rgManager.nearestFreeStation(@,track.~);2 n- T7 I+ I5 d( s! u
newDirection(@); 8 U( w/ k0 d4 o
if @.Destination /= void then
+ { ~8 Q: E+ s. x( l @.Destination.NumReservation :=
3 r3 C, e" T+ W- [! g# ~, Q @.Destination.NumReservation + 1;0 ~( X" d W) E0 C
end;& S6 Z- {% j* V. q; Q" C. I
@.CurrIcon := "drivingHome";' Z! T! N2 b' h/ h. Q
@.DrivingHome := true;: |* P; Q0 b4 ^4 O) W/ r
end;+ P2 D" a& I2 v% V4 K
else -- the vehicle @ is empty, both vehicle and part are in the same dock station5 N; {0 r. B7 ~
part := @.transpOrder;1 l" y: w6 \" q* ^" b
part.move(@);-- load part
6 j, D9 D/ Z4 ~. a @.CurrIcon := "load";
8 U, B7 _) o. H' a1 Q GlobalDistObj := part.globDestination;
. I2 V8 W% m# p+ n& x assignLObj := rgmanager.rgAssignL;# P0 d: \- e$ r. Q" ?6 q- q
row := assignLObj.getRowNo(GlobalDistObj);
' n" w9 T2 k2 M7 V if Row = -1 then -- since 70
$ Y* i1 s4 E8 {, U if lan=1 then
0 h# E' V; @: R" X+ h' e promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
0 ~/ b& C0 a% m+ x" M8 Z to_str("in der Andockstation: \"",?.~.name,"\""));; D y4 l9 c1 f; m) c Q
else
' A, ?% }/ z) W( V promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
1 N7 D' N3 K9 m3 v/ C7 X+ D2 ] to_str("in docking station: \"",?.~.name,"\""));
; Q9 N* ^4 J/ U/ J& U end;
3 T/ r( I+ Z2 N' K V# x. ` else
! n! M7 p. y5 R3 c3 Z @.Destination := assignLObj[1,row];
8 b6 y# n( i1 h% H' N q end; 9 A/ Q+ T; p# ], U4 B/ T/ o
newDirection(@);
; @5 e, m! ]3 s4 c @.HasOrder := true;
8 m5 ?" f$ w: R; O3 h ^ end;
8 L, }9 c: `) C' r4 R end;" S3 n& R$ |1 J! Q& X; y" N2 T, M
end; -- of the method& N j; K6 f2 S; _+ i6 b
|