/* called by: entrance ctrl of the object 'track'7 R8 b- w/ I1 C& g4 C* b4 I( L
*/5 Q! h* c+ V! d2 Z% x" L3 L
is4 P" z8 f2 _ v! i9 M
part, GlobalDistObj, assignLObj:object;row,Lan:integer;! Y1 z* j# F1 q. I9 E
do# f" g- C; p" N
Lan := rootfolder.Internal.Tools.AOLlanguage;- @8 a& N0 g: |/ j. t
if current = @.Destination -- else return/ f4 u* Q# X& ~. N4 u$ H ^3 v
then3 G8 M& T5 @* y3 W. k' N. d, `
@.Destination := void;7 _/ j. ^7 R% z
if @.occupied then
8 N* w8 e! g7 o9 I6 x2 D/ y2 \ part := @.cont;
0 F4 _7 @+ q0 e2 ^( {/ u @.transpOrder := void;3 ~/ ^9 y( P6 [% X Q
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1, A: [' g: r& q5 Z8 `8 ^( e3 K9 f' k
@,root.eventcontroller.simTime);
' V% W3 s, F% ?9 |9 @ @.HasOrder := false;5 a* p3 F% ~0 d2 H1 }) Q
@.DrivingHome := true;
/ W7 ^6 j: X U7 }1 P rgManager.tryToStartTransOrder;
/ c, B- Q) S% n% T6 q% y/ ^, W if @.Destination = void
9 q$ g/ N; s( Q! S then -- no transport order for vehicle @
9 d8 J6 S8 z) ?+ p/ j5 e' @- R @.Destination :=" {- ~8 I4 f; d% c6 P* p/ i
rgManager.nearestFreeStation(@,track.~);
0 ?9 }1 q! z8 z: v newDirection(@);
r* g; d. {5 i, r" W# V4 m B if @.Destination /= void then
$ L' B% `0 r& ^. R) o- O) i7 E, Z8 V& R @.Destination.NumReservation :=& A/ ~# x. O {
@.Destination.NumReservation + 1;
9 w# c/ t9 s9 T* n+ q3 {: j: y1 G end;
9 K* X; Z" ?2 j- g3 z @.CurrIcon := "drivingHome";
6 g) H- h; k5 K- `, a# U9 Q6 ~ @.DrivingHome := true;
, e; \, L. K1 }: ` end;% L8 N$ H% V- |0 G# i
else -- the vehicle @ is empty, both vehicle and part are in the same dock station6 I/ ~* T) K9 c! m
part := @.transpOrder;9 O/ I* K9 n% Q: d( ~1 c2 A; p
part.move(@);-- load part
! Y# h& ?- f( r @.CurrIcon := "load";
8 i5 K2 X; J3 u7 g GlobalDistObj := part.globDestination;9 d$ J9 \% i, |4 [3 n+ l1 V
assignLObj := rgmanager.rgAssignL;
) u% N5 ^' t' @9 x row := assignLObj.getRowNo(GlobalDistObj);
2 S |3 O& Y5 D# S if Row = -1 then -- since 70
1 r1 A( e3 ?+ |( y# T/ S if lan=1 then
4 C7 a+ \7 f$ P promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
6 w# E t* ~' i to_str("in der Andockstation: \"",?.~.name,"\""));
9 i9 e, Y' G3 B6 p else# b( K5 h/ i9 R1 o! Q. f( J$ J) v# m( ~
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
& `1 q: l" Z' X% b& [% h to_str("in docking station: \"",?.~.name,"\""));
0 E: u/ W2 k) ? ~ end;8 l6 P0 C H* S2 p
else
: z$ x! t& q& E% T, h* U @.Destination := assignLObj[1,row];
5 I$ B3 Q. F& f4 f6 w/ \ end; / M0 J& O; ?! u: x
newDirection(@);6 m* ]: H4 [; n6 Q! w
@.HasOrder := true;
. `% z P% ]+ M end;
# i, g* e) l3 z end;! d- p4 T. x" y1 a0 s7 [9 k6 t
end; -- of the method
/ i' |: M7 M' u" g: F' a0 u) i( u; N |