/* called by: entrance ctrl of the object 'track'
5 @$ j2 G1 A% C# [/ W& l*/
( p6 [8 l3 K1 cis
* @6 M: B7 m( x* s5 G part, GlobalDistObj, assignLObj:object;row,Lan:integer;
- H. \6 j5 R4 w/ e) ]% g; a2 U' Ddo) D* \: l( y3 S+ s
Lan := rootfolder.Internal.Tools.AOLlanguage;$ K% M9 b3 l% a8 @
if current = @.Destination -- else return! a2 {) R9 _, Q7 b5 Y& Z0 y
then/ u. Y% o/ r: `) b+ N
@.Destination := void;3 K- G$ o9 X$ E0 |
if @.occupied then. \$ Q4 y7 z6 f- f% y
part := @.cont;
' p& T& v6 r' O0 a: D1 A3 }' F( o% j @.transpOrder := void;4 [# @7 W: a6 h5 ]! V7 }
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,$ J* Y, G. s# N6 e9 V
@,root.eventcontroller.simTime);
+ R3 {! h. \0 n4 Z$ p: z @.HasOrder := false;: w2 g3 |0 e' E0 P
@.DrivingHome := true;
1 w F( K) _. i" d' k7 V- g' U rgManager.tryToStartTransOrder;
! e* @+ ?3 O+ j# G$ v2 T if @.Destination = void
% I2 j2 f& x0 n4 R! [' k8 f then -- no transport order for vehicle @6 g* h1 E& x8 w \3 l
@.Destination :=% J& ]$ \6 T/ j; U
rgManager.nearestFreeStation(@,track.~);5 M: [+ v# O' V
newDirection(@); $ Q2 H0 C5 H" z% o
if @.Destination /= void then
% I9 P' A& c0 ]7 f; I @.Destination.NumReservation :=
( N5 V! b% E1 T+ G, V% I @.Destination.NumReservation + 1;
% A$ V6 v: T/ i& l* L' [! r) J end;: x9 e& k- v& c5 a1 I/ R4 E
@.CurrIcon := "drivingHome";% E. D0 Y( _" u; ^7 v* x5 P0 l
@.DrivingHome := true;
0 n7 n1 j" @+ W+ S/ o- J2 Z) V4 i8 ? end;3 h) Z( I& V* w6 r8 \
else -- the vehicle @ is empty, both vehicle and part are in the same dock station4 H2 U# X/ m; M5 d- i4 x6 q
part := @.transpOrder;
! X o$ i# N- s N/ F part.move(@);-- load part" E9 D y* X, t4 A
@.CurrIcon := "load";
, E7 N: m+ p! m) f* p1 T" e% }) N/ }( y o GlobalDistObj := part.globDestination;
! d4 A. r6 t; @& [: W7 O% m- N assignLObj := rgmanager.rgAssignL;: d" k! ^ T! W g
row := assignLObj.getRowNo(GlobalDistObj);
9 k2 N: a; @9 P7 T% p6 |8 O if Row = -1 then -- since 70$ h t6 v- j! c* q" L1 y( D# Z, U" _
if lan=1 then% ?3 x% K7 g; K, u8 v
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
( E9 J) T- X- |/ } to_str("in der Andockstation: \"",?.~.name,"\""));% l6 M) A" X( X) H) E7 j
else: Z: M4 } F" @5 W, s
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),$ c; |3 t; k" }6 v4 t/ H+ j
to_str("in docking station: \"",?.~.name,"\""));
3 u" |: F* B7 c& T6 j end;
4 P! a* p# n0 n$ h# X1 U else% r# i8 a/ ?8 m; [; I
@.Destination := assignLObj[1,row];
3 g# @. i ~5 x/ I+ x, e- N& Y+ L end; 6 b1 I% _9 i0 Z3 L
newDirection(@);7 v8 J* E- s. J4 M7 r% R! N' [# h
@.HasOrder := true;
+ D5 N% F+ p7 c2 n! r' s8 P. j | end;
/ V9 ]! C) V2 F1 C end;
4 \4 p+ b8 _; }, a% dend; -- of the method" x3 q c+ C: U0 L
|