/* called by: entrance ctrl of the object 'track'' a) d7 H7 x$ ?9 t0 N5 e
*/5 q- l% w% X0 F" t) v' `
is
- _$ I$ B4 S+ f( [% T) w+ }% M part, GlobalDistObj, assignLObj:object;row,Lan:integer;$ `8 M; \* Z5 C3 g: @3 n6 k( f
do
% C; L7 b- ~9 v& Y0 o* |( u Lan := rootfolder.Internal.Tools.AOLlanguage;
% X. W0 i" j j! \7 _ if current = @.Destination -- else return* C3 ]9 w$ E6 `! l9 @0 K* F
then
. _! ]$ G$ `- s0 X+ n) P/ V @.Destination := void;
$ s7 i# \( b0 C8 _ r if @.occupied then/ @9 x5 m1 y9 y
part := @.cont;
' o5 @2 ?% Q) x$ u @.transpOrder := void;
8 ^1 ^& X5 ~* ~& o# ~ part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
6 B/ W a4 J" A+ Y$ F0 e' l8 g @,root.eventcontroller.simTime);
L+ V9 p/ j" r- i! c5 m @.HasOrder := false;
0 c% }9 x, P! `% E# n9 m @.DrivingHome := true;
7 p7 M o4 ~2 B rgManager.tryToStartTransOrder;
$ m) d8 ~, R% K+ N, |6 R if @.Destination = void
9 `$ w9 s5 `3 Z6 ^* K8 O then -- no transport order for vehicle @$ N/ d- |9 J; k% J% G& F+ ^( t
@.Destination :=
9 F8 f* K4 W: ^ rgManager.nearestFreeStation(@,track.~);
4 ^# m2 F0 [ B' k+ m9 @0 Q/ W6 Z newDirection(@);
7 E/ {+ l4 K) c; @8 |$ r5 l/ {& D- R if @.Destination /= void then
9 w* h& G1 p3 ^( y4 W9 | @.Destination.NumReservation :=
2 S2 h/ r$ }2 a; S% r, V( L @.Destination.NumReservation + 1;
7 F7 X3 y$ g% t8 f* L9 r end;
; f( }" J1 |& i: s( G3 O" G @.CurrIcon := "drivingHome";
n& f2 j1 Z. T- Q0 n, b8 _ @.DrivingHome := true;
1 |# n8 d) K' _, Y end;
; L/ J9 T' u( B6 ~4 Q- k else -- the vehicle @ is empty, both vehicle and part are in the same dock station
+ j4 n3 p. M3 A, v! I! n M part := @.transpOrder;, l V1 Z/ ~$ j$ E
part.move(@);-- load part
+ C* }7 ?( q0 Q$ ]( p @.CurrIcon := "load";' E0 W0 A/ I8 z1 s/ {+ M* L3 }
GlobalDistObj := part.globDestination;
, N. I5 B0 `" R! U5 ^# x assignLObj := rgmanager.rgAssignL;
, A: j$ v9 {9 A row := assignLObj.getRowNo(GlobalDistObj);
: h- W5 }% c9 z# R# t% A2 `4 ] if Row = -1 then -- since 70
# w; R5 ?" T1 v* U$ y# t if lan=1 then
: e! ^ i" Z8 q: x5 i promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
6 u' M2 A T2 F% k# ] to_str("in der Andockstation: \"",?.~.name,"\""));
F: r7 @3 E6 g3 |5 ^' V else
( T9 G6 J0 m2 L3 I6 G% ` promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\"")," a" V; v" p! ?7 E# e9 _2 B
to_str("in docking station: \"",?.~.name,"\"")); / c1 B3 E5 B( E
end;
9 B4 K* T* b$ D) _ else6 I: q6 ], r" I6 ?
@.Destination := assignLObj[1,row];
; s0 m2 p1 \" Q2 E* K end; 9 L+ b! y# |6 N& h- y' H$ v5 k6 d8 o
newDirection(@);
. T7 T4 S" }, q @.HasOrder := true;5 m0 ]4 r* T) N b! b0 ^
end;
1 s" P% d& |; k1 f) b9 J end;; }: ]6 p+ X# m9 Q$ T
end; -- of the method& m8 `' J3 U/ J7 p) L+ }, l% Q+ o
|