谢谢shakie的耐心解释,我按照你的建议改了代码如下(并在window窗口定义了L_null);
7 _1 H [# [/ B; ?begin model initialization function3 e5 K0 V, E2 V% B5 }
create 1 load of load type L_null to P_Creation2. |" c0 x4 V8 M: W' t% V4 P: g
create 1 load of load type L_null to P_Creation3
5 [6 B- C% A4 m- h, S create 1 load of load type L_null to P_Creation4
9 h) v7 F& [' r% i, I return true / i, C8 W9 f k% s
end; F. ]) W& M" H, c5 n1 E; b
2 N0 A1 O5 H! w5 y- G
begin P_Creation2 arriving procedure
# \: a( w: L+ s$ a) q Dwhile 1=1 do: W! k% _# b0 X
begin
, D+ ]; `9 { y+ w' [ wait for 1 sec5 }! v% P: m ^- d
create 1 load of load type L_C2 to oneof(0.2 _In2,0.8:die)
9 G& ^& C( \3 p8 _5 Z( L* ^' W end0 E7 H3 f9 X5 y4 @; r
end) K/ Y) g' B, b \
) b) @( X& {6 |* `begin P_Creation3 arriving procedure# k n4 N8 D+ ` j l
while 1=1 do" v! Z5 @$ F* k5 P) @3 Q' g
begin6 J8 d4 a, i$ J" b3 r
wait for 1 sec
4 e/ M5 c$ M& G create 1 load of load type L_C3 to oneof(0.2 _In3,0.8:die)
! [; a# k: {3 Y# g2 V; C, v end) p- h9 h$ p+ H, |
end
! C3 P. F* ~: q5 b
% ~( Y" a# p3 n `, Q& s) J4 o/ ?begin P_Creation4 arriving procedure
/ q1 {, Y3 |" N% e8 o0 owhile 1=1 do
' v& l& I s5 c7 s+ n1 z9 W begin
3 \( w/ n' I3 F wait for 1 sec
; M% w% f: L( q create 1 load of load type L_C4 to oneof(0.2 _In4,0.8:die)
$ E0 P Z0 I0 o( W% _$ p+ x2 [ end& E. B( o+ a* e2 Y
end
1 O7 r2 L% C% ?& F0 |% z% `1 U: K' x# Z- M3 Z& G, x; d9 P
但运行时仍然出现相同的问题(提示:ox100f5e09指令引用的“ox00000028"内存。 该内存不能为"read"),无法运行。不知问题出现在哪里,请高手指点,多谢! |