Hi!
My scripter has been unable to fix some of the errors with the code he produced for me so I figured perhaps someone on here may be able to help?
> local Event = game.ReplicatedStorage:WaitForChild("UpdateIslandBuxUI")
>
> game.Players.PlayerAdded:Connect(function(player)
> local IslandBux = player:WaitForChild("IslandBuxValues").IslandBux.Value
> local function sendData(player)
> Event:FireClient(player,IslandBux)
> end
> sendData(player)
> if player:IsInGroup(3221347) then
> for addIslandBux = 0,-1,1 do
> print("Island Bux running (in group)")
> wait(300)
> IslandBux += 5
> sendData(player)
> end
> else
> for addIslandBux = 0,-1,1 do
> print("Island Bux running (not in group)")
> wait(300)
> IslandBux += 10
> sendData(player)
> end
> end
> end)
If the player is in the group, they are supposed to receive 10 island bux per 5 minutes spent in game, whereas if they are not, they receive 5 island bux per 5 minutes.
The total remains the same regardless of the time that the player spends in game?
Thank you all in advance 