Exemplo n.º 1
0
        public override void DoOperation(Dictionary <int, LocalUpdateFlags> blockUpdateChain)
        {
            StaticTile existingTile = new StaticTile();
            int        idx          = lookupExistingStatic(ref existingTile);

            if (idx >= 0)
            {
                AddStatic    addStatic = new AddStatic(m_MapNumber, existingTile.ID, (sbyte)existingTile.Z, m_destinationX, m_destinationY, existingTile.Hue);
                DeleteStatic delStatic = new DeleteStatic(m_MapNumber, m_StaticTarget);

                MapOperationSeries moveSeries = new MapOperationSeries(addStatic, m_MapNumber);
                moveSeries.Add(delStatic);
                moveSeries.DoOperation(blockUpdateChain);
            }
        }