/* called by: entrance ctrl of the object 'track'
/ s8 |0 }% m4 e# F3 ~*/
9 N9 \' D+ q+ Y" Y5 [8 iis0 J8 H7 K: i! T9 L6 `+ H" v
part, GlobalDistObj, assignLObj:object;row,Lan:integer;
* Y0 j% ^0 h. G$ V2 tdo+ O7 t) ~! n) }/ |% U
Lan := rootfolder.Internal.Tools.AOLlanguage;) P9 U6 C8 v& I# U/ ^* @# [1 \, f
if current = @.Destination -- else return/ y1 ~& g) L9 [, y1 J
then* L! ~5 T5 ?8 n [. A2 q$ M
@.Destination := void;
- b& v+ V3 h5 H+ }8 k s if @.occupied then, N- l% ~$ p4 U7 U% M, c
part := @.cont;
& R/ w2 h1 V2 k7 g3 d4 ]4 d @.transpOrder := void;: {: x4 \- t/ _- m+ L, \) R" R+ _
part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,) X4 o3 ?( b* m9 q2 y2 m' G. ]
@,root.eventcontroller.simTime);
* _+ T3 ]6 Q+ c/ u- w. \ @.HasOrder := false;, `" t$ c4 L2 @' ]9 H( n
@.DrivingHome := true;3 n/ E7 E" x/ m0 ~- `/ `! ^) D
rgManager.tryToStartTransOrder;+ d9 ^5 \: A, p/ j4 ^# u4 |/ q3 W0 b
if @.Destination = void. \) h: b2 \0 I& Y, r" N3 Z
then -- no transport order for vehicle @- p+ v$ D/ }9 _, H3 L0 H; U) r
@.Destination :=( Y/ M5 w; G8 J, N5 G: X
rgManager.nearestFreeStation(@,track.~);$ x( [/ h( w% O) {2 n& C |
newDirection(@);
+ m( y& y0 H# |& `- f/ ] if @.Destination /= void then
& e" t4 X# y* z8 ^* P2 e( x u ] @.Destination.NumReservation :=
' Z5 v0 B5 @" {1 V1 O6 k- F+ ^3 W0 D @.Destination.NumReservation + 1;
5 l( ?" f' f4 q8 o/ P+ Q& J( _ end; @0 t& d3 \2 ^; a
@.CurrIcon := "drivingHome";
, Z, c3 X- D: n" A5 O @.DrivingHome := true;
* p- g' C; u- m! R+ G# I end;
# B8 L) r. w6 `8 U else -- the vehicle @ is empty, both vehicle and part are in the same dock station
1 X% I L: n3 L8 [# K part := @.transpOrder;
" m7 z) ?( E1 i* R. s! ^ part.move(@);-- load part, |0 W6 T0 ^' k" o/ C! l
@.CurrIcon := "load";: d2 D. h. r/ E) _
GlobalDistObj := part.globDestination;
~; c" M* R9 }+ \ assignLObj := rgmanager.rgAssignL;( }, B/ ] ?5 Q$ u
row := assignLObj.getRowNo(GlobalDistObj);* l3 p5 M6 B9 W5 l1 z& K
if Row = -1 then -- since 70
+ X8 p0 x: a. |9 o2 q) P' N if lan=1 then
! o- G- V% j: y4 G/ \8 x4 O9 G promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
* M ~9 n+ k: ?& {1 c* M* t7 P* e to_str("in der Andockstation: \"",?.~.name,"\""));3 {- U* t$ i% |. g, V( [* S1 F
else7 `8 C' U9 u4 R* X" x/ b. i
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),& I" B" M% n5 ~. h% z2 V" l
to_str("in docking station: \"",?.~.name,"\"")); # C9 s8 F% D5 b0 s) J
end;
% ~; p# U3 M) ^- J2 c) p else
9 E! X2 B6 L# a, ~5 D @.Destination := assignLObj[1,row];
/ y9 o$ b9 F& R& J2 S, x0 o end; 6 ?/ E, W* H6 C) e# b
newDirection(@);# s' k/ T8 Z6 }- x
@.HasOrder := true;2 U: f M* v, N( }; `
end;+ G5 y! X) d! W) J2 L; e
end;0 H* P% v' t8 f: y
end; -- of the method
9 j; f ?+ P5 b4 C! B |