/* called by: entrance ctrl of the object 'track'
+ h7 _' j" r' f6 K*/) p3 b- T9 h, a' z' Q9 ^
is
9 @. t( {/ V' X# j( ] o8 [ part, GlobalDistObj, assignLObj:object;row,Lan:integer;, R' y' K3 A/ ?( ? E6 d$ K
do& L8 h s# ~- P5 Q( D
Lan := rootfolder.Internal.Tools.AOLlanguage;+ N+ s/ U) s$ ~% t! ?/ m
if current = @.Destination -- else return: ~3 q4 o0 O7 F L
then
+ I# L2 V' u/ P( V2 X" B" w" }# v @.Destination := void;
* S* l6 g$ y' p( Q if @.occupied then% p, O0 P0 v9 g& e; h% a" e* G9 T( N
part := @.cont;( c4 u/ J' d7 B- o
@.transpOrder := void;
: Y3 { ^ E0 L0 | part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,+ e+ R. R- u& Q, p
@,root.eventcontroller.simTime);* W& S9 J2 K- N; z% U
@.HasOrder := false;( s3 z1 ~8 Y- C$ p3 R$ Y
@.DrivingHome := true;
! ]: N) n) s7 M @, B% P rgManager.tryToStartTransOrder;
8 q( {) T* k7 ` if @.Destination = void: e9 W4 v# ?1 C2 K7 }
then -- no transport order for vehicle @5 G" s$ A# Z1 J0 P0 I" v4 k( T0 B
@.Destination :=
2 `; P( Q8 p6 B4 G rgManager.nearestFreeStation(@,track.~);- y7 A: r+ V+ A! G5 `" N6 Z& o# s
newDirection(@); * s Q) x6 N, u+ M
if @.Destination /= void then, h8 U* E; ]3 z' i, v5 O! t2 t" ]
@.Destination.NumReservation :=
# J. F' q- x& p* ^' k8 Y. e @.Destination.NumReservation + 1;0 p4 Y$ O5 `6 n6 D8 K" ]) A
end;8 K8 t% a c7 @
@.CurrIcon := "drivingHome";
2 m; |/ k% ]) y1 _3 r @.DrivingHome := true;
5 U+ J; { d( x5 a$ X; Y, f% n: @& S end;/ S. D8 ]8 v) j" e+ O3 X1 p
else -- the vehicle @ is empty, both vehicle and part are in the same dock station
+ n7 h; L3 J0 J; k part := @.transpOrder;
- {, {( J6 m4 r5 a6 @ part.move(@);-- load part* @3 X1 h3 J0 e1 y, m9 H* V6 o. B' X
@.CurrIcon := "load";
3 I4 d% N4 b5 f! X7 `* [/ G8 i GlobalDistObj := part.globDestination;
8 F7 D: e* E1 [1 |" ] assignLObj := rgmanager.rgAssignL;5 H, Y, \: B' \: |3 N8 h
row := assignLObj.getRowNo(GlobalDistObj);0 z% r u# Z% m% Z
if Row = -1 then -- since 70
3 ^9 ]" V) n: d& y! C) v$ j if lan=1 then
+ |8 H/ ?5 X5 G" @ z promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),4 M4 R- A( V/ B% ?' \
to_str("in der Andockstation: \"",?.~.name,"\""));
2 ~/ {( c' b& h: u5 S else/ h" _6 x# g1 h; e; t
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),# ^5 U! c' Q6 S; y! e5 U. L
to_str("in docking station: \"",?.~.name,"\""));
; s5 C* I6 p* a( x" y) z end;
. I) ^2 `5 K9 \- z; k else
5 e: P- K& {' X @.Destination := assignLObj[1,row];/ I. N8 y# o% K
end; , i& {1 t4 n, m! s: F) X# L
newDirection(@);: Z" G* Z; C# t5 ~
@.HasOrder := true; G* `/ g- a1 ^5 v
end;
" F$ V P3 g y6 I end;9 o/ o" ~( M3 _. m a, m) c
end; -- of the method" ?. O, R5 D) ^% k; {$ a! C
|