How can i detect collisions for my placement system?

  1. What do you want to achieve? Keep it simple and clear!
    I want to make it so that when im in placing mode the viewmodel won’t be abke to go into any parts at all and if it goes into a part the viewmodel turns red and if its inside of no parts then it turns green indicating that you can place it. I want all of this to be controlled in a local script.

  2. What is the issue? Include screenshots / videos if possible!
    I don’t know how to do it because i’m not familiar with region3 or get touching parts.

  3. What solutions have you tried so far? Did you look for solutions on the Developer Hub?
    I have tried YT and Devforum, nothing.

You could use Raycasting, with that you can return the region3/terrain / parts hit. Would require 3 dimensions to make sure every side is covered.

Ok, but the thing is, is that i dont want it so that the whole part needs to be covered, just at least one side. So if a bit of it is sticking into another part then it gets turned to red

Then just raycast on that one side boom
is this the bottom ?

Im not familiar with raycasts and i would like to do it with something like gettouchingparts

You can make a “for loop” that goes through the number of objects touching using GetTouchingParts() or GetPartsInPart() and if its 0 then you can place it.