How do you find the amount of children attached to a game object

Doge Gamer 1 year ago updated by Lazlo Bonin (Lead Developer) 1 year ago 10

I tried to find the code line but the closest thing I could find was checking if it was the child of a parent, instead of how many children it has. How do I check this?

Bolt Version:
Unity Version:
Scripting Backend:
.NET Version (API Compatibility Level):
Satisfaction mark by Doge Gamer 1 year ago

Do I change component to whatever game object I’m using?

Edit: also thanks for the quick reply.

Second edit: Actually, I think I get it now. Nvm. Still thanks

You select what type of component you want to retrieve from children.

Ok, thanks! I have some scripts I’m trying to convert so this’ll help a lot.

I looked for the blocks you used and I couldn’t find any of them. Which bolt version are you using?

Wouldn't [Transform: Child Count] be easier/more-effective? (I'm assuming anyways)

Tried to find it... looked up child count and it didn’t show up

That's.. weird..

I know I've used that a bunch in Bolt 1.4 and I find no reason why they might have removed it in 2.0...?



I’m using human naming though. That might be what’s wrong

Edit: Wait. I found the get child count block.


Glad you sorted this out! :)