/* called by: entrance ctrl of the object 'track'- v- f, ~0 m4 {, B
*/) L. |2 u) o- b* ?: R, o/ i1 _
is! k k# O" r$ c( [
part, GlobalDistObj, assignLObj:object;row,Lan:integer;
; X" j4 b+ `' o8 J3 z2 _3 v* A6 sdo$ j$ B. A9 J8 L, W: s
Lan := rootfolder.Internal.Tools.AOLlanguage;
- n$ z" [/ y' |2 F if current = @.Destination -- else return
' A" W3 ] @$ S# n u. H! ?) }8 }( S3 | then4 R1 U0 Y3 Q- I3 ^; u" K
@.Destination := void;) N- \5 S! b# d
if @.occupied then- U( b* S+ w! T! @; ?! @9 Q' U
part := @.cont;
~9 I) Q7 Y) q @.transpOrder := void;+ i9 x9 c* H Z% I" p3 e
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,3 R1 ~& Z5 h# T% P' a& H
@,root.eventcontroller.simTime);
, p( K1 O" }) ^) i8 n @.HasOrder := false;: n' \9 g* k" R6 ?2 }8 i3 a; z
@.DrivingHome := true;, p4 z& u% @) U0 F! J c* C4 x
rgManager.tryToStartTransOrder;% T3 C5 f" L( ^+ t5 ]( N. y/ f0 z
if @.Destination = void
* I, ?4 r. B/ }* [" A. V then -- no transport order for vehicle @
6 b0 P# z9 {) R5 Z0 @, e @.Destination :=8 ^& h% D" N, `" k& A
rgManager.nearestFreeStation(@,track.~);" A: y8 l- {! R
newDirection(@); 0 Y9 o4 q0 z' ~2 l0 m# ?, I/ C
if @.Destination /= void then# `! Y, k5 ~$ S- P; @; [ c
@.Destination.NumReservation :=
6 [6 S2 \# I1 T% e4 A- ^- U5 z @.Destination.NumReservation + 1;
6 ~& H/ p: x( i* ?' ]! N end;: X# q4 D- m. T4 t3 n) ]
@.CurrIcon := "drivingHome";
0 R2 }9 s d; O( v+ o. | @.DrivingHome := true;! O/ N) N) Y! w9 G% @/ T( q9 r
end;
7 I. M' _7 o; e/ n2 @ else -- the vehicle @ is empty, both vehicle and part are in the same dock station0 l9 E5 o3 G. Q2 Q& i
part := @.transpOrder;( g9 I5 Z% r( d$ P4 f
part.move(@);-- load part- n- @, H8 X7 ^ ], n3 m& Z
@.CurrIcon := "load";
A& y1 D! ~( o% r% v GlobalDistObj := part.globDestination;- ~2 b5 F ^2 `% l
assignLObj := rgmanager.rgAssignL;6 N( Y2 k+ P% D. W
row := assignLObj.getRowNo(GlobalDistObj);, d# H2 [% k) C( A
if Row = -1 then -- since 70
8 `4 Y9 j; R, U6 v, { if lan=1 then) d- e% N% r3 u4 h8 d z L
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),$ h# H1 m2 O b# @' S5 F
to_str("in der Andockstation: \"",?.~.name,"\""));# U& y A! c, {" U" |% Z0 |
else
6 M/ G. u y7 \ promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),5 r% v; `1 E* m- W6 P6 u/ S- f' i$ I- t
to_str("in docking station: \"",?.~.name,"\"")); 6 F7 l) A5 _8 ?1 t' v- F
end;" V. E8 Q9 v% a9 l6 L( M
else
) r) Q( {1 D) y4 e @.Destination := assignLObj[1,row];
9 |9 a- e9 W$ W: Z end; ; j, L* \# w# t$ c3 L# u
newDirection(@);# Q+ p' X7 z" u- R* X) T5 Z
@.HasOrder := true;
% {4 p5 W3 o; f6 l2 W$ y' r end;# s# [2 {* v/ d2 d+ x# j
end;
7 _4 p2 H3 Q' e: [) C r8 zend; -- of the method x& ]" _# K6 A- q$ T, A4 I8 I; K
|