|
| 27 Jun 2013 09:19 PM |
Mission: In a different script, make a brick that, when touched, makes another brick at the first brick's position.
What I got so far:
function whentouched() game.Workspace.Part:Clone() x = script.Parent:Clone() x.Parent = Workspace x.Name = ClonedPart end
script.Parent.Touched.connect(whentouched)
~If you say it again, I might care more this time~ |
|
|
| Report Abuse |
|
|
asimo3089
|
  |
| Joined: 19 Apr 2009 |
| Total Posts: 1184 |
|
|
| 27 Jun 2013 09:22 PM |
You need to learn more on the wiki before doing this type of stuff...
function whentouched() x = script.Parent:Clone() x.Parent = game.Workspace x.CFrame = script.Parent.CFrame x.Name = "ClonedPart" end script.Parent.Touched.connect(whentouched) |
|
|
| Report Abuse |
|
|
|
| 27 Jun 2013 09:29 PM |
This is the error that I am getting in the output
Workspace.Part.Script:8: bad argument #1 to 'connect' (RBXScriptSignal expected, got function)
~If you say it again, I might care more this time~ |
|
|
| Report Abuse |
|
|
Desperian
|
  |
| Joined: 07 Feb 2012 |
| Total Posts: 3371 |
|
|
| 27 Jun 2013 09:31 PM |
| script.Parent.Touched:connect(whentouched) |
|
|
| Report Abuse |
|
|