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

How to make a game pass give you custom gear/model?

Asked by 7 years ago

How to make a game pass give you custom gear/model because I want to make a first person shooter game 3:

0
what section like does it go under characterscripts or something else uq3i 5 — 3y

1 answer

Log in to vote
0
Answered by
xuefei123 214 Moderation Voter
7 years ago

Add the gun/model you want to give the player somewhere, I suggest serverstorage And use this code, ofc you have to edit it and such

local id = 000000--Edit this to your gamepass ID
local item = game.ServerStorage.Item--Edit this

game.Players.PlayerAdded:connect(function(player)
    if Game:GetService("GamePassService"):PlayerHasPass(player, id) then 
        local a = item:Clone()
    a.Parent = player.Backpack
    else
        print(player.Name .. " doesn't have the game pass...")
    end
end)

Hope this helped! If it did, don't forget to accept the answer, it gives us both rep

0
What do you mean by 'Edit this'? jonnyrocketfinger 5 — 7y
0
You have to change the id and the item, the item I defined is in serverstorage, but it may not be and it may be called something else xuefei123 214 — 7y
0
Hey Xuefei123 Everytime the player with the weapon die, the weapon stop spawn with him. agentep352 0 — 6y
Ad

Answer this question