/* called by: entrance ctrl of the object 'track' M" \8 _& }- N
*/2 N% T; b/ N# @- T3 t
is) T9 F" y! J: I; T- i. _5 K+ t
part, GlobalDistObj, assignLObj:object;row,Lan:integer;
. e# d, ~6 G+ Ldo, F% Q4 M5 l: h6 V/ c) E0 }
Lan := rootfolder.Internal.Tools.AOLlanguage;7 k4 K8 a6 t; q# r) Y
if current = @.Destination -- else return
6 s" L3 R; ^& |1 U$ q9 }; P2 f+ R& \ then% X8 a1 x1 G( z# H, p) e6 r
@.Destination := void;5 G0 e, F9 @1 A. x
if @.occupied then
8 V; b$ U% G: g' E( K6 ~" ]5 a part := @.cont;8 G ^/ ]' b1 R$ D8 d# E
@.transpOrder := void;
/ l) ?; e. p4 M! H part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,7 x1 j' c- J$ y+ a
@,root.eventcontroller.simTime);0 K/ r( k( N2 d6 f J) C
@.HasOrder := false;
. _! l' v- ` f+ h. _5 F$ I ~$ f @.DrivingHome := true;6 U/ d, {5 p3 \3 Z( J" o- D
rgManager.tryToStartTransOrder;) v* M, J2 e. w2 b
if @.Destination = void
% E0 w2 a1 {7 _4 u% H6 d then -- no transport order for vehicle @& t8 g. u6 h" w# l3 j: w G1 i4 U
@.Destination :=
& {9 H! W, k8 a! d$ A) L rgManager.nearestFreeStation(@,track.~);
( a( q3 b+ A' ~5 ~8 ~ newDirection(@); $ ^6 l1 p* m! w3 L# o
if @.Destination /= void then
) }# ~% l: ]2 F: w1 A' B @.Destination.NumReservation :=
* y$ o# }+ v2 ^5 R4 N0 Y @.Destination.NumReservation + 1;. ]2 p% S# L) I5 J! X& _
end;
& W1 |$ E; z: O, E4 x5 J6 c @.CurrIcon := "drivingHome";( l# T/ l- @' P& k) K7 G: o( Q. z" J
@.DrivingHome := true;- X( s4 o3 U& {( k* a4 v" ]3 K6 j
end;
' {, `0 k/ w+ c% L& Q- q q else -- the vehicle @ is empty, both vehicle and part are in the same dock station, M! M0 P8 R% Y* H( w4 P1 H/ v2 E
part := @.transpOrder;5 `0 K* s; E! F
part.move(@);-- load part: ]2 @) W& B5 b/ I1 `, F; _; N
@.CurrIcon := "load";8 I$ W4 Q/ G* T# Z- U; g
GlobalDistObj := part.globDestination;
+ }* u8 B1 F1 Y; x. v6 X assignLObj := rgmanager.rgAssignL;
, [+ D X& H4 m! O, M; Z7 Z row := assignLObj.getRowNo(GlobalDistObj);
" n3 M7 t' y! E; x& [. {3 h if Row = -1 then -- since 70
* ^6 j1 V# Z& _: J2 W if lan=1 then6 H" U% p0 |2 d% D+ {
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
. y; w0 n; i) R6 q: R' ~8 W to_str("in der Andockstation: \"",?.~.name,"\""));
% A3 j2 ] M# y. _9 @& n else2 C9 p1 l% W- @! y* X" h
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),) x5 B; I: y$ g d. F7 h z
to_str("in docking station: \"",?.~.name,"\""));
, ~7 Y f# j( P! z! q6 a end;( y7 N" H. E; m: N
else0 p W3 X( \) D. j6 C9 d. @( A
@.Destination := assignLObj[1,row];
$ D6 g' J+ I+ y: o end;
& O: T8 P# M. x8 X O9 v. ^ newDirection(@);$ N8 V) G' j" |% D) ^+ s3 _
@.HasOrder := true;$ }! V S% M4 e' o* D; p
end;. \$ r; } O. b: W
end;+ f0 e6 d3 u6 J! _
end; -- of the method
) V6 n: B/ T0 U |