/* called by: entrance ctrl of the object 'track'
2 K" S& ~+ u6 e, x5 P*/& j3 ^; f6 c) Y* R6 `
is
# V2 [/ t( A. @# X" C part, GlobalDistObj, assignLObj:object;row,Lan:integer;% B7 G$ K0 e8 M/ e) q5 y, q
do
' p4 v! N3 c- r0 q Lan := rootfolder.Internal.Tools.AOLlanguage;3 }& K' w1 G7 ]/ H5 K& E% {
if current = @.Destination -- else return* o* K L9 f, d0 ^
then0 F; ]/ a9 E; P$ g
@.Destination := void;
* p7 P( m) p, t if @.occupied then$ f2 {( U$ B+ W4 |2 h9 K8 |4 a
part := @.cont;: S0 P7 z: @3 M" ^4 A
@.transpOrder := void;4 m2 u4 V; w) Q! h
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,6 c- p* @ ~/ q4 u
@,root.eventcontroller.simTime);
. {+ Q1 v7 {( u% x/ w8 q8 s F; b @.HasOrder := false;
7 d& o1 E+ Q3 L/ |$ \' ^ @.DrivingHome := true;
3 \9 P' }! w) w5 M4 G6 S rgManager.tryToStartTransOrder;
9 p# V' v' V8 W9 E- n if @.Destination = void
2 a {9 { d( M. ? then -- no transport order for vehicle @
, G' t- P4 b1 W# t u7 P1 p1 b' g5 x @.Destination := Y+ H& h# C/ g. V) ]2 L
rgManager.nearestFreeStation(@,track.~);. \; f/ U5 e+ p7 s* k+ i3 J' h& u
newDirection(@); 1 A3 o/ V( A- ?: s/ S1 D- O0 E! c7 @: q9 l
if @.Destination /= void then
+ a# i1 {9 l' P6 l @.Destination.NumReservation :=: _+ y. `9 s" F5 L$ d" C2 C! h
@.Destination.NumReservation + 1;
% [, _9 P9 V4 k1 V! M \ end;( T: d( ~; K' d" O( @% ?5 W
@.CurrIcon := "drivingHome";8 y; J: j2 R. H. e6 j+ c
@.DrivingHome := true;5 v+ V1 A6 p0 m& [: f0 r
end;
4 H% L' i; ~) k) ?* Q4 d/ S. Z! P else -- the vehicle @ is empty, both vehicle and part are in the same dock station3 t: F5 o( K0 ^: |8 D& o: Y
part := @.transpOrder;
2 ^% z! D8 }. o6 s0 _- q1 M. _ part.move(@);-- load part! R( T( J7 P4 c f% X
@.CurrIcon := "load"; l3 s! q. x k/ _. q G D
GlobalDistObj := part.globDestination;
( ], Z! W0 o- Y9 K assignLObj := rgmanager.rgAssignL;& J" t+ y9 V ]& Z1 r+ K
row := assignLObj.getRowNo(GlobalDistObj);
+ c3 r' m, @3 H' x( C& k4 _- M if Row = -1 then -- since 70
2 Q" h! M: Y6 U if lan=1 then! N% M2 m; ~- r$ B
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),- e$ n% k& H( t& w+ B" }
to_str("in der Andockstation: \"",?.~.name,"\""));9 _6 W: |. `1 y, `) r
else
" t/ G( y+ B* p0 {# k: U4 E' B promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),; s; u9 r6 `2 g; X( W5 r" o! J' D
to_str("in docking station: \"",?.~.name,"\"")); 3 a6 m( u4 m! F3 {1 Z: m
end;
4 f; l% G* o1 A7 K# r else
! X3 I0 P4 O! C7 M! y* M5 U @.Destination := assignLObj[1,row];4 ]$ N6 G& @3 [; I. [& d5 k2 O
end; ' k; A( A% W9 | F
newDirection(@);
9 y+ H$ z$ J& Z. K; G @.HasOrder := true;
- s; Y2 a9 F+ _, }+ q6 A* p end;& ?) F$ F; e! J2 d# h2 ]% ?/ N
end;* j: m7 y, }7 ?/ @0 u2 w
end; -- of the method
( p' X( j5 V3 @- X1 v/ E0 B |