0 votes

For my brick breaker game, I put all the bricks in a node. Every brick is the same scene, I just did a drag & drop .

For a super power, my ball should be able to destroy any brick without colliding(like a super ball). The problem is that even though I disable the collision for every brick, it is still colliding. The script doesn't work (when I did a print for collisionshape2d, it said that it isn't disabled.

I tried multiple approaches:
- since my bricks are all in a group, I tried to iterate through every brick and disable the collision. It didn't work
- I tried to attach a script to the scene and add a function named "collision". Then iterate again like the last time and stop the collision. It didn't work.
- I tried with are2D. It is a little complicated, I didn't manage (last time I managed something changed in code and it ruined everything. maybe I will do a different post about it)

I think with the signals I will have the same result. Do you know how can I do it ?

in Engine by (92 points)

maybe you could try having an area2d on your ball in a different layer then move the bricks to that layer so the area could enter and make the bricks destruct and the collision would not occur?

Please log in or register to answer this question.

Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read Frequently asked questions and How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to [email protected] with your username.