I know clearly how to open a door with a UI button, with a click detector i can use the TweenService to create a similar animation, But something that always got me wonder is how can i know on wich side is the player?, Like on this GIF, this script know on wich side the door got to open. I am kinda dull with all stuff that use CFrame, ive took some time to read the wiki again and again. Can someone help me with this subject? i dont want to remake the same door, i only need a "exemple" netheir a script already maked, only something to get me on the road of that subject.
local PlayerMagnitude = (Part.Position - Player.Character.HumanoidRootPart.Position).magnitude