/* called by: entrance ctrl of the object 'track'7 p5 ^3 \- A+ x$ m) [
*/% U3 d: ?, r5 S
is
4 ]7 a, [" z) p! y9 U+ d part, GlobalDistObj, assignLObj:object;row,Lan:integer;
& z# x* Y( \7 J4 n3 Z% ndo
4 l G [8 Z& J5 C! e; @& e* Y Lan := rootfolder.Internal.Tools.AOLlanguage;
# Q' Q/ w5 C" Q' M if current = @.Destination -- else return# b# K1 }% ~. k; K# f2 ~4 Q
then5 v7 F) j3 }/ a& O1 F% `
@.Destination := void;' j9 _, m/ z# d" v* q7 f& }+ y
if @.occupied then
6 ^. G. u0 B3 q5 J. l part := @.cont;
8 j9 R$ h7 \& l$ h* E. N @.transpOrder := void;9 |% P, l2 Y r% `% E
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,# L- Q( C2 R/ W# Y W# e
@,root.eventcontroller.simTime);
, B7 l2 l: i; e @.HasOrder := false;- n) x+ G0 H4 V Z4 D
@.DrivingHome := true;
/ O/ P! o! q* v4 f: f rgManager.tryToStartTransOrder;
# o% C) L3 v' H3 g/ R. Y& J if @.Destination = void
. _9 B% p/ l5 Q4 { then -- no transport order for vehicle @
8 |% ?. G. E+ }. e" Q3 j @.Destination :=" {7 G% y6 f& B- n
rgManager.nearestFreeStation(@,track.~);
) X+ s2 O% X! X2 E" I! w: I newDirection(@);
( f2 v& K8 O( V" ~( s, I. U if @.Destination /= void then5 ~+ ~/ r7 D/ {. _
@.Destination.NumReservation :=
7 ]' i- V& M: d* [" } @.Destination.NumReservation + 1; S% _9 y2 D0 m# @" D
end;
) O: V3 w5 Z5 s2 u2 t9 z' I2 a$ N @.CurrIcon := "drivingHome";
9 N% ]& {; L9 n9 n4 o @.DrivingHome := true;+ D; m3 `* J$ ^. q6 A8 k! y
end;
6 e1 n# Y8 o8 J$ F+ s else -- the vehicle @ is empty, both vehicle and part are in the same dock station
1 n( l8 g; c$ t9 o/ ] part := @.transpOrder;
9 O3 X. \! g; @0 _ part.move(@);-- load part
+ u5 p4 J4 z) G7 |5 k! Z @.CurrIcon := "load";
; F p0 z) d L! d- j* P4 z GlobalDistObj := part.globDestination;
+ [( V6 |; J8 \2 j assignLObj := rgmanager.rgAssignL;" p+ Z R/ u* I/ ^" w$ P
row := assignLObj.getRowNo(GlobalDistObj);
0 ]- T! l3 N9 Z/ P# l, ?2 b0 J( ? if Row = -1 then -- since 70# v! ?7 A6 e! w% P6 F9 ~
if lan=1 then; Q/ i( h Z- F8 C0 y4 ]& m3 X
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""), c( {& \1 k. }- |/ K$ f% Z: h! J
to_str("in der Andockstation: \"",?.~.name,"\""));, H! |- Z# ]- ^/ t q& h
else
$ }/ f; n+ s& m! f promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),5 ~ B2 G! c5 l' R0 x/ D
to_str("in docking station: \"",?.~.name,"\"")); $ Q" Y3 i- c+ S" N1 h4 e: ~
end;
+ y8 H# B- ]+ x. l# b else
/ o! c+ e! i* ]/ P @.Destination := assignLObj[1,row];4 u' l' V& h7 [5 b+ {
end;
: ?, F; b# Y' |& K: |% f newDirection(@);4 n2 p" b9 J' }! R3 g0 w( s
@.HasOrder := true;6 W* Q! J6 }# f9 U; V6 x, V5 ~2 Y2 H
end;
# h+ ^8 H% f4 ]$ Y end;! `! {, V8 Z( g+ [. ?! w
end; -- of the method
. w1 R+ a" I: E) _/ J9 P: _ |