擅长:python、mysql、java
<p>很明显,你有一个函数,它检查是否发生了碰撞,返回-1?我不知道。但我的想法是:试着让你的功能看起来像这样:</p>
<pre><code>int IsCollision( "all your variables" + int n) { // n = the current rect's number
if ("collision" == true) {
return n;
} else {
return 0;
}
}
</code></pre>
<p>当然,现在您需要将另一行更改为:</p>
^{pr2}$