/* called by: entrance ctrl of the object 'track'
8 D# M9 c5 D/ G* Y. P4 A& z*/
- `1 W8 k; G4 H, Y! [) ois6 \+ W9 |5 ^3 T$ ~9 P
part, GlobalDistObj, assignLObj:object;row,Lan:integer;
# a' ~5 k! x/ ~& Z# Zdo( X2 ^4 Y W0 y5 M
Lan := rootfolder.Internal.Tools.AOLlanguage;. m6 L$ O2 `& {, K E4 e
if current = @.Destination -- else return4 P' a. b4 ?( B& V R, c
then6 ^8 p( }4 R! v1 d5 t
@.Destination := void;
r3 v3 C$ s! E+ V if @.occupied then
9 I- z6 i4 R. r& @& n2 @4 Z& p part := @.cont;
! i4 b+ I+ O0 T( Y ` @.transpOrder := void;
. p3 K6 ` P) T8 P- S4 K part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,5 x- N H4 z; ]% E& W) h. }- H
@,root.eventcontroller.simTime);
+ F* E7 L$ |( R: Y. ~' G @.HasOrder := false;
' S+ y3 I+ _/ ^ @.DrivingHome := true;
; U7 R: t# v& E$ w rgManager.tryToStartTransOrder;
0 e$ k1 B3 {- @ if @.Destination = void
% E4 h% f2 k: {0 A3 ?/ S4 j then -- no transport order for vehicle @
$ V7 z# ?, Q, a& O4 ? @.Destination :=
) ]/ D- w. z. c" M rgManager.nearestFreeStation(@,track.~);
1 p( F& |! |. G( i; n5 I3 I% d newDirection(@);
% A5 K1 s/ |# h0 |9 F* I( ~0 k' ? if @.Destination /= void then
9 B" j1 c' W9 E6 X }7 `0 Q @.Destination.NumReservation :=: \. r5 A, s i8 j9 A( d
@.Destination.NumReservation + 1;0 P) u# E5 w$ Y* S" R! J4 J
end;' M" z/ I+ u/ F" I) _
@.CurrIcon := "drivingHome";
t1 b8 B1 F+ K% i& J+ t5 m1 p8 o @.DrivingHome := true;! v0 T' |" b* J, P
end;
4 O/ O: M+ \- V. f else -- the vehicle @ is empty, both vehicle and part are in the same dock station2 \4 s( W7 l- b) \# n P
part := @.transpOrder;
5 j5 A6 Y6 B$ o$ Z! |5 b# x$ S: x part.move(@);-- load part. l: f: m& t! |. }4 _' {
@.CurrIcon := "load";
* j) ~" {% x* j$ i& Q d GlobalDistObj := part.globDestination;
$ \. f+ Y5 l' R) A$ k5 c assignLObj := rgmanager.rgAssignL;" Y2 Y9 K/ c4 X7 M
row := assignLObj.getRowNo(GlobalDistObj);6 g3 Y/ b# x) C) A- l: f
if Row = -1 then -- since 70
- I7 \6 v1 N( w7 _3 A1 y* Y& @ if lan=1 then5 z- r2 ^, I9 @/ W6 V) C& T
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),7 n2 e! h9 _+ V/ {: l* G. v
to_str("in der Andockstation: \"",?.~.name,"\""));4 O3 ]- z1 v9 _( l
else: p8 P: r6 S1 @) C( y+ Q
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),( w* ?+ R6 o& k4 T3 ]& D3 s* j4 `
to_str("in docking station: \"",?.~.name,"\"")); 2 @$ N& K% i, Q5 u' g- ~
end;
+ I f' S+ r. H7 ^2 V% | else! V- W% s$ @4 e) ~9 B
@.Destination := assignLObj[1,row];
7 e0 w- ^ q' H! }1 Z end;
/ |, k% s( ^7 p. a newDirection(@);
9 j/ b& ?7 ?, d3 |: z8 Y- V @.HasOrder := true;; G% t" e4 E6 s; R* N
end;2 f* M- Z/ J! E \
end;' U2 ^# f1 g$ m* w( s7 D: ^
end; -- of the method
" |- }, T5 S5 l" |6 x$ x9 {7 Z |