/* called by: entrance ctrl of the object 'track'
/ v- a _! Q9 X*/
' b* N6 O6 G# c5 ^2 z0 Cis$ n9 B) B- k0 }1 w% o1 g
part, GlobalDistObj, assignLObj:object;row,Lan:integer;
5 ~! o6 O2 N- E# {do
* m! V* }: D, q* g& A6 _1 k Lan := rootfolder.Internal.Tools.AOLlanguage;
8 H& U: X4 k5 \9 X# O if current = @.Destination -- else return
6 S7 K: c+ o1 x! |' @7 b then; e1 P; D8 \% I) Q
@.Destination := void;
6 R" F u* I2 A) x; B& W if @.occupied then0 w$ n8 D' T# t$ G6 l
part := @.cont;3 U/ Z6 D8 O6 T6 C2 U2 O
@.transpOrder := void;
* `& x* B; }6 X part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1, j4 z5 ~# `- z6 ~ h% Q b
@,root.eventcontroller.simTime);- p* f. _+ j$ ~
@.HasOrder := false;
; }7 n+ @, ^7 I @.DrivingHome := true;( ?- o7 z" j: W# _5 E9 `4 Y
rgManager.tryToStartTransOrder;
; x! {# P. k8 S9 u$ M" D if @.Destination = void4 {! [ S. |& _4 C. B; w1 R% Y2 w5 V
then -- no transport order for vehicle @
: Z0 J1 @* U3 ^$ M( [( k5 w @.Destination :=* Q2 g- w- n# p' f }) U
rgManager.nearestFreeStation(@,track.~);
* }, P: B* z+ B- O t- b newDirection(@);
$ i! ~0 K4 ]2 ~: g2 Q9 u$ N if @.Destination /= void then E" T' F0 S& B4 v" w
@.Destination.NumReservation :=
. s9 |( p. b6 w! y! i: C @.Destination.NumReservation + 1;
1 ^6 e" i+ B7 R# C1 r end;
: o. `2 A# c- [5 O7 A/ H) ^0 p5 _ @.CurrIcon := "drivingHome";. C$ P4 C) f! j& J! r$ Q
@.DrivingHome := true;
+ |- M6 o1 |% C7 E end;
- x6 l5 `4 _! A- a) ?+ O* S else -- the vehicle @ is empty, both vehicle and part are in the same dock station
* P0 W) o$ b4 |; d- }% b7 L part := @.transpOrder;2 Q2 {6 b4 b9 c% M% w
part.move(@);-- load part
, F$ z: g7 n) d. _ @.CurrIcon := "load";# O8 T% K) u* R
GlobalDistObj := part.globDestination;
) }, L L% j' F5 x/ B, m assignLObj := rgmanager.rgAssignL;! c" ~6 c: p3 h6 Y% E9 k
row := assignLObj.getRowNo(GlobalDistObj);: j/ w* w! X8 A/ J& q
if Row = -1 then -- since 70' y& `& D8 C8 B( E6 D# q `6 I3 P
if lan=1 then
2 }+ `0 D6 t$ ~+ f( W3 R4 C promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
8 t7 @1 T7 a4 ]+ M- T3 v to_str("in der Andockstation: \"",?.~.name,"\""));
1 Z* f( a7 t Q! P; J7 Q$ f' S" ` else9 m7 l4 B; \* s/ Q3 f) j7 [
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),3 ~* J* L- S" r% \8 D
to_str("in docking station: \"",?.~.name,"\""));
+ k" ^! Q0 f9 \# V7 Q/ n end;
, \& S6 G9 t5 w; I; _ else# p2 @( d3 m% J
@.Destination := assignLObj[1,row];
/ e) G# T" V, Y& x1 [ ~ end;
' D$ j% ^8 X0 N) _8 \" z. } newDirection(@);- r1 t8 r( i3 W* G+ r! z
@.HasOrder := true;
- A5 x1 p) `% ?4 X end;
' e0 W+ x0 H, k( J6 i3 U+ _: f end;
, k2 S7 M% n, F- x. Q4 tend; -- of the method9 x% l0 j5 E7 U6 D# @; G
|