コード例 #1
0
        private void DrawMapEvents_DrawMapLayer(object sender, DrawLayerEventArgs e)
        {
            if (e.PriorLayerID == "Back" && e.NewLayerID == "Buildings")
            {
                int i = 0;
                while (Game1.currentLocation.Map.Layers[i].Id != "Buildings")
                {
                    if (Game1.currentLocation.Map.Layers[i].Id != "Back")
                    {
                        Game1.currentLocation.Map.Layers[i].Draw(Game1.mapDisplayDevice, Game1.viewport, Location.Origin, false, Game1.pixelZoom);
                    }

                    i++;
                }
            }
        }
コード例 #2
0
 internal static void OnDrawMapLayer(object sender, DrawLayerEventArgs e)
 {
     DrawMapEvents.DrawMapLayer?.Invoke(sender, e);
 }