/* called by: entrance ctrl of the object 'track'" Y j. k/ F T' u1 r1 y
*/
( n5 j3 O9 ~8 ris
: e8 X* T2 U* K$ a- k1 \ part, GlobalDistObj, assignLObj:object;row,Lan:integer;! D" H3 g5 {* i! A7 Y* f$ @
do; p4 A' Q! W( Y# j+ T) v
Lan := rootfolder.Internal.Tools.AOLlanguage;, Q! n7 T/ o( Q2 X' c9 K
if current = @.Destination -- else return: F' j& W: a/ U; I5 D. u
then \1 s1 ^% b1 E/ Z5 C* k
@.Destination := void;% N+ J* N+ C0 X- O/ A- T
if @.occupied then
. ]/ m% Y q: A4 H$ B- _ part := @.cont;
; P$ t! O& b( [% H @.transpOrder := void;
d0 V7 a3 j) O' v) ~ part.move(partExit);-- unload is already possible rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
) ?" D7 ]' m% z9 U @,root.eventcontroller.simTime);
( _# K8 k# R3 A" E' ]0 q @.HasOrder := false;
% J5 y( q0 V8 p& M- D+ h @.DrivingHome := true;
7 u% ]) ~0 F% [5 u$ g" i* K- m% S rgManager.tryToStartTransOrder;7 Z3 {- W( s* t% d0 A; S8 U1 R
if @.Destination = void
& |4 N/ J. F) O" b; ~8 r! u then -- no transport order for vehicle @
0 b. v# N( @1 N' b @.Destination :=
- b6 X! U& _9 N) ^! s3 M* J rgManager.nearestFreeStation(@,track.~);+ Z' f" T J6 H; v( Z6 _9 t
newDirection(@);
& y, o: a4 P! U' Z- e) p if @.Destination /= void then2 H# F; J* f; z. B
@.Destination.NumReservation :=
/ I4 S0 g z6 ~0 J. H @.Destination.NumReservation + 1;
; o& x/ z: b S; ~$ a* X end;
* D( d$ u0 h2 _0 k& h9 v$ ]! q @.CurrIcon := "drivingHome";
: w6 D! E1 q$ X @.DrivingHome := true;: c$ S# N& X) a. h
end;
* e* ^. |" N! I% P5 Q( a else -- the vehicle @ is empty, both vehicle and part are in the same dock station
# @/ n$ U5 W' @1 O8 a9 L part := @.transpOrder;
! a9 F/ S. j0 G# U/ g part.move(@);-- load part9 c' q5 y, A. Z' e3 ^5 S! C
@.CurrIcon := "load";
2 F# C I# `8 t' y GlobalDistObj := part.globDestination;2 M: M9 e9 c6 ~, f: o8 i# S/ b
assignLObj := rgmanager.rgAssignL;# q5 i* K6 G% k& G* D' F
row := assignLObj.getRowNo(GlobalDistObj);
' e/ R' R' a. M- } if Row = -1 then -- since 70
3 [" _! V5 O( z8 y7 w3 H+ i+ b if lan=1 then; B5 ^0 j/ k8 I5 z+ ]* I- `
promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),$ k' g, g& E: m5 H; ]( G% W
to_str("in der Andockstation: \"",?.~.name,"\""));7 O4 S) Q% ` P
else/ s4 H1 J0 N- k% U, P% f8 X
promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),( ^. t; g/ n) F6 N( s6 V& h
to_str("in docking station: \"",?.~.name,"\"")); * r! I' X( [, y! c5 \8 [! e E
end;
; s' Z7 A$ \' I! A" m else4 O" j* V' X4 r, S8 v
@.Destination := assignLObj[1,row];4 T4 b4 z. \: u' y8 f9 O
end;
# j/ U; ~! n8 W. ^& {' r newDirection(@);" E# M) I+ ?8 h+ @1 H( X0 i' k
@.HasOrder := true;
2 m# N( J. w0 p% N$ E end;
: T& R* X5 O! @! [& h* |! K end;
+ O* ^ t t. w8 j) t5 P' }end; -- of the method
; F8 U6 C$ x) ~ v |