/* called by: entrance ctrl of the object 'track'
1 v& v' D& [+ Y8 x+ ?*/) y" a' k0 H, b1 N6 d( q
is
2 `( F( U f( [) J8 ^ part, GlobalDistObj, assignLObj:object;row,Lan:integer;
4 V$ z* Y* F) a7 j! e! |% udo$ _, Z: Z4 }; A5 B* @* I( X
Lan := rootfolder.Internal.Tools.AOLlanguage;
4 T/ f7 Y9 s+ u7 U- ^9 q: C if current = @.Destination -- else return
. ^) o3 l* u4 d then1 F5 N5 y o1 p1 z& t# y
@.Destination := void;( t. |' n& d& G3 A: d
if @.occupied then
7 ^, g& h4 F! ~% U7 ]5 g- Q3 _2 l# F part := @.cont;
* w5 B6 E7 E* F9 d) G; s. u @.transpOrder := void;/ o& w$ T# _0 x2 M" R
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
+ Z9 H+ l! ~) e6 G) m1 m3 { @,root.eventcontroller.simTime);! p$ U( K; P- Q
@.HasOrder := false;% Q( L) }: } T, @1 o& f" u
@.DrivingHome := true;3 S6 O1 q% X5 r" z
rgManager.tryToStartTransOrder;
9 |% R7 i& h: z9 x; x if @.Destination = void
; x; n1 c3 d0 n' v; ^2 u then -- no transport order for vehicle @
" L4 [8 v4 O0 A F @.Destination :=
, K. ^$ N" @6 W( _3 U rgManager.nearestFreeStation(@,track.~);4 Y- P& W& f* `8 `- k, P4 p
newDirection(@); 4 q' R v6 W/ y4 n: q
if @.Destination /= void then4 ^4 m3 j8 @6 Q: x' T- U
@.Destination.NumReservation :=6 C: U5 l& g7 Z1 l: g8 R- {
@.Destination.NumReservation + 1;0 t" x& F1 t4 D* z% m& e& B/ ~
end;
+ |9 p4 o- C% v9 H1 f& G @.CurrIcon := "drivingHome";# z9 @! t& N0 w" B
@.DrivingHome := true;* [5 k7 ^! X! E) k
end;( I; s; H/ V! C w& H7 Y6 C
else -- the vehicle @ is empty, both vehicle and part are in the same dock station* @8 v. ~6 r' v; K
part := @.transpOrder;+ M0 B( q& V' V J; a
part.move(@);-- load part
# l+ ~* u6 T& l( @! i/ M2 e @.CurrIcon := "load";
8 C3 L, j. M# O% c0 B# X% l6 J GlobalDistObj := part.globDestination;
, n; e& Z$ E( k/ _" `6 T assignLObj := rgmanager.rgAssignL;
" r4 @% ~5 r7 f# h3 w# P2 x row := assignLObj.getRowNo(GlobalDistObj);
1 W+ t) U- F+ m: D2 Y }" K y7 T if Row = -1 then -- since 70
$ n- {# I" D; h9 J if lan=1 then- l P: S8 a$ j0 t5 r
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
0 w1 |8 p, @+ ` x* ^' Z6 B5 \ to_str("in der Andockstation: \"",?.~.name,"\""));
; M! \3 e# M3 J8 L5 o* ? else
- R; V# g" s' T5 u r promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),& ^8 ` |2 a5 r3 Z& [1 D4 x6 O3 P
to_str("in docking station: \"",?.~.name,"\""));
* b2 J0 u0 l* W. R9 f# n end;
: f& Y( s; N9 }5 l else
! j" {2 t4 N: M. u$ H- f1 } @.Destination := assignLObj[1,row];
$ m' v% M, p% Y end;
0 `/ G) T, y" b9 e/ e1 ^$ D4 q$ S8 v newDirection(@);
# M+ O' u' \4 C1 \5 y: d2 l @.HasOrder := true;
4 m0 V6 ^* s: ~9 _ end;
. h/ I* x$ R# W: \' W/ F end; k/ h$ _( ^ h3 O+ e
end; -- of the method9 E. {5 L! F. `! K) m' x' |- G. [
|