/* called by: entrance ctrl of the object 'track'
0 v6 _4 j, t z& |/ @6 [ {% j*/
7 b5 t, r3 s% cis
- ~) k0 B; k% ^; G5 N part, GlobalDistObj, assignLObj:object;row,Lan:integer;5 `4 O0 |, {. W4 E
do
- L8 p8 m% L% {* K Lan := rootfolder.Internal.Tools.AOLlanguage;9 j' ^' n1 G* d1 ^9 E- M. E3 e
if current = @.Destination -- else return, z* s" C, S1 R5 a" T* a" P+ v9 c
then4 A. ]( k9 W" {" }
@.Destination := void;
/ m% c1 r7 }8 O, f2 [: _, h8 c if @.occupied then
5 U3 y1 }# h, ~; J3 j$ k+ R _ part := @.cont;
, R2 [, M. Z9 B# B/ C, y+ s' \! B1 ] @.transpOrder := void;# L& B4 i K5 k5 n
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
9 s0 G5 s3 u5 i" {: C- T9 x% p @,root.eventcontroller.simTime);
- R1 C0 F8 h. A; C @.HasOrder := false;9 @7 r" I- u7 |1 N$ ^0 P# V
@.DrivingHome := true;
, ^3 e: Y/ I1 n# U: G rgManager.tryToStartTransOrder;& M: h, E: ]' e" |: g
if @.Destination = void& d' k9 u, A+ H+ l1 r
then -- no transport order for vehicle @
! D; }2 Z( q; E) W1 m @.Destination :=
3 c+ u- w2 j% e, a rgManager.nearestFreeStation(@,track.~);& c# c6 Q) e& ~) o0 h, F% I( Y+ n
newDirection(@);
2 ^) r+ O6 a# Z2 }2 x- K if @.Destination /= void then
5 v9 ~! N# J8 J4 G6 X3 e% o @.Destination.NumReservation :=
m0 j3 J% ^5 n @.Destination.NumReservation + 1;
a4 d3 }' V2 X. z8 Q end;
9 h# H$ `: B. b- Z @.CurrIcon := "drivingHome";" K+ f. a0 h0 x. ]% L1 `5 f2 u& g
@.DrivingHome := true;5 ~9 z, c5 _- D: k# t
end;
% A7 X+ m" P5 ^ else -- the vehicle @ is empty, both vehicle and part are in the same dock station. j5 d% y8 w4 [4 |2 w
part := @.transpOrder;) ?# p \- Z0 P+ K* p B
part.move(@);-- load part
* p" K6 o' W1 M# ~) ]6 m @.CurrIcon := "load";- M7 |/ z" `1 k$ z+ q- `9 n' M
GlobalDistObj := part.globDestination;
& h4 W' E- ^0 g% M! i+ \2 F assignLObj := rgmanager.rgAssignL;
' H3 d# `6 @6 l# T2 ~ row := assignLObj.getRowNo(GlobalDistObj);! r+ o6 f0 i0 |: c# F3 y$ i
if Row = -1 then -- since 70
: k# K7 v8 N1 g if lan=1 then
3 g# S! r* L% b7 m promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
9 @/ \. y* [( ? to_str("in der Andockstation: \"",?.~.name,"\""));' G: c! n9 G1 T. p" {
else4 _: D3 J% O$ ~! d
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
: ^* @! k+ _0 }/ W3 S! y to_str("in docking station: \"",?.~.name,"\"")); ( N) n; z2 F/ B9 l* r1 W$ d( S/ [2 g! p
end;4 n# g( L9 [, E4 q; f: t
else
0 a% L; g3 o' M- p H" Z! ^ @.Destination := assignLObj[1,row];
/ T0 o# _0 l1 H/ Z- | end; 4 i. c: x' q+ i5 e7 ~
newDirection(@);9 D) w; g6 p8 [
@.HasOrder := true;
- a8 Q7 I* B u& r4 M8 V7 N end;
6 J9 V2 v% n+ ` end;
, i& D, o: V: ?7 _% p' K/ @/ v& C9 }5 Eend; -- of the method
* K7 c3 q; h) W" o5 i. Y |