generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripting Helpers
Home Search
 

Re: Script that will help lock the children of my models!!

Previous Thread :: Next Thread 
CapitalOfRegionturna is not online. CapitalOfRegionturna
Joined: 25 Jul 2011
Total Posts: 26
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
CapitalOfRegionturna is not online. CapitalOfRegionturna
Joined: 25 Jul 2011
Total Posts: 26
01 Aug 2011 02:39 PM
SORRY , I'm a horrible scripter!
Report Abuse
CapitalOfRegionturna is not online. CapitalOfRegionturna
Joined: 25 Jul 2011
Total Posts: 26
01 Aug 2011 02:40 PM
BAWMP.
Report Abuse
CapitalOfRegionturna is not online. CapitalOfRegionturna
Joined: 25 Jul 2011
Total Posts: 26
01 Aug 2011 02:42 PM
BAWMP AGAIN.
Report Abuse
killjoy37 is not online. 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 is not online. 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 is not online. Spectrumw
Joined: 04 Aug 2009
Total Posts: 13510
01 Aug 2011 02:46 PM
... Why did you add that useless loop? ._.
Report Abuse
killjoy37 is not online. 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
CapitalOfRegionturna is not online. CapitalOfRegionturna
Joined: 25 Jul 2011
Total Posts: 26
01 Aug 2011 02:47 PM
Not working!
Report Abuse
CapitalOfRegionturna is not online. CapitalOfRegionturna
Joined: 25 Jul 2011
Total Posts: 26
01 Aug 2011 02:48 PM
Wait nevermind let me change the line...and please make it run once?
Report Abuse
killjoy37 is not online. 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 is not online. killjoy37
Joined: 27 Aug 2008
Total Posts: 2821
01 Aug 2011 02:49 PM
It will run once.
Report Abuse
CapitalOfRegionturna is not online. CapitalOfRegionturna
Joined: 25 Jul 2011
Total Posts: 26
01 Aug 2011 02:52 PM
Lets see...if it works hold on.
Report Abuse
CapitalOfRegionturna is not online. CapitalOfRegionturna
Joined: 25 Jul 2011
Total Posts: 26
01 Aug 2011 02:53 PM
Nooo it's not working.
Report Abuse
killjoy37 is not online. 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
CapitalOfRegionturna is not online. CapitalOfRegionturna
Joined: 25 Jul 2011
Total Posts: 26
01 Aug 2011 02:55 PM
No working!
Report Abuse
CapitalOfRegionturna is not online. CapitalOfRegionturna
Joined: 25 Jul 2011
Total Posts: 26
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 is not online. 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
CapitalOfRegionturna is not online. CapitalOfRegionturna
Joined: 25 Jul 2011
Total Posts: 26
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
CapitalOfRegionturna is not online. CapitalOfRegionturna
Joined: 25 Jul 2011
Total Posts: 26
01 Aug 2011 02:58 PM
There ^ that is the exact one and it still doesn't work.
Report Abuse
killjoy37 is not online. killjoy37
Joined: 27 Aug 2008
Total Posts: 2821
01 Aug 2011 03:01 PM
output?
Report Abuse
CapitalOfRegionturna is not online. CapitalOfRegionturna
Joined: 25 Jul 2011
Total Posts: 26
01 Aug 2011 03:02 PM
What do you mean output?
Report Abuse
killjoy37 is not online. killjoy37
Joined: 27 Aug 2008
Total Posts: 2821
01 Aug 2011 03:04 PM
What does it say in the output window?
Report Abuse
CapitalOfRegionturna is not online. CapitalOfRegionturna
Joined: 25 Jul 2011
Total Posts: 26
01 Aug 2011 03:05 PM
LET me check...
Report Abuse
killjoy37 is not online. 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
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image