谢谢shakie的耐心解释,我按照你的建议改了代码如下(并在window窗口定义了L_null);
9 @; k# o0 l5 u* W, B8 H& A/ Mbegin model initialization function' l5 L: K, }* B
create 1 load of load type L_null to P_Creation2
8 [1 F7 R9 y; j" B$ w* p) `6 P1 F5 _ create 1 load of load type L_null to P_Creation3
$ f6 K. w. \0 Y create 1 load of load type L_null to P_Creation4
) D$ q; |# W0 U2 H1 F return true
8 H: H9 X# B7 x) Y e6 Send* f2 z5 Z) I! e. e, K
* q8 ], [8 [4 G$ j
begin P_Creation2 arriving procedure
: v% q" i7 L' ] ]0 k$ ywhile 1=1 do0 G7 s1 W7 F1 Z. |) D
begin
1 x% i+ L7 ^% T% r: ?5 g% Y8 {! m7 Q wait for 1 sec7 U) h9 V- L+ h8 u& w' h
create 1 load of load type L_C2 to oneof(0.2 _In2,0.8:die)
' S" g9 V2 e8 I- n" m+ | N end
4 r/ H }, f$ K% z7 P1 wend
2 S i1 N: u: t- ?; f. d" V1 n- `9 y
begin P_Creation3 arriving procedure* r! T! ]. P2 o( t! p+ c. I
while 1=1 do: M3 w$ _" Q( a1 U/ r* N
begin
0 V: | _* R. b. Q3 S wait for 1 sec
/ e8 u. Z8 z9 I% N" H% r7 x create 1 load of load type L_C3 to oneof(0.2 _In3,0.8:die)' _: F, d# d3 ~
end2 A; ~4 U5 z' Y+ W2 s
end
# c' M) L$ J" e# a% v
" l# C( Y9 X8 h' n; Z3 |: k% Zbegin P_Creation4 arriving procedure
7 E3 F) ^9 H, q$ ywhile 1=1 do2 u" X! s( M, m# U( c* F
begin: N6 K G; F/ e% {9 L
wait for 1 sec
" V+ i! h# o9 [. I% ]: C) z create 1 load of load type L_C4 to oneof(0.2 _In4,0.8:die)
+ |3 w( Q3 f( |4 m2 L end
$ V5 j, K$ A! U, s, `end
: x5 z! ^4 }4 p8 h7 ^2 @2 K+ q$ \# {: V+ H! _/ h
但运行时仍然出现相同的问题(提示:ox100f5e09指令引用的“ox00000028"内存。 该内存不能为"read"),无法运行。不知问题出现在哪里,请高手指点,多谢! |