/* called by: entrance ctrl of the object 'track'
+ y* H8 X0 x, [/ R) P*/
1 |3 ?& l8 r! R+ M* o" j; jis' G( `+ c- Y" G: N( _
part, GlobalDistObj, assignLObj:object;row,Lan:integer;/ Z- E( e: p% H+ t" x/ {
do: A7 ?8 k, i' M8 p' [& W
Lan := rootfolder.Internal.Tools.AOLlanguage;$ L& b4 C0 ~. v( y% A* D1 ?
if current = @.Destination -- else return
/ @+ ~7 @6 j6 e9 n then! C+ p& v- z. B! `7 f/ O( B# C4 \
@.Destination := void;
, G4 E' r* p$ w6 M if @.occupied then
. O9 M. b8 `8 z part := @.cont;
+ b5 }5 ]' ?, e% ] @.transpOrder := void;/ ~* P# O& K. b6 N- ] F; W A
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,( C8 z4 A1 g) s ?+ `; Q+ \
@,root.eventcontroller.simTime); @) a& ]/ x8 P
@.HasOrder := false;
9 A- H' }8 g& b @.DrivingHome := true;
6 q8 J* U9 y, g1 S4 |" M/ n rgManager.tryToStartTransOrder;
* j2 [( t5 Q. ?- l$ O if @.Destination = void
% F: c- V4 B$ L$ Y O then -- no transport order for vehicle @# U5 w: P. p! ~7 y
@.Destination :=4 w/ ?% g' F6 H
rgManager.nearestFreeStation(@,track.~);
0 |. |9 G$ H( P4 b newDirection(@);
9 m6 ^/ o7 z9 e0 ]$ w if @.Destination /= void then( t M. Z% ]% t6 `4 ^" _1 Q+ H
@.Destination.NumReservation :=
5 Q" c8 S1 P4 z! t. f @.Destination.NumReservation + 1;4 {- ~9 \5 S/ t
end;
. u; Z. X& j, i3 B' X @.CurrIcon := "drivingHome";
% d( W% y7 T! l* l7 m3 ~2 q3 b- Z) Y @.DrivingHome := true;" e/ x7 P9 O4 M" \
end;
- \0 a M, [0 ?. F4 T else -- the vehicle @ is empty, both vehicle and part are in the same dock station
- M* p p4 s; v4 | part := @.transpOrder;
. k1 z; t& @8 e4 Y3 u2 { t" A part.move(@);-- load part- Z- R, d/ [7 [3 d
@.CurrIcon := "load";
0 C7 Z( |) e8 P& e9 O" c: s9 m GlobalDistObj := part.globDestination;
# N3 ]( m% i+ L1 W3 M/ ^ assignLObj := rgmanager.rgAssignL;
9 `. X8 K; D7 l% Q8 V* N row := assignLObj.getRowNo(GlobalDistObj);3 f; H' A' ?' f4 F3 W! B
if Row = -1 then -- since 70
; M! B& M, R, j& X if lan=1 then: g ` k# c% \* [- F+ b" N
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
$ }% N# y* X& A- v/ n* g% N to_str("in der Andockstation: \"",?.~.name,"\""));$ Y, l8 k% C; X% _$ ^7 W
else
l+ g3 e+ W* \" a6 t' R promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
. Q) i; I' e! ?7 h N to_str("in docking station: \"",?.~.name,"\"")); ) a' n2 y1 t* X8 l7 `1 j! m
end;# T$ W: g" k6 k$ `. |# e. ? E* Y
else- [. X$ _( k' A: P* } n* E
@.Destination := assignLObj[1,row];
, |$ H. Y% J) m1 y( q3 y" h end; 7 i0 D- A; I, Q+ {0 W0 ~
newDirection(@);
# d7 S S# {/ j! m. P @.HasOrder := true;/ J7 _: n: v- A- E, y
end;- m9 r; w# Q7 A, R
end;; ]& \/ h1 D" c* `, w) Y) }
end; -- of the method
6 h: ~, |/ L' Y |