Answered by
4 years ago Edited 4 years ago
Just store them in two separate variables:
1 | local Leg = script.Parent.Parent:FindFirstChild( "LegTrue" ) |
2 | local Torso = script.Parent.Parent:FindFirstChild( "TorsoTrue" ) |
If you truly need them in one place, you can store them in a table, like so:
3 | local Leg = script.Parent.Parent:FindFirstChild( "LegTrue" ) |
4 | local Torso = script.Parent.Parent:FindFirstChild( "TorsoTrue" ) |
7 | table.insert(Parts,Leg) |
8 | table.insert(Parts,Torso) |
Also note that parentheses do not have to wrap statements, like in Javascript and similar languages. For example, in if
statements, you do not have to wrap the conditions.
in lua
in Javascript