If CountChildren(entity) > 0 For childcount = 1 to CountChildren(entity) child = GetChild(entity,childcount) Next Endif