谢谢shakie的耐心解释,我按照你的建议改了代码如下(并在window窗口定义了L_null);
6 G& y5 E& ?3 C0 mbegin model initialization function) _8 v/ [: w6 S8 Y- J9 J
create 1 load of load type L_null to P_Creation2
4 X, c8 B7 b3 t8 A$ X create 1 load of load type L_null to P_Creation32 G2 D, @9 c, k* R3 @
create 1 load of load type L_null to P_Creation4$ j1 z2 G j. i8 H5 Y
return true ( ]( l. z1 f/ Y2 z4 C
end
6 ^, u1 x% _/ l6 r) l5 C7 d3 O8 ]: o9 @
begin P_Creation2 arriving procedure
& I! e+ G+ F. Q' w `+ D- ewhile 1=1 do! m% ]6 f" C, ^# R& C
begin' B4 O+ a5 D ]/ B1 A
wait for 1 sec
% ` W8 T1 x$ X* d+ z- D2 g create 1 load of load type L_C2 to oneof(0.2 _In2,0.8:die)
' o0 t. {& o' M, H end
; O! E- o6 m! C6 B; ^ [% ?, \end& s) v/ m H6 ~7 N6 M% Y& T3 Y
$ w' I3 r4 ?" ~begin P_Creation3 arriving procedure
' M; P Z" G9 \$ lwhile 1=1 do' ^$ @# P* Y2 [6 R8 F6 t$ ^! f& t8 T
begin4 s1 _9 T2 R: M, [3 \4 G
wait for 1 sec g* d9 N% G& O. R; l, \2 `
create 1 load of load type L_C3 to oneof(0.2 _In3,0.8:die)" x7 a( C7 }2 X1 R0 E
end
) {; T4 z3 L4 C8 gend : R# H# w+ s6 ~) J1 r5 P! y
: R7 _3 l$ M4 ^+ ?( R4 K
begin P_Creation4 arriving procedure5 \0 J% B# c3 L/ g1 M: x! Y
while 1=1 do
4 u# E, W% L& O* n5 V0 L% e begin
2 G; p; b8 a8 c. ?% E { wait for 1 sec/ f ^8 V5 z* U2 M. W
create 1 load of load type L_C4 to oneof(0.2 _In4,0.8:die)
4 g( X5 u( y! K E7 @ end
' ~ V) R: D! T; q3 eend
8 b, q7 h% z A$ D& C
4 c8 C7 l4 A- W: E7 _& {' }但运行时仍然出现相同的问题(提示:ox100f5e09指令引用的“ox00000028"内存。 该内存不能为"read"),无法运行。不知问题出现在哪里,请高手指点,多谢! |