/* called by: entrance ctrl of the object 'track'
- V/ U+ S# W) B4 y/ E. Y. b" L8 j*/% u, _6 _7 B; ]/ `6 l* w
is2 T4 u, g9 b, T" L% g; I4 J
part, GlobalDistObj, assignLObj:object;row,Lan:integer;
0 t# S l9 o1 `: X3 Tdo
4 W# G B" D5 }! w* n- P% O Lan := rootfolder.Internal.Tools.AOLlanguage;
6 x. C" H! l9 m8 h- j& C if current = @.Destination -- else return
6 N, [: K) i' G* f then1 o2 g/ K! P Q: |+ X
@.Destination := void;" z" v/ Y% z! p' s. a
if @.occupied then
3 I3 Q$ X8 [, M part := @.cont;
) o/ K1 C+ J% n# w @.transpOrder := void;0 H2 s+ s5 s1 W7 Q! W4 T
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
9 v& S( \- X2 ~( x @,root.eventcontroller.simTime);
) a. V+ S1 `& M) B; D @.HasOrder := false;
5 z( e' t+ z+ X/ S7 s9 s: Y @.DrivingHome := true;; Z0 L) F$ h- l( l; P( o( {$ x
rgManager.tryToStartTransOrder;
9 A: P+ W5 u/ t1 I' \ if @.Destination = void
; X: s6 I; N* U$ v+ G5 u( o6 Q then -- no transport order for vehicle @" U0 J, W3 O; ~2 u# z
@.Destination :=
3 O f7 W) ^5 K6 ` rgManager.nearestFreeStation(@,track.~);
* @" g" u4 I; Q, P6 o newDirection(@);
/ p$ ]5 f5 K; t/ O$ T if @.Destination /= void then
; A9 _- l. _) g2 l i* c @.Destination.NumReservation :=
& d# x3 q2 N2 m$ `5 g! i. g @.Destination.NumReservation + 1;
# k) u0 A' F, T- A! S end;- [# S; Q1 ]" q+ z# `; y
@.CurrIcon := "drivingHome";( I% T; i: j9 r' @5 E) u
@.DrivingHome := true;3 C4 v% @. B8 W' X, l' [
end;
4 Y: A! E. P/ W8 a$ x+ I& W else -- the vehicle @ is empty, both vehicle and part are in the same dock station' D$ B; t. q. L/ S+ u
part := @.transpOrder;
0 g1 w) B1 S% I% E: p1 ? part.move(@);-- load part
0 C% t" I; [5 J" ^1 v. V @.CurrIcon := "load";4 Q" [0 j' F# _" u8 i. E
GlobalDistObj := part.globDestination;
3 p: D# A/ S6 m" x }) w8 q. X( R% t assignLObj := rgmanager.rgAssignL;* A; m& i, m7 i
row := assignLObj.getRowNo(GlobalDistObj);
K8 E6 P2 S6 C- A/ j if Row = -1 then -- since 70
- `+ |) B" e# R1 P6 n if lan=1 then
v0 p# T0 H* n promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),; H# w" G Y! l4 j$ K3 ~- s
to_str("in der Andockstation: \"",?.~.name,"\""));/ D+ i- y" A& _# Z
else
& k2 Z8 ^: e3 ?8 X/ }3 y promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
: c+ l! k" y2 N2 c. k7 D" B4 W to_str("in docking station: \"",?.~.name,"\""));
+ C9 [# f# { ]: ]" i4 V8 \ end;! ^" T, C% x7 ]3 O( C
else! K2 w* k$ @6 J7 q* B2 q) S7 N
@.Destination := assignLObj[1,row];
4 y* [, l, r0 L& g8 i- q end; v- z# K5 \& e4 b
newDirection(@);
* x: g5 ?2 ^$ g3 c. G @.HasOrder := true;. T* B' H& k; @% U
end;
: Y: w6 }* |8 k3 J: } u R# N end;$ A; s/ c) |* c9 @) w/ M1 x
end; -- of the method
3 {* f) g' j6 N# f3 _ |