/* called by: entrance ctrl of the object 'track'' o1 r5 U6 v" i3 C
*/5 a1 Q5 ?% ]+ S; A
is) M: U; T$ b/ c4 f
part, GlobalDistObj, assignLObj:object;row,Lan:integer;/ V) I, L0 v3 C4 H+ j0 W9 W0 T
do
# Q& C2 C. m! p6 S Lan := rootfolder.Internal.Tools.AOLlanguage;
# \0 W$ `8 \) L if current = @.Destination -- else return Z5 G- f( M& S
then
. s/ _; ^- W6 R/ N3 K k# S! v4 b0 _" { @.Destination := void;
+ S& n, P# r5 ~- x E# E F if @.occupied then
) i$ n+ L1 I- Y* O1 f! c/ |) J part := @.cont;3 U3 x$ [/ J0 v
@.transpOrder := void;* G) {& O: B0 l `! V7 T" z
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
3 | H8 z" {" {' p7 W @,root.eventcontroller.simTime);# }' Y/ k N6 y* R. N: A! c
@.HasOrder := false;
; z, d/ k. j& q& z @.DrivingHome := true;
( c# M1 b' T6 ]$ W rgManager.tryToStartTransOrder;
1 M- [ \$ E% Q if @.Destination = void
. B1 J; t# q, N: |" Q1 }# h4 g$ n then -- no transport order for vehicle @) r0 w* [, v5 _6 ?- S7 M2 G6 m( i" j4 E
@.Destination :=# T, n2 H/ p$ S( F2 K- f/ |3 z6 L* \
rgManager.nearestFreeStation(@,track.~);9 h, l( N6 ~" u, C. o- x8 W
newDirection(@);
# x: m- x2 |8 k7 R5 d8 L if @.Destination /= void then! \: g% f1 x! O0 c% `" P. K
@.Destination.NumReservation :=2 ~$ L- m2 i9 b- d& {1 z" H
@.Destination.NumReservation + 1;
1 o0 ~0 k& z; a, p" w4 h2 l end;: V8 r7 }$ J! t5 z, f! U% m
@.CurrIcon := "drivingHome";
& j M7 B& a/ f @.DrivingHome := true;
1 k" ?% \# m/ `3 F& U% N end;8 b- }" J& L" Y0 b6 |- A) ~0 o
else -- the vehicle @ is empty, both vehicle and part are in the same dock station1 \7 d3 c' k) D! } h- J- l
part := @.transpOrder;- g0 N2 o3 @ O" ]- A! B
part.move(@);-- load part
& H# P! K* [' \/ N& Y+ q& b* r7 s2 K: M$ s @.CurrIcon := "load";
- h% ~9 i/ x* T3 z. f0 u* w8 |& p f) R GlobalDistObj := part.globDestination;
. c8 W* J6 \( R assignLObj := rgmanager.rgAssignL;
+ m" \; f6 t3 `. u) y row := assignLObj.getRowNo(GlobalDistObj);; L# L: u, T7 B5 _
if Row = -1 then -- since 706 R: |- `. s% n" N
if lan=1 then# R9 u1 b7 d6 ?, j5 Q) z3 H
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
3 N5 H/ ? W V: F! s, W to_str("in der Andockstation: \"",?.~.name,"\""));3 C$ e, I! A- X* F0 n
else
4 V3 Q7 s9 l& a9 ?2 j promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
' y4 I4 ^" B5 P9 e% J4 ?: ]6 S to_str("in docking station: \"",?.~.name,"\"")); 0 e+ [4 x2 }' t+ ^+ `& N( M
end;
- n P- v2 S& {& ? else$ l. Q: c1 o/ J* g: L
@.Destination := assignLObj[1,row];
# u0 C; L# X( _ end;
' n# U z8 k# n" o/ e newDirection(@);3 T }! E& T: Q: M* j4 b- v
@.HasOrder := true;+ g9 u* X0 u! M* ]0 c" ~
end; C7 }6 H, r+ _
end;3 m7 w% l* _$ y5 `4 f; _1 |: T' O
end; -- of the method* k- R: Z( \- k/ M; g. y& Z7 f2 }
|