local player1 = script.Parent local trail = game.ReplicatedStorage.TrailMachine mps= game:GetService("MarketplaceService") function createMachine() local trailClone = trail:Clone() trailClone.PrimaryPart = trailClone.Core trailClone.Parent = player1 trailClone:moveTo(player1.Torso.Position) local weld = Instance.new("Motor6D") weld.Parent = trailClone.Core weld.Part0 = trailClone.Core weld.Part1 = player1.Torso end game:GetService("Players").PlayerAdded:Connect(function(player) if mps:UserOwnsGamePassAsync(player.UserId,5260848) then createMachine(player) end end)
Even though I tested it in the place, and since I'm the owner I have the gamepass, it still didn't make the model. Maybe this is because the place is private and only I can play it?
And you put it in ServerServiceScript
local trail = game.ReplicatedStorage.TrailMachine local mps = game:GetService("MarketplaceService") game:GetService("Players").PlayerAdded:Connect(function(player) if mps:UserOwnsGamePassAsync(player.UserId,5260848) then local function createMachine() local trailClone = trail:Clone() trailClone.PrimaryPart = trailClone.Core trailClone.Parent = player.Character trailClone:moveTo(player.Torso.Position) local weld = Instance.new("Motor6D") weld.Parent = trailClone.Core weld.Part0 = trailClone.Core weld.Part1 = player.Character.Torso end createMachine(player) end end)