谢谢shakie的耐心解释,我按照你的建议改了代码如下(并在window窗口定义了L_null);
, ]4 q+ A2 u9 R4 [+ v5 E% tbegin model initialization function% k( J4 \) {6 |2 M* P0 B
create 1 load of load type L_null to P_Creation2: L2 w0 [" o& k$ }
create 1 load of load type L_null to P_Creation3
! Y9 u+ l, a: f2 ` create 1 load of load type L_null to P_Creation4% R- N- ^$ t! ^. z1 r1 y0 b/ F0 g
return true + ^6 w3 I' ~( Q! P
end- @' e1 |% ^3 B0 N; d) p
% ?; U- ~, l# d- O L( O
begin P_Creation2 arriving procedure
/ E5 K3 p1 N! b8 ]/ h( O5 P' F& V Dwhile 1=1 do, r" ~0 Y3 X4 O& C* |
begin8 G# X0 z: t v7 }( T8 i
wait for 1 sec0 d8 I( f* Q. }" o0 B' N& y9 J2 P
create 1 load of load type L_C2 to oneof(0.2 _In2,0.8:die)3 @; h( ^# s9 _0 B5 F, r
end
( `# H; V, N7 r4 ? a- B6 \end
! _( U! @5 {5 ?! d- A$ Z% u+ k! ]" X( B, j( L" m
begin P_Creation3 arriving procedure- C1 B: A# e C1 q/ X8 W! A
while 1=1 do5 V0 i6 [) f( O R3 H) u
begin
$ X4 M9 J' ]- J, ~0 `( Q/ Y wait for 1 sec
5 s* @/ I+ u8 Q, k. L create 1 load of load type L_C3 to oneof(0.2 _In3,0.8:die): g }+ m' \% S
end
c; {3 t9 C5 xend
, m- L# ]' T1 g3 X: P9 f( b; R# ~- ^
begin P_Creation4 arriving procedure( \* \, M2 ?% ]% V3 n2 H, n6 {
while 1=1 do
3 P4 m3 a! { r; o5 x4 ? begin
% \3 N1 G7 f# ~, H4 |, C4 }! R wait for 1 sec
: P' ]% k" P2 ] create 1 load of load type L_C4 to oneof(0.2 _In4,0.8:die)' I& S8 J E7 |# o
end
n b, A y7 f, c0 [1 Vend% Z# D! ]; {% B u) u0 [
. u" c8 _9 o8 ?$ z6 N' s但运行时仍然出现相同的问题(提示:ox100f5e09指令引用的“ox00000028"内存。 该内存不能为"read"),无法运行。不知问题出现在哪里,请高手指点,多谢! |