|
| 09 Jun 2013 10:08 AM |
So I need a script where when you touch the block it takes a certain Gear from you. So far I have this.
for i, v in pairs (Roblox.IDKTHIS.Inventory:children()) do if v:IsA("Darkheart") then v.Parent = Roblox.IDKTHIS.Inventory end end
I need it so it takes it from the players inventory and gets rid of it... (I stink at scripting)
¤ᶯᶸᶩᶩᶬ¤ |
|
|
| Report Abuse |
|
|
|
| 09 Jun 2013 10:21 AM |
part.Touched:connect(function(hit) if (hit and hit.Parent) then local player = game.Players:FindFirstChild(hit.Parent.Name) if (player) then local darkHeart = player.Backpack:FindFirstChild("Darkheart") if (darkHeart) then darkHeart:Destroy() end end end end)
Wiki Profile: http://wiki.roblox.com/index.php/User:Nelson |
|
|
| Report Abuse |
|
|
|
| 09 Jun 2013 10:57 AM |
I just change darkheart to The gear I want right...
¤ᶯᶸᶩᶩᶬ¤ |
|
|
| Report Abuse |
|
|
|
| 09 Jun 2013 01:31 PM |
Yup.
Wiki Profile: http://wiki.roblox.com/index.php/User:Nelson |
|
|
| Report Abuse |
|
|
| |
|
|
| 09 Jun 2013 02:34 PM |
^ What was the point of posting that?
Wiki Profile: http://wiki.roblox.com/index.php/User:Nelson |
|
|
| Report Abuse |
|
|