Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

how to search the whole server for a player with a certain tool in his backpack?

how to search the whole server for a player with a certain tool in his backpack? because the tool can be only with one player

like i want to search the whole server for that player and if that tool is in his backpack, then want to make that player a variable

1 answer

local players = game.Players:GetChildren()

for _, player in pairs (players) do
if player.Backpack:FindFirstChild("Tool") then
local PlayerWhichIsNeeded =  player
end
end

this might help you out but just see the capitals and all...

thanks!!

This discussion is preserved as it was. New answers, comments, and votes are closed.