|
| 01 Aug 2011 02:38 PM |
wait(.1) game.Workspace.ModelName.Children.locked = true end
It don't work =( also I just want the script to lock one of my models , I know there is a way to lock it without a script but I'm trying to make a script do that too. HOW DO I fix this? |
|
|
| Report Abuse |
|
|
|
| 01 Aug 2011 02:39 PM |
| SORRY , I'm a horrible scripter! |
|
|
| Report Abuse |
|
|
| |
|
| |
|
killjoy37
|
  |
| Joined: 27 Aug 2008 |
| Total Posts: 2821 |
|
|
| 01 Aug 2011 02:42 PM |
i = 0 while i = 0 do i = i + 1 for i,v in pairs(Workspace.ModelName:GetChildren()) do if v:IsA("Part") then v.Locked = true end end end |
|
|
| Report Abuse |
|
|
killjoy37
|
  |
| Joined: 27 Aug 2008 |
| Total Posts: 2821 |
|
|
| 01 Aug 2011 02:43 PM |
| oops sorry, change this line: "while i = 0 do" to this: "while i == 0 do" |
|
|
| Report Abuse |
|
|
Spectrumw
|
  |
| Joined: 04 Aug 2009 |
| Total Posts: 13510 |
|
|
| 01 Aug 2011 02:46 PM |
| ... Why did you add that useless loop? ._. |
|
|
| Report Abuse |
|
|
killjoy37
|
  |
| Joined: 27 Aug 2008 |
| Total Posts: 2821 |
|
|
| 01 Aug 2011 02:47 PM |
| I don't know how to make it run once, sorry. |
|
|
| Report Abuse |
|
|
| |
|
|
| 01 Aug 2011 02:48 PM |
| Wait nevermind let me change the line...and please make it run once? |
|
|
| Report Abuse |
|
|
killjoy37
|
  |
| Joined: 27 Aug 2008 |
| Total Posts: 2821 |
|
|
| 01 Aug 2011 02:48 PM |
| Did you change the line i said to? It should work if the model is in workspace, and you got the model name correct. |
|
|
| Report Abuse |
|
|
killjoy37
|
  |
| Joined: 27 Aug 2008 |
| Total Posts: 2821 |
|
| |
|
|
| 01 Aug 2011 02:52 PM |
| Lets see...if it works hold on. |
|
|
| Report Abuse |
|
|
| |
|
killjoy37
|
  |
| Joined: 27 Aug 2008 |
| Total Posts: 2821 |
|
|
| 01 Aug 2011 02:55 PM |
| post the script as you have it right now here. |
|
|
| Report Abuse |
|
|
| |
|
|
| 01 Aug 2011 02:56 PM |
i = 0 while i == 0 do i = i + 1 for i,v in pairs(Workspace.ModelName:GetChildren()) do if v:IsA("Part") then v.Locked = true end end end |
|
|
| Report Abuse |
|
|
killjoy37
|
  |
| Joined: 27 Aug 2008 |
| Total Posts: 2821 |
|
|
| 01 Aug 2011 02:57 PM |
| You have to change ModelName to the model's name... |
|
|
| Report Abuse |
|
|
|
| 01 Aug 2011 02:57 PM |
Ops . i = 0 while i == 0 do i = i + 1 for i,v in pairs(Workspace.Susan:GetChildren()) do if v:IsA("Part") then v.Locked = true end end end |
|
|
| Report Abuse |
|
|
|
| 01 Aug 2011 02:58 PM |
| There ^ that is the exact one and it still doesn't work. |
|
|
| Report Abuse |
|
|
killjoy37
|
  |
| Joined: 27 Aug 2008 |
| Total Posts: 2821 |
|
| |
|
| |
|
killjoy37
|
  |
| Joined: 27 Aug 2008 |
| Total Posts: 2821 |
|
|
| 01 Aug 2011 03:04 PM |
| What does it say in the output window? |
|
|
| Report Abuse |
|
|
| |
|
killjoy37
|
  |
| Joined: 27 Aug 2008 |
| Total Posts: 2821 |
|
|
| 01 Aug 2011 03:05 PM |
Try this, not sure if it will do anything.
i = 0 while i == 0 do wait() i = i + 1 for i,v in pairs(Workspace.Susan:GetChildren()) do if v:IsA("Part") then v.Locked = true end end end |
|
|
| Report Abuse |
|
|