/* called by: entrance ctrl of the object 'track'
0 @' c. X) }; {4 U" g: v0 v! w*/8 \# N, @ K+ U1 L3 E+ a8 o
is
0 B2 [4 }- P. Z+ ^* @2 G part, GlobalDistObj, assignLObj:object;row,Lan:integer;& r& I; S" ?" A' }7 V. o
do% I- C9 l8 l' g- z6 G+ Y7 F
Lan := rootfolder.Internal.Tools.AOLlanguage;
, z" F4 V0 _, i5 y& U if current = @.Destination -- else return3 w9 t3 ?. d7 ?$ a4 \
then
0 |+ R6 Y! T x @.Destination := void;3 O+ |* k4 \# |( v6 X8 N+ `3 {
if @.occupied then
2 W0 r$ x% h; ~# P4 C2 } part := @.cont;
3 K- x1 M* c" t" Q @.transpOrder := void;+ i# @5 l: ^' X* T# E
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,, a0 S( }6 \+ c. E
@,root.eventcontroller.simTime);& y( U1 f& _! _/ U( D. ~
@.HasOrder := false;
' ~. D$ ?# W7 b2 R0 Q6 z @.DrivingHome := true;7 @. ^8 A5 _; K! y$ u. p) O' d
rgManager.tryToStartTransOrder;/ G. W. G5 [) I8 W& D
if @.Destination = void& i/ Y# L* D5 u5 U
then -- no transport order for vehicle @& E1 G$ @: A- s7 v- v
@.Destination :=1 S2 q3 l6 F$ c2 I
rgManager.nearestFreeStation(@,track.~); h4 w9 [1 Q- w
newDirection(@); ! H# H# W: q* [4 D. H; U1 J/ S
if @.Destination /= void then. `" O, O7 j6 y
@.Destination.NumReservation :=% g5 |4 U2 I O/ g
@.Destination.NumReservation + 1;/ p- o0 A) f3 q
end;
" c5 W. X' j7 S* v( S0 R @.CurrIcon := "drivingHome";
9 S, k3 p* Z; ^$ {9 \ @.DrivingHome := true;6 ^9 l7 [5 W$ x0 T3 X
end;
, y# x% Z1 W7 d k" I0 `. @8 D* s. G else -- the vehicle @ is empty, both vehicle and part are in the same dock station7 z2 M. F! V& i: k/ x1 F( h+ r; G
part := @.transpOrder;4 O: P" u+ d$ b+ J4 v$ r1 P
part.move(@);-- load part
3 M' e1 w" l- p+ q% _ @.CurrIcon := "load";
- M5 r' D+ a" `2 D7 p9 u+ W/ z/ F GlobalDistObj := part.globDestination;
. n$ Z5 I4 M d/ k' P3 d3 l H assignLObj := rgmanager.rgAssignL;, X3 m. x8 B1 k/ U. m2 J
row := assignLObj.getRowNo(GlobalDistObj);
. d6 t: x+ `. p4 N$ N0 D if Row = -1 then -- since 700 }; m9 G3 B% q* }& e0 R/ q
if lan=1 then$ ]5 l6 b3 r; p& f* ^4 R9 a% C" ?1 a
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
& p. f. c. r1 r to_str("in der Andockstation: \"",?.~.name,"\""));" [1 ^* X( d* V2 ?) i- ]
else
8 e6 x* Y+ Y1 C1 j' j( E8 i% D promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
2 Z {0 q, {5 l to_str("in docking station: \"",?.~.name,"\""));
* I5 j9 E; V3 D end;
, n& J4 `9 A5 e' y/ t% W else
, ]: t' W& a4 z+ d% t) @ @.Destination := assignLObj[1,row];
1 J( J8 q4 Q; } end; + Y; {2 c7 k7 a+ L' `9 k
newDirection(@);8 `, ^( U1 A% U3 n+ e" X
@.HasOrder := true;9 o( y; A& |# Z; t2 H4 v" ^
end;9 R$ V5 |; s- i
end;
% x+ G3 E& I, y. H5 k' ^end; -- of the method" g$ [) ], W7 p1 H0 I7 G3 g! a
|