/* called by: entrance ctrl of the object 'track'
0 q6 l1 J- U7 I d4 n*/
4 k% ?1 ^/ R5 g" S/ e& w: dis4 _; p& z1 |. f8 s& L
part, GlobalDistObj, assignLObj:object;row,Lan:integer;
# ?; D; s+ j4 c( E, Odo
# [0 P* g' e- _7 i1 B Lan := rootfolder.Internal.Tools.AOLlanguage;
. E1 K; G6 [0 W7 C if current = @.Destination -- else return
1 w4 z9 ]; {0 @( s! Y then
' j, g8 `% d! T @.Destination := void;2 O- }$ {8 h( z4 v8 q/ d
if @.occupied then, C) w) l5 P9 J$ q
part := @.cont;
7 |+ h! g' _' n @.transpOrder := void;9 S p d' V6 ^, p& R* {7 D1 x0 l
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
+ x% e# Q9 N3 `) ~2 S! |. N7 d @,root.eventcontroller.simTime);+ \) ?6 d1 R8 y) `7 j
@.HasOrder := false; \( ?( u& J, I, S+ n
@.DrivingHome := true;
# I+ e9 a% K3 C o, `# o3 a rgManager.tryToStartTransOrder;
- A& D1 D8 s C- I if @.Destination = void
7 `. ~' E9 z0 K# T. \ then -- no transport order for vehicle @4 j* Q) @: u4 O3 j, F
@.Destination :=5 l, q2 A2 _. d3 G! X* z3 F
rgManager.nearestFreeStation(@,track.~); _! p2 B( z' E7 T. y
newDirection(@);
2 z3 s" F8 _5 }- |+ G if @.Destination /= void then; C: d/ G* I" N2 e: }% i
@.Destination.NumReservation :=
: G" d) e5 Z$ X3 b( `* C& }) }; n: V @.Destination.NumReservation + 1;- ^2 U$ M- K' h- `) u
end;
8 B9 x" k7 f7 |; F" b8 ~ @.CurrIcon := "drivingHome";
1 M0 _! t$ k# U% m- I, \ @.DrivingHome := true;
6 W: ^& t7 ? v4 ^1 W% u end;
1 T4 H$ E0 p( E! V; U6 V else -- the vehicle @ is empty, both vehicle and part are in the same dock station5 n6 p8 Q2 T. d, f# K- F8 q
part := @.transpOrder;
8 {! E4 p! F! A( \( S1 \, a part.move(@);-- load part
5 M' r/ X* L. E( Q @.CurrIcon := "load";
# z$ t3 M, @6 w GlobalDistObj := part.globDestination;; W3 T+ F( T6 A+ V) e! ^
assignLObj := rgmanager.rgAssignL;
0 J. n( S) t% o" w row := assignLObj.getRowNo(GlobalDistObj);
2 `/ J+ [ J& {# V2 l3 R' b1 i* Z if Row = -1 then -- since 70, r4 P8 l6 H, J* L% A3 Q5 m& [
if lan=1 then
# d2 p0 Q& T' d+ O promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),6 _( Z, C7 B' l5 t% L0 a
to_str("in der Andockstation: \"",?.~.name,"\""));1 i* d6 o1 R' u
else
% ^3 @8 T7 E" S" ] promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
! D' o& B# s5 V7 [# c0 g1 l2 l% { to_str("in docking station: \"",?.~.name,"\""));
5 S, r0 X$ M& `" A1 f end;0 b- |0 M! s: F) |0 ~7 G
else
' H! \1 t7 d6 N! { @.Destination := assignLObj[1,row];
% ^6 ^0 l* i: z$ C# d; ]0 l) t7 f. n ^ end; / O4 v8 o& }" O# k# \
newDirection(@);
6 e8 m" G6 N# B) y* b @.HasOrder := true;
. d8 j/ ]/ P! \/ M3 c3 } end;
0 _. m6 E: i* X" O, n6 l+ v end;- G$ U: T* I5 Z! e
end; -- of the method4 N2 D/ j3 w! c# G7 V8 v1 }& g
|