How to make your own particle game pass?
Asked by
7 years ago Edited 7 years ago
I am trying to create my own particle for players to buy a gamepass and get.
I have the premade particles from roblox working.
Script:
01 | local passId = 000000000 |
03 | function isAuthenticated(player) |
04 | return game:GetService( "MarketplaceService" ):PlayerOwnsAsset(player, passId) |
07 | game.Players.PlayerAdded:connect( function (plr) |
08 | if isAuthenticated(plr) then |
09 | plr.CharacterAdded:connect( function (char) |
10 | local Trail 1 = Instance.new( "Sparkles" ) |
11 | Trail 1. Parent = char:WaitForChild( "Left Leg" ) |
12 | local Trail 2 = Instance.new( "Sparkles" ) |
13 | Trail 2. Parent = char:WaitForChild( "Right Leg" ) |
And I have created my custom particle and placed it in replicated storage, I used this script to test it for when I touch a block.
01 | local rs = game:GetService( "ReplicatedStorage" ) |
04 | local ee = rs.ParticleEmitter:Clone() |
06 | if hit.Parent.Torso:FindFirstChild( "ParticleEmitter" ) then |
07 | hit.Parent.Torso.ParticleEmitter:remove() |
09 | ee.Parent = hit.Parent.Torso |
12 | script.Parent.Touched:connect(onTouch) |
But no I am trying to make it so that you get my custom particle when you purchase a gamepass, this is what I have so far, and I am not sure what to do from now.
1 | local passId = 000000000 |
3 | function isAuthenticated(player) |
4 | return game:GetService( "MarketplaceService" ):PlayerOwnsAsset(player, passId) |
7 | local particles = game.ReplicatedStorage.Particles |
8 | game.Players.PlayerAdded:connect( function (plr) |
9 | if isAuthenticated(plr) then |
Any help would be much apreciated thank you :)