谢谢shakie的耐心解释,我按照你的建议改了代码如下(并在window窗口定义了L_null);
( R4 O+ t( ?& Nbegin model initialization function) e8 H7 u* Q9 y+ f: y8 l
create 1 load of load type L_null to P_Creation2
) F0 d, x/ T, m create 1 load of load type L_null to P_Creation3; V7 R" p' H7 d3 m& r
create 1 load of load type L_null to P_Creation4, Q0 d9 I5 M# k/ z
return true
/ Y( h1 P% }& P$ pend
# a& H& _. o4 p$ w( G% l" `: S& _% P V/ X; r5 h) ~& U
begin P_Creation2 arriving procedure
" J% \' b4 |* `; ?while 1=1 do& y5 s. Z. ?7 z& Y2 @ p
begin. R* ]& i: B/ O# p
wait for 1 sec
% r3 {5 S, \( S( q( m0 J- Z% |' W4 _ create 1 load of load type L_C2 to oneof(0.2 _In2,0.8:die)
6 m$ S( u- u+ E! \$ D' C4 ?9 N end
6 j0 N# P; ^( j+ n, jend
# j. I: ~; P( o9 j* S. {. v) q$ ?$ `6 U% ^( S, R' V
begin P_Creation3 arriving procedure
) C& t" n% k; \# y8 Mwhile 1=1 do
& j) o/ O. S* C& c begin
9 ^4 W7 o, H; [4 Y# E$ R wait for 1 sec. ^3 _( U1 V, l- L; z
create 1 load of load type L_C3 to oneof(0.2 _In3,0.8:die)
. }* E" }3 y6 e; t end
, `6 f: E$ G9 G+ E6 C6 n# w+ h& Gend
" H. d: Q5 E4 l( S, m5 ~, H
( i7 W/ ~% S7 {8 z4 \begin P_Creation4 arriving procedure
; b- x" f2 G5 Q8 x5 ^' p$ bwhile 1=1 do$ n P5 j' c/ Y7 H5 y3 k
begin
+ c) T0 H0 p } wait for 1 sec
+ p) f, o- K$ m4 u& `+ O create 1 load of load type L_C4 to oneof(0.2 _In4,0.8:die)+ ]8 i, A& `4 d% D8 n) Y& M
end
. E. o5 y; a# f7 ?! b" Dend( Y+ e \; m& l E, p& H/ p3 L
; h ]5 G& \- b) ?$ K7 m但运行时仍然出现相同的问题(提示:ox100f5e09指令引用的“ox00000028"内存。 该内存不能为"read"),无法运行。不知问题出现在哪里,请高手指点,多谢! |