/* called by: entrance ctrl of the object 'track'
+ S- y+ ?9 Y4 j* L( a8 g- H*/6 g) v. S8 b- O |
is
5 o* U+ y( W7 ` part, GlobalDistObj, assignLObj:object;row,Lan:integer; K4 w0 _. _" \
do! {+ c( g: W6 `4 E. ^2 D
Lan := rootfolder.Internal.Tools.AOLlanguage;9 N, @6 F* j9 l, i$ z, X
if current = @.Destination -- else return
0 I) k1 U b5 O- P& _- @" { then G+ h5 u3 i0 q0 s9 F
@.Destination := void;
6 U9 W) @; r+ A if @.occupied then, L2 |. P- c/ w# f
part := @.cont;. U; B2 d$ o+ y/ M4 y/ x' G
@.transpOrder := void;
0 l+ B1 v% K; t1 T/ _% Q* V. V part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
8 h9 {* ~$ l; _3 N$ s @,root.eventcontroller.simTime);0 T- R2 R: M' }. j! y
@.HasOrder := false;
7 p! A# O- g; ?6 k4 `1 Q& S c @.DrivingHome := true;
3 `- u ~. I9 n5 b( _* U! ^% B rgManager.tryToStartTransOrder;
3 I, P! u7 w8 ]1 I+ j, _ if @.Destination = void6 n% t9 U/ v& |6 o0 u T% {# j
then -- no transport order for vehicle @
+ d/ B; U- c# ?" x2 g# P @.Destination :=
# _# R% p. ^% ~ rgManager.nearestFreeStation(@,track.~);
0 b! C) N, P/ v# }5 G9 ^& e" i newDirection(@);
" Y' t! g' I# p if @.Destination /= void then
+ a& i; l5 K! V @.Destination.NumReservation :=$ K; T1 ~% ^& K0 j% |( Z
@.Destination.NumReservation + 1;
; K' i" E$ g' J v# }6 i ] F end;
6 P" [" l, j7 G7 Y% f+ }/ ` @.CurrIcon := "drivingHome";" L; Z3 X0 y* t
@.DrivingHome := true;
) D7 Q3 s, j# ?2 t( M& x/ X end;( M+ w! O/ `) P5 E3 N
else -- the vehicle @ is empty, both vehicle and part are in the same dock station
# S' _# z! A+ p1 s* D# D8 X part := @.transpOrder;
( [3 H4 P! b- ?, b$ j4 Q part.move(@);-- load part
$ a9 V' O3 N) {8 w" i @.CurrIcon := "load";
9 a2 q7 C' I: a# y/ m6 f# M GlobalDistObj := part.globDestination;
" c/ w$ u# o& G) X' `! U$ q: p assignLObj := rgmanager.rgAssignL;' D" f2 y7 x" R! _. t& J
row := assignLObj.getRowNo(GlobalDistObj);# ^, f/ i7 A# {
if Row = -1 then -- since 709 [3 H( v# Z" b3 ~. V% H. R) P
if lan=1 then3 c/ }3 S0 o0 z# R! I
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\"")," Z3 Y& D/ O% [& k( w
to_str("in der Andockstation: \"",?.~.name,"\""));$ L3 m, \: O, ?, h/ V
else
, @( h3 c5 P( g promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
% X8 n" C, o9 T+ D) a p% J0 i9 s, i to_str("in docking station: \"",?.~.name,"\""));
) K. R# g" F1 I4 U* o end;* `9 V. |5 F' h
else
& ^$ V( e5 G) k" z* C2 ^ @.Destination := assignLObj[1,row];9 b6 J, M* D4 C/ T
end; ( C8 M( f' q$ S. ?$ k y9 ?$ P* m
newDirection(@);3 Z* H* \ o4 |. D. H. a9 ~
@.HasOrder := true;9 p9 p7 r' x9 `" s6 x
end; _' C# [* k; r$ R* \, n
end;
/ e9 e- y8 ~5 x8 Cend; -- of the method/ _4 O* s/ |. d3 Z: X4 K5 p" _
|