/* called by: entrance ctrl of the object 'track'! G8 v( i" \2 r! X9 X/ i9 X
*/
5 I# b0 w4 G( ?is
$ h( Z! f7 C" P. W1 I/ [ part, GlobalDistObj, assignLObj:object;row,Lan:integer;
# }1 H/ E: z1 A$ _( O Pdo
6 D/ y$ N/ ~. f; Q; ^ Lan := rootfolder.Internal.Tools.AOLlanguage;
# ~% }: A1 v+ e2 o/ U. C; D if current = @.Destination -- else return, i# t4 k. S! l9 {
then; O, `' ~+ W: K- v- q
@.Destination := void;
! J% T) o. ]. X/ W" V( Z if @.occupied then
- R, M& H4 {3 f% V$ u, e part := @.cont;% ^) t' J% i$ D6 U1 h7 `
@.transpOrder := void;5 ^- W4 x+ @" N4 H3 N4 F
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
8 E" s4 J1 K9 {% b3 ~ @,root.eventcontroller.simTime);0 u& C. Q" S! r; H: v. J
@.HasOrder := false;( r5 n) {" t% k, l, j' h- b
@.DrivingHome := true;
! m, X4 w/ Q( ?6 I7 ^3 Z) a% G0 W rgManager.tryToStartTransOrder;; C/ a5 s1 M$ |( P9 r; K# X' R0 G/ h' \ s
if @.Destination = void- v9 T- O) T G m
then -- no transport order for vehicle @# S- t. d4 B" @
@.Destination :=
j: V7 G6 ~3 o Q6 _6 U- R rgManager.nearestFreeStation(@,track.~);' A5 k$ }8 [* t% O Y% V3 t& I
newDirection(@);
, i# b2 i: v. a- |9 H j: ^ if @.Destination /= void then u- l6 C& j+ { T9 D/ y; n
@.Destination.NumReservation :=
1 e" S# v, p' ~; _" `) M @.Destination.NumReservation + 1;
7 C0 t9 O9 \* ?7 H5 D end;
! c% F. Y: H# |1 H" z @.CurrIcon := "drivingHome";
" M7 b6 \7 Q' Z @.DrivingHome := true;# z8 w8 y c. z9 Z3 t% U o
end;9 s1 h' o& o" I# ?
else -- the vehicle @ is empty, both vehicle and part are in the same dock station
: [: m9 _% g4 W, C; j part := @.transpOrder;2 y9 F7 g( |3 m- S: r" R( e
part.move(@);-- load part- F( B9 J H0 S" _- V& ?( S9 l
@.CurrIcon := "load";
5 w. Q2 a. D& H& R" M GlobalDistObj := part.globDestination;8 j' f2 a/ ]% _6 s" K
assignLObj := rgmanager.rgAssignL;
1 j" w, H$ Y1 V6 ?/ |" ~ row := assignLObj.getRowNo(GlobalDistObj);+ X' h% [. E- E& }" [
if Row = -1 then -- since 70
m3 ^# v! u$ z8 A1 x( r7 |8 M I8 A" H if lan=1 then& ~4 E. Q/ a( z4 J7 ?# j
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
: E. b. j, J0 G8 n' l% I! k to_str("in der Andockstation: \"",?.~.name,"\""));
' p% X4 d, @" g( G, I else
4 ]$ g5 U/ o2 K; ?. _! C( i& J promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),% O3 d. b! {8 b2 j- Y1 ^" p9 \9 X# K) ^ z
to_str("in docking station: \"",?.~.name,"\"")); 2 Z6 h7 D, T* B0 U/ N y
end;, F6 B: w1 {3 G/ x
else
$ j& m/ D0 n8 q0 `8 x, k8 p @.Destination := assignLObj[1,row];3 M& X2 g- ?$ D/ x) }& U' g
end;
5 u4 {) b1 ], Z& o3 Y' c newDirection(@);- W% p; D' \* c4 _
@.HasOrder := true;$ b# P2 W7 P0 U$ N b
end;/ I( ~/ x3 B1 p1 p; F2 j$ `
end;
# q% B7 j$ J, x9 v7 ~end; -- of the method
5 d' Y: ]- @" t |