谢谢shakie的耐心解释,我按照你的建议改了代码如下(并在window窗口定义了L_null);
! ]6 H; {/ ^( y" [( K1 ybegin model initialization function, U# e1 \( T Z: Q# F7 V7 I% k1 X
create 1 load of load type L_null to P_Creation2
( A+ B2 s6 d5 N+ ?, \ create 1 load of load type L_null to P_Creation3& F8 Q3 R0 ^- p. y3 S4 N2 x
create 1 load of load type L_null to P_Creation4
7 ]! g% [6 T6 \- g8 g return true
' s! X2 V. v$ {# S( h" }) t2 y- s qend' c4 A' o; m& ]' v0 }5 d
6 x: p5 L: s7 T* j, xbegin P_Creation2 arriving procedure
7 _, L. N, R. y& D! dwhile 1=1 do' F* K' }' V2 Z9 n) k" r
begin
. {6 [& @8 S+ @4 E/ r wait for 1 sec, o+ U7 z5 @1 Y7 K
create 1 load of load type L_C2 to oneof(0.2 _In2,0.8:die)
; }, U5 g4 Y) u7 a" @ end; h0 ^$ I9 x- h, s
end, d4 U! E7 v$ V! C* W9 \
- }9 m- Y; S; Ubegin P_Creation3 arriving procedure
; ^7 i! T* Z8 J+ x% c. g0 Lwhile 1=1 do( J* L K& L7 [* C7 J
begin
. F! O; U; g8 Z% V6 Y% B/ Z wait for 1 sec
+ X5 P8 h: m; X/ i; B create 1 load of load type L_C3 to oneof(0.2 _In3,0.8:die)
. d4 g. h5 @% J1 t/ ]0 H end2 a& T! l d% h2 U- C4 P
end
# X8 T) P$ X2 s3 V/ N. N- G2 A4 H- l+ A3 [* Y+ r. T
begin P_Creation4 arriving procedure
$ ?! ?- e/ @# F2 D9 b# @while 1=1 do2 f/ z6 ?8 o) f; t
begin
2 i4 E. i1 C0 S wait for 1 sec) T, Z' |/ w" @/ o V o8 c
create 1 load of load type L_C4 to oneof(0.2 _In4,0.8:die)) K' l. v% T$ V5 o# B. l& ^ Y
end) V" I0 D0 d: i+ W. d6 ~/ F: E5 G
end, M, E4 a7 _9 w0 K7 M% j
" O4 Y$ h+ k% P! N9 |. R
但运行时仍然出现相同的问题(提示:ox100f5e09指令引用的“ox00000028"内存。 该内存不能为"read"),无法运行。不知问题出现在哪里,请高手指点,多谢! |