I have been working on a gate, and I was wondering how I can have this gate pivot around the red part when it opens.
This is the part of code that I have for this gate, but it pivots the gate in the center instead of on the side. How would I go about changing my current code to allow for the gate to pivot on the right side(where the red part is) to allow for players to pass through?
This has already been answered on this site, please research before posting.
You have to multiply three things in a certain order.
Rotation * Pivot + Point
Rotation is the rotation you want, Pivot is the relative CFrame between the part and the part you’re rotating around, and point is the CFrame of the part you’re rotating around.