local groupid = 3897722 game.Players.PlayerAdded:Connect(function(player) if player:GetRankInGroup(groupid) >= 249 then script.Parent.CanCollide = false script.Parent.Parent.card.Value = true end end)
Help!
Hi there! You changed it to a localscript according to the comments. Local scripts don't work in the workspace. They only work in the Player service, tools with exceptions, and the replicated storage I think. There's an easy fix to your issue.
I have no idea what the hierarchy or name of script.Parent is so for this example, we will use workspace.Part.PartChild. Change it to whatever yours is.
Make sure the script below is a local script.
local groupid = 3897722 game.Players.PlayerAdded:Connect(function(player) if player:GetRankInGroup(groupid) >= 249 then workspace.Part.PartChild.CanCollide = false workspace.Part.card.Value = true end end)
Make sure the above script is in the StarterCharacterScripts or the StarterGui.
Good luck!