/* called by: entrance ctrl of the object 'track'5 |0 [. y; t' T p
*/+ ^6 \; x; t9 X9 w, i
is
9 I. Y1 z& `# I0 z part, GlobalDistObj, assignLObj:object;row,Lan:integer;
4 o' x# b# l- s7 G) \do% m/ x! D# ?* R9 L2 h
Lan := rootfolder.Internal.Tools.AOLlanguage;
8 b7 x3 S& c+ l" _1 o1 }$ A" h* K' M if current = @.Destination -- else return
0 e+ u( b$ `' c) l+ P/ }, b2 P then p) } V" |* R& t
@.Destination := void;
, m: D _. p6 m, v; \ if @.occupied then3 w6 M* s; ?) {! Y" D
part := @.cont;
: U K- h$ n7 h5 ? @.transpOrder := void;
5 T" f5 U, L. u' b part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
3 t" g& E8 W( E# `5 ]' s @,root.eventcontroller.simTime);( Z( o7 v9 }1 p2 A5 A6 J
@.HasOrder := false;) A: i" K: ] }- D! [
@.DrivingHome := true;2 |; v0 D( x8 A7 \2 h$ t6 `$ S
rgManager.tryToStartTransOrder;# f3 h) |8 N3 V0 g5 M* s! {1 G
if @.Destination = void
0 R. _6 P; E6 j% a# s then -- no transport order for vehicle @- ?+ z: R) a8 J% @9 k6 ~& }: `3 p% _
@.Destination :=
^# C" F' F1 _ l6 _ rgManager.nearestFreeStation(@,track.~);& s0 v( v+ @' {1 x4 G. L. [
newDirection(@);
6 e; b' \% X& f" p- i# i2 L if @.Destination /= void then" J) T6 ^* F9 G; c6 h
@.Destination.NumReservation :=: M/ d9 Y, i. j. P, K: B4 t3 C
@.Destination.NumReservation + 1;0 k+ v1 S& K6 ?5 ]
end;( n1 z8 S3 t6 w' L. }8 v, c
@.CurrIcon := "drivingHome";8 J5 |4 R" k6 p
@.DrivingHome := true;7 c( S/ K' i+ u& r8 m
end;
: [ _% E( [) ?& g$ D; e else -- the vehicle @ is empty, both vehicle and part are in the same dock station
6 }& H4 p5 h; j) u; ^. i. Z part := @.transpOrder;8 [$ J) v8 L: d
part.move(@);-- load part1 @' U. `, d0 f+ J: j# x
@.CurrIcon := "load";
8 y1 A1 [6 ~1 i% F4 s- s GlobalDistObj := part.globDestination;
7 L9 p9 b7 G" L G assignLObj := rgmanager.rgAssignL;2 [$ I; a, O4 V4 ?+ @: [# ~
row := assignLObj.getRowNo(GlobalDistObj);
! J; L& ?3 u, G4 a7 S if Row = -1 then -- since 704 M" ?; V% \! } Z% ]7 A9 e
if lan=1 then/ ] ~, n3 O3 y0 M% O) P
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
2 t1 ?8 N1 |( {- j& T to_str("in der Andockstation: \"",?.~.name,"\""));* w. k& a; d( S: I {
else
+ @7 r r( ~8 F: t, O promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
9 X0 X9 m t- P6 S to_str("in docking station: \"",?.~.name,"\"")); 0 B- ?6 \+ O4 R4 s6 O5 Q4 g& u
end;2 ?7 w- `, h& w; X% b
else
) E" f7 n! ?$ h: n" F( p @.Destination := assignLObj[1,row];# Y1 U* d4 H1 w& q" [' c* g Z
end; 0 W1 C3 M& z' Y. |% T; a
newDirection(@);4 `( y1 F/ T: w* [$ ~# ?( ^5 u
@.HasOrder := true;& z5 L3 V) r _
end;
z6 B1 m/ F# e2 ~5 ~6 }4 g end;
3 }6 y- J: \2 a; aend; -- of the method
" ^8 A: P8 ]3 ?9 \6 a |