makeLine.Update C# (CSharp) Method

Update() public method

public Update ( ) : void
return void
    void Update()
    {
        Vector2 wc = wand.getTrackpadCoords ();
        if (wc != Vector2.zero) {
            float h = Mathf.Atan2(wc.y, wc.x) / (Mathf.PI * 2f) + 0.5f;
            float v = 1f;
            float s = 1f;
            color = Utility.HsvToRgb(h, s, v);
        }
        wandModel.GetComponent<Renderer> ().material.SetColor ("_Color",color);
        reduceTransparency ();
        if (lines.Count > 0) {
            lineRen.enabled = true;
        } else {
            lineRen.enabled = false;
        }
    }