谢谢shakie的耐心解释,我按照你的建议改了代码如下(并在window窗口定义了L_null);
' P# S4 o! {5 \4 G) r) abegin model initialization function
) ?1 W1 a# g: W& }; e create 1 load of load type L_null to P_Creation2
! G8 R" @. a$ d6 |; X/ h1 r create 1 load of load type L_null to P_Creation3
1 H" Y6 A/ d3 x- ~& H$ B+ i# q create 1 load of load type L_null to P_Creation4: G4 V4 X- c. M- E" N! e
return true 0 D. [: O' m8 B1 d5 q' `
end
# F$ T* t- ] y* I# U3 R! W* b, [) B8 V6 `9 ^; p2 e4 B% z; g7 h1 F
begin P_Creation2 arriving procedure6 ]) z* ~- H+ @
while 1=1 do' o3 C+ X. l; l; j$ N+ t& d
begin) R( N& V. T8 a X% c
wait for 1 sec
7 @9 f* h+ j l2 O1 [' p, d1 @9 ] create 1 load of load type L_C2 to oneof(0.2 _In2,0.8:die). Y+ Z; o. N# I* q9 m
end
% B: x2 a$ j( V) ~& X2 hend
4 Q$ P, C$ x; d
- G. V; `7 a; k6 ^8 Dbegin P_Creation3 arriving procedure
% `0 n9 @( k+ Q- ^8 o2 w8 Uwhile 1=1 do' J) @% Z9 T+ k9 D0 b
begin
" ?: ^4 ^9 b8 L8 N( T/ ?' F wait for 1 sec
' w) r# V" C2 i( B create 1 load of load type L_C3 to oneof(0.2 _In3,0.8:die). e! p" X7 P9 a5 T. x/ T- r5 }
end
8 t. J2 O' Z0 ], [: nend $ O" f6 p! Y3 r; }6 G
+ `) J! O* m: K4 p9 v" i
begin P_Creation4 arriving procedure( L- [9 A! Z: j0 s5 K1 _3 z
while 1=1 do
+ P0 A# ]4 _9 P; z, Y9 u( M- h begin0 e9 y _! a, z: \8 x2 p
wait for 1 sec3 j# S4 x: r0 w7 n2 G! q" t
create 1 load of load type L_C4 to oneof(0.2 _In4,0.8:die)$ \. S _7 a1 b# b
end
; u0 q# w; f/ m5 B4 N$ send
$ N, F0 W' I A
, \4 A! l) }" Y% W) M) ~但运行时仍然出现相同的问题(提示:ox100f5e09指令引用的“ox00000028"内存。 该内存不能为"read"),无法运行。不知问题出现在哪里,请高手指点,多谢! |