/* called by: entrance ctrl of the object 'track'
! q# a9 c4 p9 m3 Y/ }5 ^( i*/
7 {$ W' T9 q3 X: @ o0 X zis
) W" s# q. L# L part, GlobalDistObj, assignLObj:object;row,Lan:integer;
* I0 B5 z, F7 P$ Q6 {6 A" E! R+ edo
* [3 [) Z3 O# L! ^( r# p9 D( K Lan := rootfolder.Internal.Tools.AOLlanguage;
^& f' C/ I9 v; U if current = @.Destination -- else return
7 \6 ^0 C1 J1 a2 o/ q8 y then- c# T7 S1 c( V; K
@.Destination := void;
% _. x+ w# Q6 ]0 h. _1 L if @.occupied then3 `4 E4 @( a6 N+ i6 W) G+ A# E
part := @.cont;
+ Y4 k5 A) r5 c! Y; Y @.transpOrder := void;( F& f7 E( I* x9 p
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
, Q" q- y/ t) @; @( V @,root.eventcontroller.simTime);
- [/ T l5 z R( P @.HasOrder := false;
# T f& x* ~* m% ?3 ^3 V @.DrivingHome := true;
6 M5 }" @! D( T) i. ^6 l8 d, X% d- f rgManager.tryToStartTransOrder;
# c1 V4 \9 K/ f$ f# M8 U if @.Destination = void
) G Y# d# z6 H) [$ F Q. t& Q then -- no transport order for vehicle @! {3 U* m; n. s6 w- T7 _
@.Destination :=/ e G7 ?$ N* ?3 G1 ^
rgManager.nearestFreeStation(@,track.~);; J1 Q# L) A" f& X
newDirection(@);
; w8 |% Q6 z# c; L% i% ^ if @.Destination /= void then0 r+ u1 i2 p: M& r
@.Destination.NumReservation :=
" x) o% G( ^8 ]8 \: M) w- m2 d @.Destination.NumReservation + 1;
8 P* w2 M7 B: o' x5 U" _) p end;3 W# }$ j% H# ^
@.CurrIcon := "drivingHome";0 M* x: G6 F0 |
@.DrivingHome := true;4 Q5 |8 E1 P/ L3 h% S5 d1 |
end;
0 Z' R! g6 ^5 |" y' `- }- q* q( o else -- the vehicle @ is empty, both vehicle and part are in the same dock station( J9 g7 U7 q$ D) s# z; u" y
part := @.transpOrder;
1 U4 l# j5 b2 b) G3 f part.move(@);-- load part! _9 O( ~* |3 a- T' A
@.CurrIcon := "load";
! d8 G2 |/ K4 c* r6 E; n GlobalDistObj := part.globDestination;" F( I) ^4 S2 {- V0 t1 }
assignLObj := rgmanager.rgAssignL;
' p( T3 e( x5 a4 Z row := assignLObj.getRowNo(GlobalDistObj);
$ m+ s" C! W ~0 ]! L if Row = -1 then -- since 70! p7 |% o, U, N
if lan=1 then
- r) k5 @ q t: W: K" G promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),3 L5 u6 i; B4 r5 f4 {$ \
to_str("in der Andockstation: \"",?.~.name,"\""));
. ~/ B5 A, d: X' @0 S/ n else
0 ? H2 F: u6 h5 r, ]- A* @ promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
" F9 ]7 s* H+ X# F to_str("in docking station: \"",?.~.name,"\"")); ! r; ^' I+ {/ o" H
end;" S: C5 I+ y8 q7 \5 @' C# o' A
else* I6 g# o7 h# ]$ l% [& }: H
@.Destination := assignLObj[1,row];8 O' U/ f5 T3 g$ R8 S
end; % E. {& d, V7 H$ Q' t3 j) v
newDirection(@);# j, {; I* s. h u) |* W
@.HasOrder := true;
C0 p) b3 a0 ^# D: M! J end;. i- u2 ?5 C7 n; Z6 I3 `
end;
3 `, ]! b$ }8 b z- [end; -- of the method
2 z7 ^8 G2 g5 t% g; f5 J9 i: h |