/* called by: entrance ctrl of the object 'track'
* G2 n% n8 Z8 y0 M, K*/
6 H' d8 O a Iis
2 u2 r' v; O6 b% O; ^" U9 p part, GlobalDistObj, assignLObj:object;row,Lan:integer;
6 ~6 b9 R5 J- E* M: m8 mdo( ]* _( X1 l) U) k8 W
Lan := rootfolder.Internal.Tools.AOLlanguage;
# ^' n4 ]8 p7 c$ J) A* W if current = @.Destination -- else return
* u) C( o, d& c then7 y! J- y9 Z* v, N
@.Destination := void;- f) j) v! ?7 v& w4 ~' \
if @.occupied then
5 {' X; l: f* r$ j& \, f part := @.cont;
( R! p4 U, o5 B) J @.transpOrder := void;/ B9 f* _# O6 i |2 d
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,5 q4 x6 n/ [# U8 ]2 q( H
@,root.eventcontroller.simTime);
% {4 l. b" m3 U) \ @.HasOrder := false;) W; [7 O( s ~0 _! i0 ^( o5 W j6 N
@.DrivingHome := true;
2 c; F/ X! M" Z( R rgManager.tryToStartTransOrder;
* I, J4 g. y' \. u! x9 q0 k if @.Destination = void
6 O2 r& k) v- c' B9 f2 ` then -- no transport order for vehicle @
3 ]' W2 k) ^% g+ W& E \* k: ` @.Destination :=0 G* U* ^1 H( v" |9 v9 Q
rgManager.nearestFreeStation(@,track.~);" o' c0 [7 F) J; P) j* [
newDirection(@); 5 M9 n6 R, k; {$ L. N, l. j( P
if @.Destination /= void then
+ G- ? X: I- ~' u: w) b @.Destination.NumReservation :=" u2 k. h& Y6 f
@.Destination.NumReservation + 1;
/ `. y0 @' _! X end;
, E1 v* M8 h9 }6 o @.CurrIcon := "drivingHome";
- d$ `2 I2 e6 }: c @.DrivingHome := true;
O4 Z' j6 V1 ]) E! I$ P3 F end;. c0 ]8 [5 U5 }( m7 g3 v
else -- the vehicle @ is empty, both vehicle and part are in the same dock station
K& g, F' e P part := @.transpOrder;
1 N( A7 e% p. i8 Y' {( n part.move(@);-- load part
9 K2 O8 A6 J+ X' B' N- o @.CurrIcon := "load";
! L1 \5 F$ u/ P3 H" d3 `) i$ I GlobalDistObj := part.globDestination;% R, a/ ~7 x" a/ R/ T( @- F H
assignLObj := rgmanager.rgAssignL;& k6 Q) {0 L+ C, z# O2 r0 I
row := assignLObj.getRowNo(GlobalDistObj);
" E! s) D0 ~* s* q8 q: ~# a7 a if Row = -1 then -- since 70
; r* P, {. i6 ?, y/ e if lan=1 then3 M# s/ A+ A5 V- Q2 G
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
% g* p( _) w# q% e2 v \ to_str("in der Andockstation: \"",?.~.name,"\""));
$ j y( V# _- I. I5 F" r) _8 l else5 z8 q+ ]# _0 f+ ?6 i
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),; t! J. l4 W9 k( l: J) b6 ^+ Z
to_str("in docking station: \"",?.~.name,"\""));
' ^2 v! @) j* @ end;7 x8 D6 W$ E. G# K& K9 l
else
6 e3 h- {& E( M0 f @.Destination := assignLObj[1,row];' O3 Q" h" u. @1 N7 I
end;
' \! s1 [# P" ]* z newDirection(@);
7 k/ ?# n9 N! B% i" g! L3 j9 j3 L @.HasOrder := true;! [; A, q# {8 I d! Q6 R) i: B
end;
6 O6 l! k# `; B3 M0 j. M# @, F( K end;
4 Y, v7 D, M: w5 }- }( |end; -- of the method
& j1 o4 [* _+ e8 }/ k; |2 b |