Get a named vector value.
public Vector4 GetVector(string propertyName) { Color color = this.GetColor(propertyName); return new Vector4(color.r, color.g, color.b, color.a); }
protected override void Init() { if (null == m_target) { return; } // end if var renderer = m_target.GetComponent <Renderer>(); if (null != renderer) { m_Material = renderer.material; } // end if if (null == m_Material) { return; } // end if if (!string.IsNullOrEmpty(m_property)) { m_beginVector = m_Material.GetVector(m_property); } else if (-1 != m_propertyID) { m_beginVector = m_Material.GetVector(m_propertyID); } // end if }