/* called by: entrance ctrl of the object 'track'
9 P1 J! ?3 V$ I1 F: ]*/
) y, i- n8 l+ L% q# cis
4 V$ D: a" [( W! @ part, GlobalDistObj, assignLObj:object;row,Lan:integer;8 ?; o$ B+ J# O
do. @$ v+ ^, b0 `* s7 ?- X4 `! G4 M* d* s
Lan := rootfolder.Internal.Tools.AOLlanguage;9 w# U" x8 q# y6 S
if current = @.Destination -- else return
9 _; a: [, o$ N. n4 L ^2 V! { then) o R) _; M/ ]# {: r
@.Destination := void;
2 ]! d4 H- T7 \- U; a+ P! }1 S if @.occupied then
$ C' o- E7 z3 | part := @.cont;3 {8 d+ ~5 t d6 @3 S
@.transpOrder := void;
' c- W% L/ A: X# q, Q5 L part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,5 K/ T: l# f. A, j2 h
@,root.eventcontroller.simTime);
, L7 g2 k7 j0 w @.HasOrder := false;4 m2 r4 H i2 C4 P: [/ t
@.DrivingHome := true;
- l6 R- _/ J% D" e rgManager.tryToStartTransOrder;) T7 [" q6 ?% @# `, {
if @.Destination = void9 O1 o9 S; q, z
then -- no transport order for vehicle @4 v3 w6 ?; d( I
@.Destination :=: S9 d( x/ H* x/ I" T4 C
rgManager.nearestFreeStation(@,track.~);
/ p1 L6 p! P1 m; T; I [ newDirection(@);
8 [3 a7 K* V3 j( u3 c# @& h$ ? if @.Destination /= void then
+ \1 a* t0 [/ b, e0 A @.Destination.NumReservation :=" c, n, k( a+ v9 J/ E) x
@.Destination.NumReservation + 1;$ L0 g$ j, _" v. d
end;% K# l% Q+ a. Z I- W
@.CurrIcon := "drivingHome";
! ?# w$ ^9 n) V2 [, Q$ r @.DrivingHome := true;
: b! S% N" s$ @3 m6 o; P, ` end;
) C; y; u: t, K: L# k5 k3 V else -- the vehicle @ is empty, both vehicle and part are in the same dock station+ _1 _1 [0 a1 D5 E
part := @.transpOrder;$ ]/ |1 }" t9 L$ M* d
part.move(@);-- load part+ c h! Z% y' P# M; M# k4 d1 n
@.CurrIcon := "load";. @' f8 P! D$ F4 O& r! M& T
GlobalDistObj := part.globDestination;
6 z8 n* P3 l/ K( H. e; ~3 k7 e assignLObj := rgmanager.rgAssignL;( @/ e1 @# |8 S1 T1 |/ S
row := assignLObj.getRowNo(GlobalDistObj);
1 [$ ]" B& [: R% U* h if Row = -1 then -- since 70
' Q$ Q; O3 a0 z, c if lan=1 then
% ]; }4 {9 g3 E0 r promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
% Y$ x4 Q4 L0 E+ S to_str("in der Andockstation: \"",?.~.name,"\""));6 o- f7 q$ ^6 W1 U
else- J1 C) m* B0 R5 h% q" }
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
, X* N6 G4 s0 A9 ]. u$ _8 G to_str("in docking station: \"",?.~.name,"\""));
! [$ S5 w, X) E# n8 n6 B- C/ z) \% ^ end;
+ I: e) I# V3 V) `* B- @& @: Z else
2 i. D5 [/ w. C* k @.Destination := assignLObj[1,row];, n8 r# w( _# {1 A% f# x2 G9 h
end;
9 H/ y& r* b% _% m* N newDirection(@);" r: U' V( Z* T$ _
@.HasOrder := true;* Z4 h" C U, x
end;4 e: |8 K w- }* }0 \8 W' b
end;
5 [# u3 i! G" x: m$ d/ zend; -- of the method
* A/ _, H5 W' }" v) A3 K5 L, `) c$ t |