So I’m making a cuff system, and I need to somehow detect if the person arresting rank is <= target’s rank, and what I mean by rank is just roblox Teams.
if things.Attack == "Arrest" then
if not CharState and not TargetState then
ServerFunctions.SetCharState({Character = Character, State = "HasArrested", Duration = math.huge})
ServerFunctions.SetCharState({Character = Target, State = "Arrested", Duration = math.huge})
if TargetPlayer ~= nil then
ClientEffects:FireClient(TargetPlayer, "BackpackToggle", {Phase = true, Player = TargetPlayer})
EnemyHuman:UnequipTools()
else
EnemyHuman:UnequipTools()
end
weld(OriginRoot, TargetHumrp, CFrame.new(1.5,0,-3))
end
This is not finished obviously, but im just tryna see how i would make a function checking priorities of teams, and by that disable / enable the person arresting the target.