public Spatial detachChildAt(int index) {
        Spatial child = children.remove(index);
        if (child != null) {
            child.setParent(null);
            logger.log(Level.FINE, "{0}: Child removed.", this);

            // since a child with a bound was detached;
            // our own bound will probably change.
            setBoundRefresh();

            // our world transform no longer influences the child.
            // XXX: Not necessary? Since child will have transform updated
            // when attached anyway.
            child.setTransformRefresh();
            // lights are also inherited from parent
            child.setLightListRefresh();
            child.setMatParamOverrideRefresh();

            invalidateUpdateList();
        }
        return child;
    }
<code>detachChildAt</code> removes a child at a given index. That child
is returned for saving purposes.

@param index
           the index of the child to be removed.
@return the child at the supplied index.
jme3-core/src/main/java/com/jme3/scene/Node.java