CSL.NetworkExtensions.Framework.NetInfoExtensions.SetTextures C# (CSharp) Method

SetTextures() public static method

public static SetTextures ( this segment, CSL.NetworkExtensions.Framework.TexturesSet newTextures, CSL.NetworkExtensions.Framework.TexturesSet newLODTextures = null ) : NetInfo.Segment
segment this
newTextures CSL.NetworkExtensions.Framework.TexturesSet
newLODTextures CSL.NetworkExtensions.Framework.TexturesSet
return NetInfo.Segment
        public static NetInfo.Segment SetTextures(this NetInfo.Segment segment, TexturesSet newTextures, TexturesSet newLODTextures = null)
        {
            if (segment.m_material != null)
            {
                segment.m_material = segment.m_material.Clone(newTextures);
            }

            if (segment.m_segmentMaterial != null)
            {
                segment.m_segmentMaterial = segment.m_segmentMaterial.Clone(newTextures);
            }

            if (segment.m_lodMaterial != null)
            {
                if (newLODTextures != null)
                {
                    segment.m_lodMaterial = segment.m_lodMaterial.Clone(newLODTextures);
                }
            }

            return segment;
        }