/* called by: entrance ctrl of the object 'track'2 W! [) K1 Y6 k% `( P
*/
6 f+ @, [4 ~! R# ?is
+ @& k1 S1 I3 e! k. T' J. m. Z. ? part, GlobalDistObj, assignLObj:object;row,Lan:integer;
& a% Z* _& S! _. C8 Vdo
$ C, h$ g$ u* P# B9 n E Lan := rootfolder.Internal.Tools.AOLlanguage;9 y% C; D' z S. ?) J( c/ F" W
if current = @.Destination -- else return+ ^/ R5 n2 w4 `; \
then
5 l/ B$ g; H2 g4 h3 p1 V3 @ @.Destination := void;% P1 M) \& T1 v+ \( \% k- c
if @.occupied then$ E4 Y9 I: S. l( a3 y/ _, f6 ?
part := @.cont;
) H6 `8 `" n, A7 ?3 Y @.transpOrder := void;+ X* Q' o% k8 x" M5 J# v/ Y, A
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
5 O: D0 _. S) V/ u# f0 T @,root.eventcontroller.simTime);, Q1 a0 P3 Q" [5 |
@.HasOrder := false;
* J& N6 O; u9 a' h* O% n3 w @.DrivingHome := true;
- X) i' X3 {$ A% {& f2 b rgManager.tryToStartTransOrder;$ J( o* d+ R9 w+ D
if @.Destination = void! b/ B! G. G; U6 M O: D
then -- no transport order for vehicle @+ l$ K0 ^" ~8 j; U* L9 X, P) x
@.Destination :=. A2 |5 @2 P! |! F& o; C6 x' r* n% `
rgManager.nearestFreeStation(@,track.~);
, E" P+ v4 p) |: Z3 ? newDirection(@);
) ~& b3 n! n/ {4 ~7 \* F if @.Destination /= void then
+ y0 Y8 }$ ]. A' @; D8 f @.Destination.NumReservation :=
4 u2 u& C5 Y m& a @.Destination.NumReservation + 1;
2 {9 h& ~, x7 ], u end;1 ~1 j; M" x' s% `# n" y; M
@.CurrIcon := "drivingHome";7 R9 W, r R2 b* ^1 r0 [. H
@.DrivingHome := true;
- X; d" Y+ l! _& \+ u end;6 r( U* K/ K- U/ q& n& F
else -- the vehicle @ is empty, both vehicle and part are in the same dock station
4 e7 \8 j8 Q2 y" u part := @.transpOrder;3 j2 i2 a& y H; g3 g
part.move(@);-- load part* O+ K5 I7 P/ K1 `7 f1 D h
@.CurrIcon := "load";7 H9 B: l3 T# ?5 X8 c5 o1 U, N
GlobalDistObj := part.globDestination;1 N8 k9 ~4 m4 @3 X4 w+ f
assignLObj := rgmanager.rgAssignL;
8 @* j4 p' y8 L5 T4 ]# {3 C! X row := assignLObj.getRowNo(GlobalDistObj);
7 V' D" J V9 M if Row = -1 then -- since 70
+ E5 C0 [( a: G. |$ N if lan=1 then/ \ o4 {1 y8 {! m0 j. ~- S
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),. M9 Y9 _) M) l
to_str("in der Andockstation: \"",?.~.name,"\""));* l5 D" q# c) I- X Z
else
+ L' h( V: T1 z) x( o( b promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),* f6 Y2 P& R4 l* D+ r# O; y
to_str("in docking station: \"",?.~.name,"\""));
7 @ L% ?& o- x# j: S7 U8 [$ ? end;
! d* M6 z( F% `- p/ D1 F" {+ e5 G else
% X( u, Q) g- j+ Z6 @+ u @.Destination := assignLObj[1,row];6 |) D* n2 P' y4 p0 Z0 b
end; 0 V8 v+ _% {" h C' c# ~ g
newDirection(@);
: {) B U$ h0 I5 u) i" Y/ h @.HasOrder := true;
7 }9 u9 W @. v7 U9 S* V/ G end;; ]6 X9 C" Y/ @' R
end;
j1 `0 d# c' i% k4 Zend; -- of the method1 n" T O1 U0 ^* @0 s- Y& s3 u
|