/* called by: entrance ctrl of the object 'track': F" N' W+ G5 c( X+ B7 y3 h) S
*/
4 T. k/ O/ M6 x) pis$ w5 l- ]: F, a- v/ C2 v/ l% q
part, GlobalDistObj, assignLObj:object;row,Lan:integer;
; C* M( d. E2 tdo
8 M* \: z0 `3 a# N& O5 P Lan := rootfolder.Internal.Tools.AOLlanguage;
+ l, R" x5 W' F& Q) J; D. a# Z if current = @.Destination -- else return
5 `: p2 c/ n2 ?; ]8 l then5 W; Y, H; y' \! E: r# J: y
@.Destination := void;
: s/ N5 ]! W% @ if @.occupied then- F6 h5 j+ d! k. u
part := @.cont;
4 w4 r* i* i. \* H @.transpOrder := void;
, F7 ^- N% n& ~; i* Y3 u g part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
1 }6 A* `5 q* G/ ~9 `* m @,root.eventcontroller.simTime);0 [9 }# C1 y6 j' ^
@.HasOrder := false;9 M6 J. N6 |' Y: m
@.DrivingHome := true;
0 K3 H$ U5 W9 O$ h! e rgManager.tryToStartTransOrder;
( E9 @. V) ~. R, d: }, n. ~ if @.Destination = void
7 H3 N: n' F7 P+ {& o then -- no transport order for vehicle @
0 r1 f! U9 K5 P) E. v @.Destination :=, D2 O8 K0 x5 r4 j0 M$ B- b) O
rgManager.nearestFreeStation(@,track.~);
: W, c0 D. k" \0 ]) } newDirection(@);
2 k. H2 M B: V/ K4 Y% Z; v if @.Destination /= void then2 e) ]7 f2 [7 x! W' t0 r4 }
@.Destination.NumReservation :=
1 q# \) G w: t2 A1 N/ f* D @.Destination.NumReservation + 1;% j% f, h6 `" l3 Z! _1 V
end;: U3 Q# Z/ V% [$ G& B- `/ L N% Z; J
@.CurrIcon := "drivingHome";
+ _ X8 q2 m# O @.DrivingHome := true;# p6 n9 O: P; _8 [ T
end;
! ^, P$ o8 f$ Q% z2 J else -- the vehicle @ is empty, both vehicle and part are in the same dock station; v: _6 ~. x1 ]9 [4 u) ~$ _
part := @.transpOrder;, O* Q* ^( P; ^- A+ k0 G
part.move(@);-- load part
; ]4 [$ o7 j# W3 Z5 U' O* z# ] @.CurrIcon := "load";
2 G2 }0 n6 k& X6 u GlobalDistObj := part.globDestination;0 Z$ ]- Y6 _" |' {
assignLObj := rgmanager.rgAssignL;
$ c! u% z. d1 R! z+ ?( R/ I5 Q row := assignLObj.getRowNo(GlobalDistObj);' Q+ S& a+ d- h8 x8 i7 F/ P3 h
if Row = -1 then -- since 70
$ W3 j8 K5 {- R" v7 _. f& @9 x if lan=1 then# n2 Z/ h/ ^8 {
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
) q' Z2 I6 S* |9 o* o to_str("in der Andockstation: \"",?.~.name,"\""));. [+ z, j. k1 r; ^& Q$ o
else7 A/ E [5 G! f2 }3 w5 M
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
, P- a5 W6 N( \) }! ~& o+ A4 x to_str("in docking station: \"",?.~.name,"\"")); " F% J- q) f0 g6 E6 u
end;, F. |" A) n( d! m$ ~" ]8 n
else
3 j4 P0 J x+ a: A- [1 B2 k0 c# T @.Destination := assignLObj[1,row];/ _9 D. b, b2 @0 `% K& g/ J
end;
* i$ @( w& E$ {( s3 `* y4 R newDirection(@);
- T% _/ z4 ]( J3 r+ E$ [ @.HasOrder := true;& q- X, E2 O( J$ |, A* D
end;
( {4 \% v) A% ^5 s- y end;6 T! I) v* L- `3 K8 u$ ^
end; -- of the method' j, j% O" s' C, v. w6 s: c# C
|