/* called by: entrance ctrl of the object 'track'$ [( }# f3 Z! `
*/! }8 j/ n5 H, E K! \2 E3 X2 m( _
is
7 G( R7 p% D# F" p part, GlobalDistObj, assignLObj:object;row,Lan:integer;
4 e! P8 R7 O% ]8 Edo4 N/ B' A! [# @6 _
Lan := rootfolder.Internal.Tools.AOLlanguage;
2 |" x* _4 S7 @7 o* R$ Z if current = @.Destination -- else return
' `4 i( H( O. h2 g' M! Z then
& Y2 A( M e% V* ~" d @.Destination := void;, X# P/ Y6 _- e8 |& t
if @.occupied then. `$ B( V3 C$ Z
part := @.cont;; `' F$ H, w+ ?" Y
@.transpOrder := void;
$ e& z+ N1 k; g4 @% k5 x part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
; b* g$ q1 {" f @,root.eventcontroller.simTime);
1 e! n e1 ~3 @& E3 A @.HasOrder := false;
+ Y5 @1 K1 I# R @.DrivingHome := true;; v& q1 X% S; O: ]' B1 m( L
rgManager.tryToStartTransOrder;
4 u2 F/ i4 N. F1 m* a# Q1 x5 F' b if @.Destination = void3 A$ e. d9 q' m" w8 k
then -- no transport order for vehicle @4 Q, T" V& G5 G1 y7 k7 _, D
@.Destination :=
- W9 ?2 g1 @0 G/ ^ rgManager.nearestFreeStation(@,track.~);9 M7 a5 C- h5 M# \
newDirection(@);
1 x8 Q# b0 c X/ n if @.Destination /= void then
: a1 q* j! ^+ z: d; U2 j+ B @.Destination.NumReservation :=
3 ~/ S( ]( [" d; R+ ?1 S% q @.Destination.NumReservation + 1;
8 j) s/ K' V7 W' x end;# U$ J; t3 P; o
@.CurrIcon := "drivingHome";
! d' L7 S3 _$ d) }( B* ? @.DrivingHome := true;
5 M3 @( K Y$ p; L' u end;1 ?* x9 E) Q2 W% K6 y8 J2 \
else -- the vehicle @ is empty, both vehicle and part are in the same dock station
. @. ?; c& V2 X: R4 H part := @.transpOrder;
+ q+ t! i4 k9 v( u$ f part.move(@);-- load part
; W3 v2 B$ ]3 A" w @.CurrIcon := "load";
/ Z% s! r! K: v) F GlobalDistObj := part.globDestination;, g5 R u" c7 n
assignLObj := rgmanager.rgAssignL;
4 s3 s U/ h' T+ C, E row := assignLObj.getRowNo(GlobalDistObj);" |7 ~. k$ N' b4 [$ M' d7 t
if Row = -1 then -- since 703 |( e: U' x% @* g" {
if lan=1 then
4 h+ s: j' C) i8 E8 @, C% A promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
9 }* J2 Q( s% n, `5 B to_str("in der Andockstation: \"",?.~.name,"\""));; U# \+ q* r7 Z3 U# ]
else
8 Y0 c# r" W" M0 e; g1 U: ] promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),+ _1 ?9 b$ ~ x: \% p, l' D
to_str("in docking station: \"",?.~.name,"\""));
( q9 S, D; a) C+ i' F: {8 Y end;
& |) Y5 n+ ` f else+ ~0 U3 N' d, J7 H
@.Destination := assignLObj[1,row];# U, E: V- R4 q& T4 {- u
end;
+ A' _/ w4 T% r* ~ D5 J5 { newDirection(@);
# M6 B% ^* Q& b9 W- n @.HasOrder := true;
) T8 B- g' L+ A8 i+ A2 M end;2 Q; ^& t: f8 H) [, J
end;* o% i! F/ U+ o
end; -- of the method9 d/ h1 j$ D# {. J6 c8 Y
|