/* called by: entrance ctrl of the object 'track' U& `& b; m6 W D* @; G h
*/% c! _1 w8 p4 u o8 c9 ^
is, z O& H) q: ^; s
part, GlobalDistObj, assignLObj:object;row,Lan:integer;+ b* u8 ?# h' A
do
+ M! z7 Z3 W! ~2 B! N$ x. a Lan := rootfolder.Internal.Tools.AOLlanguage;3 O2 f5 a3 b, `& h# a
if current = @.Destination -- else return5 Z' {1 J$ a/ v4 p
then8 Z0 N* F+ r. J# i1 q. L! i' A
@.Destination := void;
/ h" Y. j' X! i9 n: s; s8 ^ if @.occupied then2 e# K! P; Q- J5 b# l
part := @.cont;1 U8 |) d" C7 |4 K! h) a$ a' j
@.transpOrder := void;
1 k X2 g8 @) p part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
; E2 }- E K, E# f @,root.eventcontroller.simTime);
. Y/ g* F) W! K2 s8 _ @.HasOrder := false;
& x- F& ]' s8 p/ b( Y" a! m @.DrivingHome := true;0 T" A+ M( h- f( _, @. J. U7 \
rgManager.tryToStartTransOrder;
: n+ P( l5 j8 ?1 W, J: x- J if @.Destination = void
* v# T- q: r: f) Q9 ?5 t then -- no transport order for vehicle @
$ O7 h, f7 U! _2 q @.Destination :=( C( j: i! A0 k3 J7 g9 j* q
rgManager.nearestFreeStation(@,track.~);
7 ^3 |# Q6 i9 x+ ~9 }) i9 @1 f, } H newDirection(@); ) l, j y/ b5 j$ B
if @.Destination /= void then* v- _3 U9 s! m; j# _0 P
@.Destination.NumReservation :=
3 P" Z+ ?& f% f5 i @.Destination.NumReservation + 1;7 ]" V- w7 w3 K; n3 Q% ?0 i! \
end;
9 a6 m1 B- a& c8 k @.CurrIcon := "drivingHome";
7 X# m2 P, Q5 U @.DrivingHome := true;4 ^8 h/ q N+ S# F/ G
end;% n! c) \7 q) X8 ^7 q6 ^( r" L) P
else -- the vehicle @ is empty, both vehicle and part are in the same dock station
q9 L& [/ ~! R% j6 J# W d2 b part := @.transpOrder;
: d4 W( l: d/ J" o8 E j& a) Z8 m4 S part.move(@);-- load part5 j* n$ q6 g3 m3 F9 k
@.CurrIcon := "load";+ ^4 `7 z8 c& l4 n
GlobalDistObj := part.globDestination;) W! S8 Q8 O! S
assignLObj := rgmanager.rgAssignL;( g; s1 |( Q0 X6 g2 B' o1 b8 n
row := assignLObj.getRowNo(GlobalDistObj);9 l2 e: R% Q' d& E
if Row = -1 then -- since 705 c/ z' E& o5 ?
if lan=1 then' I# G. z# a6 G, B
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
6 e8 `$ q# x$ p* U to_str("in der Andockstation: \"",?.~.name,"\""));( v4 B! m4 e9 M( G" w; o4 A
else
+ I' k7 k" [! ] promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
8 m5 b5 e3 e9 M3 `* ^) v6 d/ r to_str("in docking station: \"",?.~.name,"\"")); F* z' I) H3 A9 i
end;2 j9 I9 a1 `4 z$ }: w
else
1 E) Y8 i* N, ?# T- V9 n4 v4 c* o @.Destination := assignLObj[1,row];
2 L j8 O/ o; B0 w4 ] end;
6 K Z6 Y& D5 |5 j newDirection(@);7 [: U1 C1 A; ~9 W. e$ f7 ?, c: A
@.HasOrder := true;$ e( ?( I2 H* H& z2 a
end;
, x* {: a2 f. o' L8 Y. u3 V end;; q: c! Q7 h% m6 |9 S# J
end; -- of the method
7 C1 p! ?6 _7 l9 A, ^, u) y |