/* called by: entrance ctrl of the object 'track'6 \$ r. t+ `# ? {4 S
*/$ D, \* v% r' b% H* R; {0 Q
is
. l/ d" w' s" r part, GlobalDistObj, assignLObj:object;row,Lan:integer;2 g+ n6 N1 I. U- g5 |
do
/ A$ @3 \) J- x& p+ }' M Lan := rootfolder.Internal.Tools.AOLlanguage;
6 H8 V3 R* u' h% }) D2 ^4 x. O if current = @.Destination -- else return0 i! N6 H: Q$ C9 t
then
+ @' E- c" f" J* L. h P# W @.Destination := void;
$ t5 l0 Q0 ^1 h- [ if @.occupied then/ H0 h# r& N) k' _5 B! p
part := @.cont;/ B& y1 o y# f/ V* e1 u
@.transpOrder := void;
0 L- U1 o" X$ c( n: i' o part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,$ o- Q5 T9 N3 Q/ v
@,root.eventcontroller.simTime);
7 M7 y1 O: X) t8 f/ u @.HasOrder := false;6 E' f5 C# Q9 e$ V, M* v/ S
@.DrivingHome := true;
/ o# j X: g; S- V7 V& |8 q* @ rgManager.tryToStartTransOrder;
0 P7 h# O2 l( h7 A0 [ if @.Destination = void+ I% J! U! j z6 X& s
then -- no transport order for vehicle @0 N0 X% m; i2 I& u2 n1 f
@.Destination :=
/ w7 v) l+ S3 m9 [+ K, e q1 S rgManager.nearestFreeStation(@,track.~);
" p( z8 y7 T3 r- ?% E8 E newDirection(@); ; a) I* Y5 i: E! a
if @.Destination /= void then
- L1 C* @0 J# V% r9 p, { @.Destination.NumReservation :=5 b3 x7 E" w. t$ Q
@.Destination.NumReservation + 1;
/ R5 @1 |0 D# Z' j U* h end;
/ m- T7 `7 q" R2 }/ T/ ?% J7 \ @.CurrIcon := "drivingHome";) E9 ^' n' d7 m& I( B
@.DrivingHome := true;2 B4 r$ y! a) y% c
end;* K: L9 Z0 t: x N8 V; u. K1 x
else -- the vehicle @ is empty, both vehicle and part are in the same dock station
# B! H9 s8 j! H3 s+ v' h4 q part := @.transpOrder;& }4 o5 Z# F! d: i" c% s) k
part.move(@);-- load part
4 |% \/ l# W0 z# T1 q @.CurrIcon := "load";# p! E K6 o0 H
GlobalDistObj := part.globDestination;+ @, }4 r0 g0 ~& C) f
assignLObj := rgmanager.rgAssignL;7 f9 g8 D4 L; h( V! o4 ]: ~% Q$ a
row := assignLObj.getRowNo(GlobalDistObj);
& N0 |/ H+ D/ I4 e if Row = -1 then -- since 70
# [: D) Z" u- H; H* f2 U4 N if lan=1 then8 R) `8 d# n( N& J
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),: i1 V o- m) s3 v
to_str("in der Andockstation: \"",?.~.name,"\""));5 |) n- a! ~5 N9 J$ G. J
else
$ [( A o/ G, R# U' V promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),! S V1 s3 C; |. W$ S( Z
to_str("in docking station: \"",?.~.name,"\"")); " M% ~2 S/ m- d) N$ A K; U
end;4 p! k8 T4 U4 H8 l
else; e- v. U5 @0 L* R' {% u
@.Destination := assignLObj[1,row];
/ ~- q q0 L! |/ |) t. i end; 9 t0 Q* @/ `5 W. p2 h! S0 N
newDirection(@);, _) o) {5 ]$ U1 O2 P4 D
@.HasOrder := true;
5 f7 u3 ]: T# H- d* j6 h- \- l% r/ u end;
0 y+ P% X# p, J end;
; J+ b3 E6 c: h7 tend; -- of the method
, M$ h) u! \& ?0 H: U: s |