/* called by: entrance ctrl of the object 'track'4 c% y* j, v/ C
*// I( _5 K/ X6 I9 Q( J5 o
is' s8 U' A7 ^/ d+ Z( ^) `, E
part, GlobalDistObj, assignLObj:object;row,Lan:integer;
+ [: r" V- F' p& L) udo( y9 X( M3 E# }! |/ ?
Lan := rootfolder.Internal.Tools.AOLlanguage;
8 p6 h0 }: A% f4 o" A4 m2 j. W if current = @.Destination -- else return1 S8 r2 K0 V4 g( u+ H% \
then v7 p; M* ~2 R0 x, j
@.Destination := void;
7 v6 ~( a1 T# y if @.occupied then
+ L' g( q# J0 k4 a" u; u% n v/ \0 r part := @.cont;
) @* H! V. h4 Q# b" r# U. c @.transpOrder := void;
) l$ E/ N3 G, b7 \' k+ w part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
, z; h6 U& Q9 x, n( P2 L* M4 v @,root.eventcontroller.simTime);
) j' ?) P c% ~, q7 ? @.HasOrder := false;
" l0 S. e* W% c0 ] C @.DrivingHome := true;
7 X& x( R1 ?/ _, u ~* {# C+ s rgManager.tryToStartTransOrder;$ x* n; \% d) m2 ?
if @.Destination = void
, Z$ ?' P2 k& h y$ u% `' N then -- no transport order for vehicle @
|6 y; ?4 v" r6 |: V4 h% e; Z @.Destination :=' ^! K% o0 {' B( C* P8 [" }
rgManager.nearestFreeStation(@,track.~);
- \3 X2 @1 b* \- a) j& x5 V( _ newDirection(@);
. g& H. `, x3 E& b7 d if @.Destination /= void then
; R8 o# i `9 F! @# u$ L% h3 S x8 y @.Destination.NumReservation :=- x( j* t' u& @2 D, T
@.Destination.NumReservation + 1;
. Q( D: X2 B& Z ~! T end;
8 Y% w: c9 j6 `) _7 \1 \ @.CurrIcon := "drivingHome";
( D$ _* {5 E b4 r @.DrivingHome := true;. j0 _. d5 H& G% s& f
end;" q/ u; s: C0 H+ ]
else -- the vehicle @ is empty, both vehicle and part are in the same dock station
) p; G! N' m& f& s/ y& O6 ` part := @.transpOrder;4 ]$ m# a7 a% _: o7 Q5 G
part.move(@);-- load part# [$ L- u+ k4 W+ y& `, ~- c
@.CurrIcon := "load";
# m0 i7 T. c) I0 f1 v2 U9 v GlobalDistObj := part.globDestination;9 I! k$ ?- q' Z+ M' n4 f$ s: R1 Q
assignLObj := rgmanager.rgAssignL;
3 Z+ g9 E# B& {5 m5 Q, l row := assignLObj.getRowNo(GlobalDistObj);8 ~( [, D% ?, H7 ?0 H/ f/ q
if Row = -1 then -- since 701 `' H( K7 c8 C" |
if lan=1 then
% M5 f {! {; K! Q promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
' a1 ?9 t% z" `0 E% b3 v to_str("in der Andockstation: \"",?.~.name,"\""));0 m% F |( m' r, X
else
" l# h0 c, |& E" Y/ O: ^$ B* ~ promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),, i( q& w* @' z0 }5 q) d
to_str("in docking station: \"",?.~.name,"\"")); 1 N) u7 K% B+ r V5 J3 T
end;, V: a1 p0 U6 ?- b% M
else+ B. I5 K& a) f' |: h
@.Destination := assignLObj[1,row];5 E; x! q- J# a& h1 J2 H
end; , C5 d8 i$ c# y
newDirection(@);5 E& A6 ~- z0 ?2 a# j
@.HasOrder := true;
; w5 g4 A# l" k2 t2 c1 ]9 M) k end;
# u& m+ Y9 G! g l8 | end;
8 }4 y$ P6 Y; u% A; Z- ~) ^9 vend; -- of the method
/ Z4 l" I% p$ ^. X; z, w/ c$ J |