/* called by: entrance ctrl of the object 'track'
! w. K3 R4 a# N3 b& m% @*/. b0 v; u% G! r: O/ O7 B
is4 h- k0 y d8 b
part, GlobalDistObj, assignLObj:object;row,Lan:integer;
2 ^, c) K! [ edo+ O* t l; e+ ~5 }) u1 g% j3 x
Lan := rootfolder.Internal.Tools.AOLlanguage;
8 f7 m; N% t9 g) e E if current = @.Destination -- else return
O X# G$ g* @, s: Y/ Q$ V7 R$ e then0 S" \) n& b& u2 i' E; ?
@.Destination := void;
$ d2 R0 O" i& O5 F if @.occupied then8 I2 s. I3 u: H/ x/ W8 l$ @% J
part := @.cont;
+ A* n" a5 F, d2 }) F& e/ C, r @.transpOrder := void;
. i0 ~- l1 X' W7 n9 V part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,7 h- t, Q/ g6 c8 n& ^
@,root.eventcontroller.simTime);, e6 @5 L6 T& }) O) w1 m
@.HasOrder := false;1 J3 J% j- a. c. x( s2 e' E- ]
@.DrivingHome := true;
$ p" C/ O1 |' }4 \7 g) E! G rgManager.tryToStartTransOrder;; F* I5 ]: |1 _4 X2 I
if @.Destination = void
3 E6 `7 D) X$ e6 r then -- no transport order for vehicle @0 T* R5 |* T9 J0 g) f; Z9 |* g
@.Destination :=
* O* H/ R5 Q) s; g! B rgManager.nearestFreeStation(@,track.~);
K9 }8 |3 t! y: h+ w, y newDirection(@); " q2 r M& |) c% t3 l
if @.Destination /= void then
3 P$ E j5 @7 ` @.Destination.NumReservation :=
: Z* r3 v7 t2 S2 S @.Destination.NumReservation + 1;3 j, @' C3 \ s5 r7 G0 ]( ]
end;! ?0 Z2 R( M3 B+ S% o/ [
@.CurrIcon := "drivingHome";" p, ]9 d3 l) A
@.DrivingHome := true;
& U% R+ M! T& h, j" d6 K end;6 ?7 g8 F: E6 T1 S4 L
else -- the vehicle @ is empty, both vehicle and part are in the same dock station
: |" {. e8 t# c3 A' `% M8 x" B$ } part := @.transpOrder;
! \# i" e: |. q4 e part.move(@);-- load part
9 ]- j: P" X A* O1 B @.CurrIcon := "load";
0 r9 [6 M' }4 c, K6 [5 [* k. P GlobalDistObj := part.globDestination;; z2 A3 y7 N1 L7 ^0 |' v
assignLObj := rgmanager.rgAssignL;
; X9 i% g, M) u/ Y8 [2 k row := assignLObj.getRowNo(GlobalDistObj);
% g: Z# o: R% S8 G, \% J if Row = -1 then -- since 70
0 n! B9 n9 |( [$ {3 l if lan=1 then0 I- K4 O; y" f+ ~) \5 B4 E
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
$ K$ o3 M, \" b/ Z( d to_str("in der Andockstation: \"",?.~.name,"\""));
1 t# I' n' Q( l9 z else
+ G% y- \3 O b- t+ K( |2 M7 k' s promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),& O; k4 j: d m8 q
to_str("in docking station: \"",?.~.name,"\""));
+ o* j- N+ z1 K0 b6 L$ g, ` end;4 h* y6 s; s. }: l7 G) \
else
1 V! I& t0 F8 @" g! x @.Destination := assignLObj[1,row]; o# B5 ~' V* t4 n
end;
5 f2 F( Z! I8 Y- w# K. Y newDirection(@); T0 l, }- l; ^& }, z
@.HasOrder := true;
6 `! g) M$ J l/ n( G end;
4 j) z# O2 k7 L( w" }* f end;. p) D4 X+ Y2 b
end; -- of the method
* A% k+ F. Q' D! k6 N. J |