/* called by: entrance ctrl of the object 'track'
7 u" H* ~- |: b/ U0 w*/
2 e2 M# O% ?$ k0 E |, ?- eis
, i# f. f( m/ j! V2 R part, GlobalDistObj, assignLObj:object;row,Lan:integer;
& c+ b5 s7 N. }7 _do
2 ?0 {, \# O Z% Z Lan := rootfolder.Internal.Tools.AOLlanguage;
5 B4 n) \. R8 g2 q7 C% [ F if current = @.Destination -- else return0 d/ {5 i8 y: h9 ]+ [5 O: @2 E7 w
then
; [" V; l. [, m* I; s @.Destination := void;
1 z) r7 q0 L- S8 Q if @.occupied then, b; G3 f5 V- Q g: _& R9 E
part := @.cont;6 Q7 d8 c" e' }! e+ W* J7 t
@.transpOrder := void;
% r; y0 h' t, `5 J8 a& |* x# j part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
6 O0 ^1 m' _4 |6 g& Y @,root.eventcontroller.simTime);' L# t8 R6 C: |9 P5 O3 C( c
@.HasOrder := false;
* C% Q- X# S2 R: u5 P @.DrivingHome := true;3 K( q: f% W- `6 E
rgManager.tryToStartTransOrder;- F) _: ?+ z# P2 K+ }8 E4 B% J: D
if @.Destination = void8 J; y8 v- ~) q% Y1 c
then -- no transport order for vehicle @
; R) ?+ w) f Y5 i. ] @.Destination :=
5 c2 k/ `- x3 X9 W, s rgManager.nearestFreeStation(@,track.~);% G/ m' e$ r S- x) \8 J
newDirection(@);
0 m# w) j9 K3 g4 w if @.Destination /= void then; ^9 d! L5 \5 |7 j
@.Destination.NumReservation :=
; X! H9 u; n1 S" j @.Destination.NumReservation + 1;
$ U t4 K& x# @6 A$ ` end; ]) c H4 b4 [5 Y' A( N- l
@.CurrIcon := "drivingHome";
7 H2 @" x; L$ J- Q @.DrivingHome := true;, Q- B' o3 L8 M
end;8 {4 J3 v9 a5 Y& c
else -- the vehicle @ is empty, both vehicle and part are in the same dock station7 d% b( R& e- p
part := @.transpOrder;0 R1 W* V% ^ g( c2 F, b! P
part.move(@);-- load part/ f' e) Q: z- L, _( n# [
@.CurrIcon := "load";* c' v. H- n8 x( V) Z# s
GlobalDistObj := part.globDestination;
6 q3 W# t+ Z2 c) W1 p assignLObj := rgmanager.rgAssignL;
) f: i- E3 h8 E- W+ c8 a row := assignLObj.getRowNo(GlobalDistObj);
3 ] l: _( s' r if Row = -1 then -- since 708 O. Q0 f# l2 x2 B* H
if lan=1 then; A. S6 O+ S5 k/ Q7 \! Z; b; S& [
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
! w& p' p8 D( r& T to_str("in der Andockstation: \"",?.~.name,"\""));$ I2 D* |/ s, S# G
else, b2 R, [% E' C" Z. r, C) w' f
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),0 w# l g+ Z9 D5 ]+ {6 n8 P
to_str("in docking station: \"",?.~.name,"\"")); " q- ~& Q0 q/ \% R k* l
end;% M' C+ c! c3 h- ^& J6 f
else
4 z* f H. S4 d7 T6 L5 F: M @.Destination := assignLObj[1,row];& v' H, {# Q% L/ Q) [, d
end;
" t5 g% N3 W. A2 ? newDirection(@);& `3 J% u1 y5 c: C, S/ e
@.HasOrder := true;1 V( H# H' X% p9 ~
end;5 H1 F. C! l& J0 o# l
end;
# J+ f8 c u1 j) n( p0 }end; -- of the method; m' M! z/ }' p1 M6 G3 |
|