/* called by: entrance ctrl of the object 'track'4 K, o1 h8 j& p6 t6 c$ c/ K
*/
, ~6 e6 E: _. X7 \- _* D# G- Qis8 P Y3 U2 S& x( C
part, GlobalDistObj, assignLObj:object;row,Lan:integer;
! t9 T& h- |- b( Q$ ^' ]# Sdo
" g7 v3 N) W) E9 A$ `5 u) K3 } Lan := rootfolder.Internal.Tools.AOLlanguage;
- K+ n9 }/ M+ t& H& R/ Q if current = @.Destination -- else return
. d9 |& k* c: v- B then5 e4 ~, W$ g: A5 t: L
@.Destination := void;1 u& n, }/ b9 U. R9 D" w; s' n+ _1 |
if @.occupied then
' @. r" e- ?6 e6 _: b9 D8 I4 O part := @.cont;. k7 S0 X4 Q Y$ e. ~& v
@.transpOrder := void;5 c$ X7 s4 O5 K3 g' Q. z
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
- s" o y4 _( G5 b' L @,root.eventcontroller.simTime);
: B6 T4 x6 B2 I0 |9 G T! H9 X9 u @.HasOrder := false;/ S- O9 }" l3 J8 @" g: [+ Z
@.DrivingHome := true;
' h( J( b7 m5 z( ~% t rgManager.tryToStartTransOrder;
: t% i( [9 o, V* \; |5 [5 U" d if @.Destination = void
5 T& Y( k% |# I+ I0 T( X& m then -- no transport order for vehicle @
. F) ?" B; O( {9 g4 ~% Y @.Destination :=* M" O! D7 ^( j# B2 p
rgManager.nearestFreeStation(@,track.~);
. l/ U) z; L" f; f2 p+ @ newDirection(@); 9 H+ @5 x" w0 u1 y* a: `4 z, ]- @3 R' L
if @.Destination /= void then
- Z, m9 p, q3 M1 y @.Destination.NumReservation := Y P( H3 K+ m7 R' m2 |
@.Destination.NumReservation + 1; g0 c6 p$ j) g# p$ `
end;
6 q; m2 V+ X1 g: E$ s6 c1 S' E @.CurrIcon := "drivingHome";' Z/ c+ C/ e& S/ g: k; D
@.DrivingHome := true;
! n" ?" ^8 u |# Z2 S end;
4 S1 v- \( U3 L, O t; q7 M! b else -- the vehicle @ is empty, both vehicle and part are in the same dock station
! L/ Z9 w2 n6 O) g% o* p8 {+ ^ part := @.transpOrder;
7 Z, _4 X) a0 A( V part.move(@);-- load part
, l; A" E7 U" @/ e @.CurrIcon := "load";
" M$ B$ D6 { j0 j8 l. c GlobalDistObj := part.globDestination;
F3 A# d* R j# i* R assignLObj := rgmanager.rgAssignL;
! U* L0 H/ B8 l row := assignLObj.getRowNo(GlobalDistObj);3 Z# X U: m' F# w' G1 l2 k
if Row = -1 then -- since 70
" _7 [# J! A+ l4 F if lan=1 then7 z8 J. g% K2 k2 ]1 c$ Y9 n
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
. Y' `( t/ h d \ [: L+ S( W; x% O to_str("in der Andockstation: \"",?.~.name,"\""));4 `7 S: D6 J5 D7 Z. D2 u# c
else+ e& H3 C6 M. }9 Y( q
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),- p3 G' x3 ?1 i* D' J4 c/ O
to_str("in docking station: \"",?.~.name,"\"")); 3 m F$ B. T9 b
end;
, ]; x- B3 j8 e1 d0 S4 J else' m! I( Q& n. G
@.Destination := assignLObj[1,row]; Q) D9 Y Z% ^
end; 2 l1 \) p" l" m3 E& _
newDirection(@);
; |0 r* Q. ]/ n) e& a @.HasOrder := true;
' x3 R( d5 a, p9 B& R: L end;
; o; z4 }5 B1 k% L3 W end; g6 ]+ X0 O; H. I
end; -- of the method& p9 v9 B7 Z+ h$ Y
|