Hello all,
I’m in the process of designing an editor for an upcoming game where the player can build whatever they want to. What I’m trying to achieve is a wall editor where the wall will position itself along a selected edge, which means you don’t have to rotate the walls yourself.
For example, Retail Tycoon uses this system for its walls. They align along the closest edge to the mouse.
How can I get the closest edge of a part to the mouse and then position the wall on it?
I first thought of the idea of using multiple parts to represent the edges and the center, but this doesn’t seem like a good way to do it especially since there are ~ 1000 grid spaces, which would each have 5 parts = 5000 parts per plot (not very good)
The grid spaces are each 8 x 0.5 x 8, no rotation
Thanks in advance!