I am trying to rotate these booths based on the front red line to match inside of the box. Although, I am not sure how to rotate the entire model inside of the square. I tried to work with orientation but didn’t see a good outcome. Can anyone help me with this?
Current Script (the model is named Folder):
game.Players.PlayerAdded:Connect(function(player)
local Booth = game.ServerStorage:WaitForChild("Folder"):Clone()
Booth.Parent = game.Workspace
local children = Booth:GetChildren()
Booth:MoveTo(game.Workspace.Booth12.Front.Position)
local children = Booth:GetChildren()
for i, child in ipairs(children) do
child.Position = child.Position + Vector3.new(-4.5, 0, -5)
end
end)
game.Players.PlayerAdded:Connect(function(player)
local Booth = game.ServerStorage:WaitForChild("Folder"):Clone()
Booth.Parent = game.Workspace
local children = Booth:GetChildren()
Booth:MoveTo(game.Workspace.Booth13.Front.Position)
local children = Booth:GetChildren()
for i, child in ipairs(children) do
child.Position = child.Position + Vector3.new(-4.5, 0, -5)
child.Orientation = game.Workspace.Booth13.Front.Orientation
end
end)
This is the basic first part of this script:
This is what the booth looks like with the orientation added (second part):
Any help is really appreciated!