Why does my walkspeed gamepass not work?

I have tried to make a walkspeed gamepass but it doesnt work

local players = game:GetService("Players")
local MarketPlaceService = game:GetService("MarketplaceService")
local GamepassID = 26411242

players.PlayerAdded:Connect(function(player)
	player.CharacterAdded:Connect(function(Character)
		local Humanoid = Character:WaitForChild("Humanoid")
		local GamepassID = 26411242
		
		if MarketPlaceService:UserOwnsGamePassAsync(player.UserId, GamepassID) then
			Humanoid.WalkSpeed = 32
		end
	end)
end)

Are you sure you own the gamepass in the script? I don’t see anything wrong with it.

Also you made the gamepass variable two times, one is already enough.

1 Like