これは非常に単純な質問のように思えるかもしれませんが、私はかなり混乱しています。多くの条件を含む if 条件があり、この場合に使用する括弧の構文がわかりません。この場合、または if ステートメントに多くの条件がある他の場合の適切な構文を理解する方法について、誰かヒントを教えてもらえますか? ありがとう!
void collisionEn() {
for (int i = 0; i < myPlats.length; i++) {
if (posEx > myPlats[i].xPos)
&& (posEx+wEx > myPlats[i].xPos)
&& (posEx+wEx < myPlats[i].xPos + myPlats[i].platWidth)
&& (posEx < myPlats[i].xPos + myPlats[i].platWidth)
&& (posEy > myPlats[i].yPos)
&& (posEy < myPlats[i].yPos + myPlats[i].platHeight)
&& (posEy+wEy > myPlats[i]yPos)
&& (posEy+wEy < myPlats[i].yPos + myPlats[i].platHeight)
rect(0, 0, 1000, 1000);