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
 

[ Content Deleted ]

Previous Thread :: Next Thread 
nate890 is not online. nate890
Joined: 22 Nov 2008
Total Posts: 21686
08 Aug 2011 01:13 PM
I kind of dislike the fact that you can't unanchor a model alone

I have a model with several other models in it, and in them even more models...

Model
>Model
>>Model
>>>Parts
>Model
>>Model
>>>Parts
>>Model
>>>Parts
>Model
>>Model
>>>Parts
>Model
>>Model
>>>Parts
>>Model
>>>Parts
>Model
>>Model
>>>Parts
>>Model
>>>Parts
>Model
>>Model
>>>Parts
>Model
>>Model
>>>Parts

Something like that, how can I get everything ALLL together in that model, and inside get all the parts inpairs?

Report Abuse
Spectrumw is not online. Spectrumw
Joined: 04 Aug 2009
Total Posts: 13510
08 Aug 2011 01:15 PM
function unAnchor(Model)
for i, v in pairs(Model:GetChildren()) do
if v:IsA("BasePart") then
v.Anchored = false
elseif v:IsA("Model") then
unAnchor(v)
end
end

unAnchor(TheMainModel)
Report Abuse
Spectrumw is not online. Spectrumw
Joined: 04 Aug 2009
Total Posts: 13510
08 Aug 2011 01:16 PM
Missed an end D:

function unAnchor(Model)
for i, v in pairs(Model:GetChildren()) do
if v:IsA("BasePart") then
v.Anchored = false
elseif v:IsA("Model") then
unAnchor(v)
end
end
end

unAnchor(TheMainModel)
Report Abuse
comiconor is not online. comiconor
Joined: 26 May 2009
Total Posts: 16893
08 Aug 2011 01:16 PM
[ Content Deleted ]
Report Abuse
comiconor is not online. comiconor
Joined: 26 May 2009
Total Posts: 16893
08 Aug 2011 01:17 PM
[ Content Deleted ]
Report Abuse
nate890 is not online. nate890
Joined: 22 Nov 2008
Total Posts: 21686
08 Aug 2011 01:18 PM
Spec, I added the extra end, then the next output

>Mon Aug 08 14:17:26 2011 - Workspace.Script:2: stack overflow
Report Abuse
Spectrumw is not online. Spectrumw
Joined: 04 Aug 2009
Total Posts: 13510
08 Aug 2011 01:21 PM
function unAnchor(Model)
for i, v in pairs(Model:GetChildren()) do
if v:IsA("BasePart") then
wait()
v.Anchored = false
elseif v:IsA("Model") then
unAnchor(v)
end
end
end

unAnchor(TheMainModel)

Try that.
Report Abuse
nate890 is not online. nate890
Joined: 22 Nov 2008
Total Posts: 21686
08 Aug 2011 01:30 PM
Same output :/


Mon Aug 08 14:30:22 2011 - Workspace.Script:2: stack overflow
Report Abuse
nate890 is not online. nate890
Joined: 22 Nov 2008
Total Posts: 21686
08 Aug 2011 01:35 PM
No idea why it is erroring that output
Report Abuse
nate890 is not online. nate890
Joined: 22 Nov 2008
Total Posts: 21686
08 Aug 2011 01:47 PM
errrr

~
Report Abuse
nate890 is not online. nate890
Joined: 22 Nov 2008
Total Posts: 21686
08 Aug 2011 01:56 PM
May anyone help me out, please?

~This is a siggy
Report Abuse
comiconor is not online. comiconor
Joined: 26 May 2009
Total Posts: 16893
08 Aug 2011 03:07 PM
[ Content Deleted ]
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