Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

can someone help me with this tool for Rogue?

Asked by 9 years ago

okay, so i have been working on a touch tool and it works ... but not fully when i get someones tool, it takes it away from the other player even though it should just clone it into my backpack and leave it in the the other players as well maybe one of you can find my mistake

01bin=script.Parent
02 
03function onButton1Down(mouse)
04    mouse.Icon = "rbxasset://textures\\GunWaitCursor.png"
05    local hit = mouse.Target
06    if (hit ~= nil) then
07        humanoid = hit.Parent:findFirstChild("Humanoid")
08        if (humanoid ~= nil) then
09            children = hit.Parent:children()
10            for i=1,#children do
11                if (children[i].className == "Tool", "HopperBin") then
12                    children[i].Parent = bin.Parent.Parent.Backpack
13                end
14            end
15        end
View all 27 lines...

1 answer

Log in to vote
0
Answered by
Codebot 85
9 years ago

on line 9 its

1children = hit.Parent:GetChildren()
0
ok thank you FinickOdre123 6 — 9y
0
well i did it but the other person still lost thier tool D: i dont want that ... is there a way so the other person keeps it? and i still get it FinickOdre123 6 — 9y
Ad

Answer this question