/* called by: entrance ctrl of the object 'track'% e9 q: {7 Z$ U) P% u9 k/ {
*/
0 j6 s) |' W. E% b2 K+ jis
2 D+ ^' ?* ^, ]. o% y: w1 s part, GlobalDistObj, assignLObj:object;row,Lan:integer;( G. G# h8 a, F3 h1 Z% x8 f
do& g: ~, w. P2 a: \# f
Lan := rootfolder.Internal.Tools.AOLlanguage;6 y, [/ _* F0 f8 g* F; t6 b
if current = @.Destination -- else return! q7 d. F5 X3 S# A
then* E5 r! U( x# S, Y7 M
@.Destination := void;
) P9 i4 ~* j9 {7 q4 ?% E if @.occupied then
x z' }- _, j4 i part := @.cont;# E7 i( i+ E1 b
@.transpOrder := void;
+ x9 r" @! b5 [4 l part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,2 t; [$ r" _! S2 B0 {$ u6 j
@,root.eventcontroller.simTime);" `3 ~2 g6 P% f, w# s/ A
@.HasOrder := false;8 j- v8 h/ w& F9 k; H) X/ g5 U
@.DrivingHome := true;/ T( L# c* K0 ~$ f' U! G& T( e
rgManager.tryToStartTransOrder;
& U% M* W+ V- \" i. v! } t; o% k0 D9 f if @.Destination = void5 s( _$ W' V4 U2 [. i
then -- no transport order for vehicle @. I. \6 `/ d9 t9 n& Z1 _ s
@.Destination :=0 r Z5 N- R# C7 G( W. F( H
rgManager.nearestFreeStation(@,track.~);
! ]7 {# _" Y% o; Z newDirection(@);
8 ?# S4 }5 F8 e; K( K8 S8 q L8 d if @.Destination /= void then
9 B4 U1 c. K* v @.Destination.NumReservation :=
# `# Q( u# ^' \4 D: s @.Destination.NumReservation + 1;6 H# D6 ` `% @% _( b% ^4 Y a
end;. {# |8 t& d+ k1 s+ R
@.CurrIcon := "drivingHome";
' {' V- L% A) X, v) t @.DrivingHome := true;
- e4 c3 f% ~6 A9 g& { end;( p5 q8 c/ @2 r; b9 R# I$ o& K! C( z7 h
else -- the vehicle @ is empty, both vehicle and part are in the same dock station; M: e3 N7 y) f* e) L6 b
part := @.transpOrder;* @* S1 Y& _1 Q. W
part.move(@);-- load part
' `) }$ x# Q. W. |- k, W7 Q, o @.CurrIcon := "load";
7 g& v, W, L8 Z- N! G" E; C* y GlobalDistObj := part.globDestination;
6 E. M. H, E- b% s8 j3 Y assignLObj := rgmanager.rgAssignL;1 q, X, z7 Y3 t$ }9 p& \1 U
row := assignLObj.getRowNo(GlobalDistObj);
& i9 u1 U0 B% ^. ]# M if Row = -1 then -- since 70
/ |: i$ k9 ^/ L5 ~& u/ ^ if lan=1 then
1 N+ O$ ~3 `$ A( e6 x promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
" t& t* C3 g4 u: ~$ U to_str("in der Andockstation: \"",?.~.name,"\""));, }) y# e* P/ f/ Q0 d+ x7 B; k
else
6 x8 }6 l: ~. Q promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),* i+ W: \& {6 ^" u. S5 ]
to_str("in docking station: \"",?.~.name,"\"")); ! P. p4 \9 [( P1 N, e; o/ Q
end;0 n' c3 W. i; y1 ?
else/ p6 D4 ^: D/ u$ W
@.Destination := assignLObj[1,row];
3 p/ I5 G4 g- a end; 1 i8 S7 ^8 Y% X2 \8 ]3 w
newDirection(@);0 ? i" c+ X0 {; c0 I$ n& V
@.HasOrder := true;, n6 x! c' j! A5 B: J( O
end;9 i2 t7 Y, d* Y5 Y$ @' v
end;
, r- G2 {6 C8 K) X; X# H0 x* pend; -- of the method
$ N* \; O* k0 C |