1 | spawn(function() |
2 | while _G.abc3 do wait() |
3 | local player = game.Players.LocalPlayer |
4 | local auto_grab = workspace.Powerups |
5 | local playerCharacter = player.Character |
6 | task.spawn(function() |
7 | if playerCharacter then |
8 | local playerPosition = playerCharacter:FindFirstChild("HumanoidRootPart") |
9 | if playerPosition then |
10 | playerPosition = playerPosition.Position |
11 | for _, NPC in pairs(auto_grab:GetChildren()) do |
12 | local NPCRootPart = NPC:FindFirstChild("Part") |
13 | if NPCRootPart then |
14 | NPCRootPart.Position = playerPosition |
15 | end;end; |