/* called by: entrance ctrl of the object 'track', }+ G4 S; Y/ n
*/
$ S/ O0 G8 ^2 {: b0 l; k6 {is
8 A8 ?& X( x T! N7 s6 { part, GlobalDistObj, assignLObj:object;row,Lan:integer;' L2 r' f" C% s) n- \1 T6 Y
do
3 b+ j. d9 G2 c" K+ Q. Z8 z Lan := rootfolder.Internal.Tools.AOLlanguage;
9 N6 o9 }0 t- }1 ~/ u if current = @.Destination -- else return/ d* [( e8 Z$ ?
then7 L! J+ t" h. e! K( f+ F' L1 P7 ?
@.Destination := void;0 |" n+ U* j& A0 y( r
if @.occupied then
+ {- N+ n* r& U1 _$ R" ~3 C part := @.cont;; i% i8 G( V; d/ R! Q( |
@.transpOrder := void;
5 M3 h b' e/ c9 N A/ O1 e part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,- ^9 J4 j) O6 y. y- w; E1 p$ _2 u
@,root.eventcontroller.simTime);
4 S0 {4 u1 |2 Q% q* M( B) [ @.HasOrder := false;3 {) W+ c5 b% M; N
@.DrivingHome := true;
! N0 d) t ]6 u- N: W7 V rgManager.tryToStartTransOrder;
6 }) D$ r& e# l, ]- b if @.Destination = void
5 Y3 x5 n+ B3 u" O& Z- U then -- no transport order for vehicle @$ Z% E$ |7 s" V
@.Destination :=* }# [8 b! V2 \# \0 c. ]
rgManager.nearestFreeStation(@,track.~);: g6 M p. L& I) W& f
newDirection(@); , g0 Z; C* r) ]2 ]8 j4 d+ r' A$ _$ R
if @.Destination /= void then6 B5 _9 N" v$ q3 Y
@.Destination.NumReservation :=
0 s+ [; w+ w; g& Q @.Destination.NumReservation + 1;; W/ Z( k2 I8 U4 B% C. l% v8 X
end;
M" P% ?! Q$ M# U, i. c+ |' `' x# O+ X @.CurrIcon := "drivingHome";
, t) V5 ^3 f! v" [ @.DrivingHome := true;4 U; \. m4 U; g$ o. m
end;
# j, K% L# N+ F( e else -- the vehicle @ is empty, both vehicle and part are in the same dock station
) }3 e. B: l- f7 {$ M part := @.transpOrder;
/ X- ]. U4 k! {# O part.move(@);-- load part/ t2 K$ ~1 ]4 j2 [8 _8 j+ [
@.CurrIcon := "load";3 k. d+ a2 b. x& A
GlobalDistObj := part.globDestination;
# Z4 c5 u, n- G( P assignLObj := rgmanager.rgAssignL;
# e& A+ `' [4 |: O4 g* {' J* n row := assignLObj.getRowNo(GlobalDistObj);
+ s/ m& ^" ^- D3 S/ s" W5 X if Row = -1 then -- since 70 S L9 r/ y& f/ I
if lan=1 then0 g- q0 x! `2 H% z) q M
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
1 s% ]/ W$ Q) M a u. Q to_str("in der Andockstation: \"",?.~.name,"\""));
# E9 W1 ~- r# E* `/ \ else$ h8 }) {6 ~# s0 S( B
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
( B% E. _7 t4 g3 Q4 q1 H& |% f0 U to_str("in docking station: \"",?.~.name,"\"")); 9 E6 {* d5 M6 g4 a2 O
end;4 R0 d. s8 K. M5 `0 [" }0 M
else
2 Z* L7 y9 A, P* S @.Destination := assignLObj[1,row];: F7 L( d) D1 z" h9 _2 [/ Y
end;
2 c6 M4 V3 w! q6 `/ i" O C" } newDirection(@);
6 J' h- f4 a4 Q7 |. v @.HasOrder := true;5 ]7 o2 ~$ R- p' l+ R& `4 T
end;1 n# {; ?5 C3 n% F* J+ ]* {) ?
end;, T @ K! U5 Y1 Z' J% M
end; -- of the method, m# F# ^6 i u1 ^" V. l% Z
|