This script that is meant to add followers wont work. Any fixes?
game.Players.PlayerAdded:Connect(function(plr) if Workspace.StarterItemsUpgraded.StarterMonitorUpgraded.ScreenGui.Enabled == true then wait(math.random(1, 2)) plr.leaderstats.Followers.Value = plr.leaderstats.Followers.Value + 1 elseif plr.leaderstats.Followers.Value >130 then plr.leaderstats.Followers.Value = plr.leaderstats.Followers.Value + math.random(1,2) elseif plr.leaderstats.Followers.Value >250 then plr.leaderstats.Followers.Value = plr.leaderstats.Followers.Value + math.random(1,3) elseif plr.leaderstats.Followers.Value >350 then plr.leaderstats.Followers.Value = plr.leaderstats.Followers.Value + math.random(1,4) elseif plr.leaderstats.Followers.Value >410 then plr.leaderstats.Followers.Value = plr.leaderstats.Followers.Value + math.random(2,4) elseif plr.leaderstats.Followers.Value >500 then plr.leaderstats.Followers.Value = plr.leaderstats.Followers.Value + math.random(2,5) elseif plr.leaderstats.Followers.Value >600 then plr.leaderstats.Followers.Value = plr.leaderstats.Followers.Value + math.random(2,6) elseif plr.leaderstats.Followers.Value >700 then plr.leaderstats.Followers.Value = plr.leaderstats.Followers.Value + math.random(2,7) elseif plr.leaderstats.Followers.Value >775 then plr.leaderstats.Followers.Value = plr.leaderstats.Followers.Value + math.random(3,7) elseif plr.leaderstats.Followers.Value >845 then plr.leaderstats.Followers.Value = plr.leaderstats.Followers.Value + math.random(3,8) elseif plr.leaderstats.Followers.Value >950 then plr.leaderstats.Followers.Value = plr.leaderstats.Followers.Value + math.random(3,9) elseif plr.leaderstats.Followers.Value >1150 then plr.leaderstats.Followers.Value = plr.leaderstats.Followers.Value + math.random(3,10) elseif plr.leaderstats.Followers.Value >1450 then plr.leaderstats.Followers.Value = plr.leaderstats.Followers.Value + math.random(3,11) elseif plr.leaderstats.Followers.Value >1750 then plr.leaderstats.Followers.Value = plr.leaderstats.Followers.Value + math.random(3,12) elseif plr.leaderstats.Followers.Value >2000 then plr.leaderstats.Followers.Value = plr.leaderstats.Followers.Value + math.random(4,12) elseif plr.leaderstats.Followers.Value >2300 then plr.leaderstats.Followers.Value = plr.leaderstats.Followers.Value + math.random(4,13) end end)
its because your doing:
Workspace.StarterItemsUpgraded.StarterMonitorUpgraded.ScreenGui.Enabled
and ScreenGui
s are not 3D, they are 2D on the players screen not in the 3D world, so instead use SurfaceGui
s. Also the global variable of workspace shouldnt be capitalized, since thats for the datamodel of workspace game.Workspace