谢谢shakie的耐心解释,我按照你的建议改了代码如下(并在window窗口定义了L_null);
3 s3 m( Z F1 N0 A3 Bbegin model initialization function- y4 O( F# X+ {# c& N
create 1 load of load type L_null to P_Creation2
2 K( D$ v2 q \ R/ @6 p create 1 load of load type L_null to P_Creation38 }$ Z2 [$ B% I7 [- _; h* ?. |5 V
create 1 load of load type L_null to P_Creation45 d) `) |) P5 }0 X( n4 f
return true " T+ ]% K+ \) q* r) I/ U, y
end0 R9 B7 U/ Y( {% B. n" `/ q
! ^ a5 P; b U# }5 w: Q2 m* jbegin P_Creation2 arriving procedure! m& ~/ t, t: z+ m8 c2 h% U) \
while 1=1 do( U. S" h) g7 f$ K8 |& m% T' I4 G
begin: W* K7 o% w W! D/ ~, @0 L
wait for 1 sec% _+ I* \; N2 A8 ^1 P7 X$ C
create 1 load of load type L_C2 to oneof(0.2 _In2,0.8:die)/ |, U1 A& P; [2 f
end! u( j4 b9 P/ v/ P- k; [
end
1 G0 g9 `- ]- O V1 j0 z" K- O$ m3 U) `' l4 L9 j
begin P_Creation3 arriving procedure
; M2 R0 Y. W0 z7 j, V* Qwhile 1=1 do/ R$ b0 d$ Z9 t
begin; ] z' ?& ?% K" f
wait for 1 sec$ L/ E" ]! @/ \6 h; o
create 1 load of load type L_C3 to oneof(0.2 _In3,0.8:die): t% D ^- l8 c0 M) n
end
1 L' C4 C+ {, K3 K1 Aend
; W: K8 Q6 R3 r- k, _0 v
/ e; N. Q' k2 z. b3 L8 j, Sbegin P_Creation4 arriving procedure
* e- q7 A2 v* c: E. t' V7 b) {while 1=1 do& M7 [/ g) p" Q! O$ m, d) ~$ Z5 c, c
begin
" q/ z7 t' W. v5 [: f+ _; b) k: F1 O wait for 1 sec$ k' b, }1 z1 s8 x' z
create 1 load of load type L_C4 to oneof(0.2 _In4,0.8:die). a* n* t+ N) w" X& p1 l
end
0 z6 N% }2 L. t$ c, e& {end% Z: R% a7 d- ~- n/ M' l
# L) Y+ Q% N, X$ ~. U但运行时仍然出现相同的问题(提示:ox100f5e09指令引用的“ox00000028"内存。 该内存不能为"read"),无法运行。不知问题出现在哪里,请高手指点,多谢! |