How do I make an auto collect cash gamepass for my tycoon?

Wdym? Why would I put it where you redeem the cash

Nevermind, im stupid and did not understand

Im not 100% sure
But what about
if GamepassID == numberofyourgamepass then
(also local the GamepassID)

Thanks for that, but where do I put that

Not sure, as scripter im horrible, maybe try asking someone else there, sorry and good luck xD

What about this tutorial? How To Make An AUTOCOLLECT CASH Tycoon Script in ROBLOX Studio - YouTube

I already stated that the only video I could find tells you how to make the script in general, I’m trying to make it a gamepass. In witch this video wont help.

Anyways, can somebody help me with this I really don’t know what to do.

Oops, sorry I forgot about it.
Change the gp id.
This is the main script, you still have to use the subscript.

wait(2)
local mps = game:GetService("MarketplaceService")
workspace:WaitForChild(“PartStorage”)
local player --get the associated player with the redeem place.
while true do
wait(2)
local part = Instance.new(“Part”,workspace.PartStorage)
local gpId = 123456 --change this
if mps.UserOwnsGamePassAsync(player.UserId,gpId) then
local script = Script.Script
script.Parent = part 
script.Disabled = false
end
part.BrickColor=script.Parent.Parent.Parent.DropColor.Value
part.Material=script.Parent.Parent.Parent.MaterialValue.Value
local cash = Instance.new(“IntValue”,part)
cash.Name = “Cash”
cash.Value = 25
part.CFrame = script.Parent.Drop.CFrame - Vector3.new(0,1.4,0)
part.FormFactor = “Custom”
part.Size=Vector3.new(1.2, 1.2, 1.2)
part.TopSurface = “Smooth”
part.BottomSurface = “Smooth”
game.Debris:AddItem(part,20)
end

A few things, on the second script. What do I put next to “player =” sorry, I’m just REALLY bad at scripting. Also, where do I put the script? ServerScriptService?

Hey there! Don’t feel bad that you’re bad at scripting, it takes time to learn, I believe you’ll get better soon.

Also as for your question, you have to save the player as an object value when he claims an tycoon spot. Which means you’ll be storing which player is associated to which tycoon, and you’ll be using that objvalue.Value to get the player and be using that on the script.

Alternatively we can skip this whole process and just use a local script with a remote event, but that would make the game vulnerable to exploits.

Hey there,
are you still having trouble with this?

1 Like