谢谢shakie的耐心解释,我按照你的建议改了代码如下(并在window窗口定义了L_null);
! s1 E) U+ X2 L6 I* ubegin model initialization function
9 j- s( J6 p" F' N' d. L create 1 load of load type L_null to P_Creation2/ p, z: G: n. _& ]
create 1 load of load type L_null to P_Creation3" n" r& V4 N7 e" n, a
create 1 load of load type L_null to P_Creation4
# _- N$ F* f B p9 h+ @ return true . o: {# Y4 m* S. r" e
end" W( n. V A2 X; H# W
3 M4 X1 }4 X' H* o: _
begin P_Creation2 arriving procedure- o# R4 w5 O) o8 }& l% o. ]
while 1=1 do( [9 h7 \. @" ~$ p, _) m
begin" O' q" ^/ Z# Z& a: i6 L' R" F3 B
wait for 1 sec j5 |6 F1 s4 q1 i' n% P
create 1 load of load type L_C2 to oneof(0.2 _In2,0.8:die)' V& m- z6 i6 i/ n8 M8 c {
end
M6 K; _% y$ l6 jend* _4 F( v" f8 s. o7 x: z. p4 n
I1 F1 ^5 {5 S. v+ H0 p
begin P_Creation3 arriving procedure' E9 z8 J) I1 d+ q3 g
while 1=1 do
& m# H1 w4 f! j/ f+ b( [3 o# {9 q begin
- q6 Z) L! o, U4 X2 ^6 ^# M. U wait for 1 sec
& C* V* o+ @4 k create 1 load of load type L_C3 to oneof(0.2 _In3,0.8:die)& Y g+ d2 |% k0 }5 Z- D
end
( m" w% o5 E, x; G. pend * T a! \7 u7 E: [1 P* y
) q+ w- o, b3 u ^! B+ kbegin P_Creation4 arriving procedure+ b) d% r+ A2 p6 P! |2 ?
while 1=1 do; q ~% {; q* A/ `$ F
begin9 N% g! e' ]4 ~' G4 y1 W9 G0 | O$ k" J
wait for 1 sec+ c% R/ s, z5 i
create 1 load of load type L_C4 to oneof(0.2 _In4,0.8:die)0 v# B4 c, g. G
end5 P0 Z0 c- i& }! q: e, n! s
end8 ]8 q, y/ ?$ i* Z b$ |3 i
. M4 R+ t- T, W8 j8 C
但运行时仍然出现相同的问题(提示:ox100f5e09指令引用的“ox00000028"内存。 该内存不能为"read"),无法运行。不知问题出现在哪里,请高手指点,多谢! |