0 votes

Hello, is there a way to "stitch" smaller area2Ds together, in order to behave as one large area2D? I'm trying to implement "roof" scenes that the player can build with. These roof scenes are made up of a static body, with an area2D as a child. The roof itself is on another collision layer than the player, but the area2D will detect when the player is under the roof. If it detects a player, it becomes hidden. This part works perfectly. However, I also want every roof scene that makes up the entire roof (basically all roof scenes that are touching the roof scene that the player is under) to become hidden as well. Basically, I need the individual Area2D nodes of the different roof pieces to behave as one large Area2D. Any help is appreciated.

in Engine by (16 points)

I don't think "stitching" is possible without re-organizing the scene tree at run time, however my recommendation would be to extend the Area2D out so it can also touch the other roof scenes, and then connect a signal or use another method in order to make them all behave the same.

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 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 webmaster@godotengine.org with your username.