/* called by: entrance ctrl of the object 'track'2 F* w S0 S+ F$ T+ G* e4 B
*/+ @3 o: Q, E" N8 X( u2 O
is' k$ R* T, R9 c" P% q. q
part, GlobalDistObj, assignLObj:object;row,Lan:integer;
8 Z& @% P6 q: u4 q. N0 }do
3 S( a, A/ [ \ Lan := rootfolder.Internal.Tools.AOLlanguage;
& u5 M. C5 E) [: t* X u, D/ G1 w if current = @.Destination -- else return+ L& g( N; R8 V; u; X; U
then
: [( x o7 }9 r3 e$ `8 o4 K @.Destination := void;( C7 ]9 d+ U& g3 r4 d
if @.occupied then
# ?/ K- N/ e- ~+ h( G part := @.cont;, t+ U/ J! K7 u( n/ _
@.transpOrder := void;
% O- v, f7 ]. c7 p part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,' N/ W" Q2 i9 k0 F$ c" |
@,root.eventcontroller.simTime);
; p1 d3 \* H3 U% y" N; F @.HasOrder := false;
w9 B2 M# S. ?8 A7 b @.DrivingHome := true;$ A! X/ X# i$ D5 D- p
rgManager.tryToStartTransOrder;) r" g5 R( X# ~+ }- p
if @.Destination = void, G. y2 h5 \+ ~; ?3 ?) u
then -- no transport order for vehicle @
# _1 C( B* h( ] @.Destination :=
1 W/ f2 u& _0 f9 m rgManager.nearestFreeStation(@,track.~);
9 f2 c& D0 r0 J: G) l newDirection(@); + e* T: q' T9 `
if @.Destination /= void then
+ V( U/ {8 ]: I, B g. p @.Destination.NumReservation :=
8 F* S2 _$ _+ `1 W1 G* @! M7 v- \: v: T @.Destination.NumReservation + 1;3 g( L7 [$ W* }5 p# b: W
end;
) ^, g, x, e& a; ?+ g @.CurrIcon := "drivingHome";5 L4 J/ L8 N- y i* ]: J# w
@.DrivingHome := true;
4 h, _: x' k3 z/ ~- C+ ^ end;( m/ C% J F; @% ?" k/ P2 m2 N/ i0 l
else -- the vehicle @ is empty, both vehicle and part are in the same dock station
3 H! \( F: i& l! M3 _ part := @.transpOrder;, Z; t, n- e4 ?0 v5 q* H
part.move(@);-- load part
3 W. g8 ?4 o9 K | @.CurrIcon := "load";9 t3 F- p) p% o, ^6 Q
GlobalDistObj := part.globDestination;
- _( S7 ~) d+ y2 Y assignLObj := rgmanager.rgAssignL;, l! x6 K. U. X h0 s2 ~. v
row := assignLObj.getRowNo(GlobalDistObj);
8 b, x, u- ~& v8 K: ]* ~ if Row = -1 then -- since 70
: h0 o) ` z* n5 _+ a+ Z if lan=1 then
9 e) P5 p( U$ t2 s* [0 r) Y2 z promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),# V! n+ l. r3 Y) l1 j
to_str("in der Andockstation: \"",?.~.name,"\""));
4 c& r% U& o2 d: w else, Z! g" g( R* |8 q: y
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
) ~6 l- P8 z) D* H' T to_str("in docking station: \"",?.~.name,"\""));
$ Z. N3 D; P/ B3 u$ N end;
1 \2 u9 f, r. W @ else
. y& S( h8 W* \0 x7 V# m @.Destination := assignLObj[1,row];
& ^4 |+ G K& @ end; 2 O' R5 ]7 l6 p* a7 O4 B: J% {
newDirection(@);1 {: |: f6 @5 q* i! Y2 ^
@.HasOrder := true;1 z H) f' U. M4 u; [
end;. r" j: L/ I! P9 g' `: r- f
end;0 H5 P+ f0 y2 H+ w
end; -- of the method* {, _' v2 V/ N7 d T' N
|