local PP = Instance.new("ProximityPrompt")
PP.Parent = PetInfo.PrimaryPart
PP.ActionText = "Buy"
PP.Enabled = true
PP.ClickablePrompt = true
PP.Name = "BuyPrompt"
Thats my sever script
local PetsFolder = game.Workspace:WaitForChild("PetsFolder")
local RSS = game:GetService("ReplicatedStorage")
local PetsModule = require(RSS.Pets)
local PRE = RSS:FindFirstChild("Purchase")
PetsFolder.ChildAdded:Connect(function(Pet)
local PetPrimaryPart = Pet:WaitForChild(Pet.Name)
local PP = PetPrimaryPart:WaitForChild("BuyPrompt")
print("Child added")
PP.Triggered:Connect(function()
game.ReplicatedStorage.Purchase:FireServer(Pet.Name)
print("PP")
end)
end)
And thats my local script
** You are now Level 4! **