|
| 18 Aug 2016 09:36 AM |
Since I am very new at scripting, I need some help on making a tool that allows people (who acquire the tool) to delete decals and not bricks.
|
|
|
| Report Abuse |
|
|
|
| 18 Aug 2016 09:41 AM |
game.Workspace.Part.ClickDetector.MouseClick:connect(function() if part:FindFirstChild('decal') then decal:Remove() hope this help |
|
|
| Report Abuse |
|
|
|
| 18 Aug 2016 10:39 AM |
| Doesn't work. May be an error on my part. Im trying to replace the script currently on a delete model hammer. Do I use a local script or a script? |
|
|
| Report Abuse |
|
|
|
| 18 Aug 2016 10:40 AM |
regular script since we are not dealing with local players unless u r
|
|
|
| Report Abuse |
|
|
|
| 18 Aug 2016 10:41 AM |
| don't copy and paste my code do It with the variables changed to what they need to be. |
|
|
| Report Abuse |
|
|
|
| 18 Aug 2016 10:43 AM |
| Problem is there aren't specific variables. It is meant to delete NSFW decals in certain games. |
|
|
| Report Abuse |
|
|
|
| 18 Aug 2016 10:50 AM |
well then do local child = game.Workspace.Part:FindFirstChild() if child.className == 'Decal' then child:Remove() |
|
|
| Report Abuse |
|
|
|
| 18 Aug 2016 12:15 PM |
Here is what I did:
local child = game.Workspace.Part:FindFirstChild('Decal') if child.className == 'Decal' then child:Remove('Decal')
I'm not the smartest person in the world. I make lots of mistakes, lol.
|
|
|
| Report Abuse |
|
|
|
| 18 Aug 2016 12:16 PM |
| That is exactly what I told u except I forgot to tell it what name to remove |
|
|
| Report Abuse |
|
|
|
| 18 Aug 2016 12:21 PM |
What name do I remove then?
|
|
|
| Report Abuse |
|
|
| |
|
|
| 18 Aug 2016 08:24 PM |
local object = place:findFirstChild("name") if object then object:Destroy() end |
|
|
| Report Abuse |
|
|