谢谢shakie的耐心解释,我按照你的建议改了代码如下(并在window窗口定义了L_null);
3 ^7 F- s, N9 ~# O1 x, n6 Ebegin model initialization function. X" q% y/ \* m: v7 M
create 1 load of load type L_null to P_Creation2* P+ s& j3 W9 x3 y8 i5 {* d
create 1 load of load type L_null to P_Creation38 }; Z0 n8 }% p, n L5 n
create 1 load of load type L_null to P_Creation4
" e9 {9 ^1 ]2 |0 h8 L return true
9 f" B* }( u' [end5 v0 q$ Z' O$ \+ V) O1 i
8 u2 q( {) x% _, }7 N0 w! o0 Ybegin P_Creation2 arriving procedure
, ^' P. o; ], X& U5 s( ]: S. }5 `while 1=1 do
6 b& r- x1 s+ z U, j5 j begin
( B4 Q5 C( I5 {% f. s- B/ v wait for 1 sec
( z, n+ g# C" y8 r( a' s create 1 load of load type L_C2 to oneof(0.2 _In2,0.8:die)
/ I6 k: ?( A- W- J/ A, l: b+ } end/ A$ z, M7 O& F0 q0 Y" W
end K0 I- C% j: j8 I4 G$ j
( _, ?3 l \+ G$ |. z! @* s
begin P_Creation3 arriving procedure
- O( d- K7 s! `* U! ^4 N8 _while 1=1 do t+ m% }3 O" ?0 S9 Q3 Z6 o
begin4 _# i: D) u/ X- S
wait for 1 sec
1 B& [+ t. E5 a" U8 r create 1 load of load type L_C3 to oneof(0.2 _In3,0.8:die)
& K3 F1 p: s1 u end4 X0 Y4 R! s7 V3 i$ F
end
2 ^! F& |" {( b# Z2 S6 `" N6 [# X' j
begin P_Creation4 arriving procedure# w# D5 Y* t7 d4 s
while 1=1 do
, M, a& m! _/ a( x* c/ q. A' a) I begin
/ R" }2 a# j' }0 b8 m# M. S4 R wait for 1 sec7 i+ h' |0 l4 O" i
create 1 load of load type L_C4 to oneof(0.2 _In4,0.8:die)
1 ], \5 C5 S" k$ s end
* W. ]- ~- R3 g! s( _% _" Zend
& y9 @5 h7 [( a; C/ V9 o& X8 Z- \0 J) X' \
但运行时仍然出现相同的问题(提示:ox100f5e09指令引用的“ox00000028"内存。 该内存不能为"read"),无法运行。不知问题出现在哪里,请高手指点,多谢! |