Object Placer | Placing objects on rotated parts / terrain

Hello. This is my first topic here so please bare with me.


I have this Plugin called Object Placer. Please read this to get to know what i am about to say.

I want to add a new feature so that Objects can be placed ontop of objects that are rotated and on terrain if possible.


This is what i want to achieve:

This is what is happening:

Heres a Snippet of the Movement Script. Please say if you require more snippets.


I’ve tried researching it but i found nothing helpful. I’ve also tried experimenting and failed.

Thanks

2 Likes

Are all the surfaces pointing in a particular way for example are all the top surfaces pointing outward bc that would make it a lot easier bc you could do something like

game.Workspace.Part1.CFrame = game.Workspace.Part2.CFrame:ToWorldSpace()

which would rotate it correctly but you would just need to add a offset into the :ToWorldSpace() argument to make sure the part sat on top off it.
yea sorry i did’t read the script and if you have already done this but yea.

1 Like

I’ll try it out. If it works i’ll mark you as the Solution.
Thanks anyway.

Also the Object being placed surfaces aren’t in specific directions. Nor the parts i’m placing onto.
I want it so it can find a direction to rotate along the Z and X axis only.

probs not the best way but the mouse has a property called
mouse.TargetSurface which will give you the NormalID of the surface the mouse is hitting and you could do an a load of if statements checking for which one then offsetting in that direction from the top of it.