谢谢shakie的耐心解释,我按照你的建议改了代码如下(并在window窗口定义了L_null);
& G* v& F) H9 {' Z mbegin model initialization function) M( A3 `( [0 D8 s
create 1 load of load type L_null to P_Creation2
9 Z7 c% k- _6 v* \* n, m3 j create 1 load of load type L_null to P_Creation3, y( @7 }2 S* |. i L7 O; w, Q% p- U
create 1 load of load type L_null to P_Creation4
3 a& a/ w) {( l5 h! d5 S; M return true ! k. D& d8 J" Z6 `4 E# H9 W" C
end
) |, I! A0 X {, K4 B9 y/ L9 r$ g) @! C* q) B
begin P_Creation2 arriving procedure
% Q$ B. @, O5 w; owhile 1=1 do: D( T$ r! E7 _
begin% x. Z# Q4 n" o- \/ \, P
wait for 1 sec
$ c; }/ e r1 I) O- c. }3 Z create 1 load of load type L_C2 to oneof(0.2 _In2,0.8:die). r$ ?, E. O7 X# |9 n# T
end
# H' L9 p, e2 a! ?* k |1 o* Nend
& r8 n9 i! n% A
5 p5 I/ w" O$ ~+ @' Bbegin P_Creation3 arriving procedure
' C: _* V8 s# j- J3 A/ L* Owhile 1=1 do
+ j9 M+ k2 z) y7 X$ w, Y begin
) ^6 U, [. c H- X1 a2 { wait for 1 sec
* F% M/ S$ a& J: R create 1 load of load type L_C3 to oneof(0.2 _In3,0.8:die)
, Y* B- ?" D: ^; ?, I+ M4 k end
0 X7 ~# d" q f1 z$ t% C" Y9 R- q yend
; {4 _( s9 J, X, x- c3 h
- W" T- Y2 T! T, i2 r& [0 G# ibegin P_Creation4 arriving procedure7 R5 l7 m' f" x8 W
while 1=1 do5 j3 Q4 ?( n, R2 O" o& ^
begin
" O* s" w3 B& @) J) [ wait for 1 sec
; O D( W1 e6 ~4 d! g+ D: r create 1 load of load type L_C4 to oneof(0.2 _In4,0.8:die)
# g+ D; H) W/ q9 c% C end% a t8 ~& B+ I0 w
end
: Q4 T: P3 T- y7 ^+ d: p4 E2 z, D* P/ x1 t- c2 E: V
但运行时仍然出现相同的问题(提示:ox100f5e09指令引用的“ox00000028"内存。 该内存不能为"read"),无法运行。不知问题出现在哪里,请高手指点,多谢! |