Пример #1
0
    public WTPolygonSprite(WTPolygonData polygonData)
    {
        _element      = Futile.atlasManager.GetElementWithName("Futile_White");
        _isAlphaDirty = true;

        UpdateWithData(polygonData);
    }
Пример #2
0
    public WTPolygonSprite(WTPolygonData polygonData)
    {
        _element = Futile.atlasManager.GetElementWithName("Futile_White");
        _isAlphaDirty = true;

        UpdateWithData(polygonData);
    }
Пример #3
0
    // Call this method if you want to change the points of the polygon after it already exists.
    public void UpdateWithData(WTPolygonData newData)
    {
        this.polygonData = newData;

        if (polygonData != null)
        {
            RefreshVertices();

            _triangleCount = this.polygonData.polygonTriangles.Length / 3;

            Init(FFacetType.Triangle, _element, _triangleCount);

            _isMatrixDirty         = true;
            _isAlphaDirty          = true;
            _areLocalVerticesDirty = true;

            Redraw(true, false);
        }
    }
Пример #4
0
    // Call this method if you want to change the points of the polygon after it already exists.
    public void UpdateWithData(WTPolygonData newData)
    {
        this.polygonData = newData;

        if (polygonData != null) {
            RefreshVertices();

            _triangleCount = this.polygonData.polygonTriangles.Length / 3;

            Init(FFacetType.Triangle, _element, _triangleCount);

            _isMatrixDirty = true;
            _isAlphaDirty = true;
            _areLocalVerticesDirty = true;

            Redraw(true, false);
        }
    }