/* called by: entrance ctrl of the object 'track'
; ?0 K6 t, ?) R" \*/: {, t# |2 T2 [# p+ B" S5 g/ w
is* A1 f0 @0 a; l" R3 a
part, GlobalDistObj, assignLObj:object;row,Lan:integer;
0 G' O% R' |9 E% H9 p/ ndo. C6 `6 p9 l# `& E
Lan := rootfolder.Internal.Tools.AOLlanguage;
: e% ^' o' Y# f7 t' F if current = @.Destination -- else return4 D# F- G3 A5 O9 K% T' a
then9 w! i1 C$ u# I) x7 s1 f9 x& Z
@.Destination := void;
! H/ X. G' U( Y6 J' g if @.occupied then. o( A/ f: D* J% @
part := @.cont;( g$ y+ M* J; f! g* U
@.transpOrder := void; H. ^6 h9 C) H8 W4 v- j/ v/ |
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
- k. R: s+ |" s @,root.eventcontroller.simTime);
( E- t) u: y9 M0 k4 p# E @.HasOrder := false;! C* u; U! P8 P# Y0 M1 s( p
@.DrivingHome := true;( c4 _ A Z. Q/ A
rgManager.tryToStartTransOrder;
: S; k$ N x+ y9 Z* Z. C if @.Destination = void
$ z+ L c( M/ K$ u then -- no transport order for vehicle @( W/ P. R# D1 R* [
@.Destination :=, P( e& v1 _ P9 A
rgManager.nearestFreeStation(@,track.~);4 r# @- `4 m6 W/ ^
newDirection(@);
^, N/ C# s$ u6 v; | if @.Destination /= void then- H- n" Z8 L7 G) S4 M
@.Destination.NumReservation :=
" U- F) c# _6 t1 [3 g k# M @.Destination.NumReservation + 1;+ I; L8 f& T2 }' S' f
end;, M' d& d+ Y" _
@.CurrIcon := "drivingHome";- c2 f0 z; z! C2 ?4 P/ e b$ E( L
@.DrivingHome := true;$ e% i6 f! }2 x1 E1 Z6 X
end;
. u, K: N2 B `, m H else -- the vehicle @ is empty, both vehicle and part are in the same dock station- r0 R w: ^/ f) @ U, {+ r- y
part := @.transpOrder;
! r! S3 r+ J5 s. W# O part.move(@);-- load part7 x2 f9 S$ f0 F N: j# D9 B+ O
@.CurrIcon := "load";
; R+ I' p" [1 J2 o( w# M X GlobalDistObj := part.globDestination;
+ Y2 r# ?1 f$ i( e! | assignLObj := rgmanager.rgAssignL;( w* v! q8 W7 ?/ |9 e( ?
row := assignLObj.getRowNo(GlobalDistObj);
2 V) H% b3 I: m! K) U: e if Row = -1 then -- since 70
7 h3 \$ s* w* X0 J+ D; Q if lan=1 then
& A1 S' r, U. K promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
" \ s: s; w- H) R to_str("in der Andockstation: \"",?.~.name,"\""));3 i( {6 x5 ~' W" n' s7 Z
else
5 F' M8 r4 J2 u) u+ Q: v promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),+ h5 j* u) z4 F# }. |' d1 P
to_str("in docking station: \"",?.~.name,"\""));
( h. c, `, N; S# T. h b! X end;5 g' j+ q1 E4 \. x& ]
else7 k8 x0 X/ Q& q# e
@.Destination := assignLObj[1,row];3 X" l0 V& s, I. z4 u" M
end; 9 e2 C1 E# j* ], J) m( W9 E
newDirection(@);6 T1 i5 m6 y9 g l( Z3 l2 |/ X
@.HasOrder := true;
: r$ Y' T2 U [6 U$ m5 @6 c, T+ | end;5 j6 ~/ ^* Z4 {* { C/ B
end;
" M' J4 N) P3 P% `# nend; -- of the method3 ~5 T& _; s' `% j( g" [7 N
|