
using Godot;
using Rokojori;
 
namespace Rokojori
{ 
  public partial class UIShaderProperties
  { 
    public static void UpdateProperties( UIStylePropertyContainer container, Material material )
    {
      var numbers = container.GetShaderUINumbers();

      if ( numbers != null )
      {
        foreach ( var n in numbers )
        {
          if ( n == null )
          {
            continue;
          }
          
          n.UpdateMaterial( container, material );
        }
      }

      var colors = container.GetShaderUIColors();

      if ( colors != null )
      {
        foreach ( var c in colors )
        {
          if ( c == null )
          {
            continue;
          }

          c.UpdateMaterial( container, material );
        }
      }
    }
  }
}