Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How to make gamepass that gives the player faster walking speed?

Asked by 1 year ago
Edited 1 year ago

local gampass_id = 35168372

script.Parent.MouseButton1Click:Connect(function() game:GetService("MarketplaceService"):PromptGamePassPurchase(game.Players.LocalPlayer, gampass_id)

end)

1 answer

Log in to vote
0
Answered by 1 year ago

If you want to make a gamepass for speed use this

game.Players.PlayerAdded:Connect(function(plr)

local speed = 30

 wait(1)
 local ownsGamepass = game:GetService("MarketplaceService"):UserOwnsGamePassAsync(plr.UserId, 35168372)

 if ownsGamepass then
  plr.Character.Humanoid.WalkSpeed = speed
 end

end)

I think that's how it works..

0
it doesn't, but thx for effort komanos212 2 — 1y
0
What does the error say? tyfftjftgdchgf 17 — 1y
0
nothing, it just doesnt work komanos212 2 — 1y
0
wait, is there error panel or somthin? How to see errors? komanos212 2 — 1y
View all comments (8 more)
0
Go to the View Tab and Output tyfftjftgdchgf 17 — 1y
0
it says nothing komanos212 2 — 1y
0
i tried and tried but nothing is in the errors. Only when i delete ) from the ,,end" from my script, but then i can't click my button and this is probably why the error shows. komanos212 2 — 1y
0
or no wait there is something. 21:04:48.614 MarketplaceService:PromptGamePassPurchase() player should be of type Player - Server - Script:3 komanos212 2 — 1y
0
i've put it in script instead of local script. komanos212 2 — 1y
0
can u help me plzzzz komanos212 2 — 1y
0
That error means that you didn't send the gamepass purchase correctly. You need to send the player Instance and the game pass's ID in order to correctly prompt a purchase. SpiritualSonicdash 67 — 1y
0
how to do that? komanos212 2 — 1y
Ad

Answer this question