local Players = game:GetService("Players")
local MPS = game:GetService("MarketplaceService")
Players.PlayerAdded:Connect(function(Plr)
Plr.CharacterAdded:Connect(function(char)
local Humanoid = char:WaitForChild("Humanoid")
if MPS:UserOwnsGamePassAsync(Plr.UserId, YOURIDHERE) then
Humanoid.WalkSpeed = Humanoid.WalkSpeed * 2
end
end)
end)
local MPS = game:GetService("MarketplaceService")
Players.PlayerAdded:Connect(function(Plr)
Plr.CharacterAdded:Connect(function(char)
local Humanoid = char:WaitForChild("Humanoid")
if MPS:UserOwnsGamePassAsync(Plr.UserId, YOURIDHERE) then
Humanoid.WalkSpeed *= 2
end
end)
end)
It doesnât work because youâre only doubling your walkspeed when the player spawns. You need to double it in your speed script (the one where you determine & update the playerâs speed).
What you should do instead is have a speed multiplier. A normal player would have a multiplier of 1, while a player with the gamepass would have a multiplier of 2.
When you update the playerâs speed, you should take this into account by multiplying the playerâs speed by the multiplier.