Exemplo n.º 1
0
        public void DrillTileAt(Pos pos, float damage)
        {
            var result = _tileMap.DrillTileAt(pos, damage);

            if (result.removeTile)
            {
                var cmd = new ChangeBlockCommand {
                    pos = pos, block = BlockType.EMPTY
                };
                RpcChangeTileAt(cmd);

                var worldPos = MapHelper.PosToWorld(pos);
                Game.Spawns.SpawnResources(worldPos, result.pickups);
            }
            RpcDrillEffectAt(pos);
        }