Exemple #1
0
 public static void SetLandBlockKey(int col, int row, LandBlockStatus info)
 {
     lock (landBlockMutex)
     {
         landBlockInfos[col, row] = info;
     }
 }
Exemple #2
0
        private void picImage_Click(object sender, EventArgs e)
        {
            txtDetail.Clear();

            // this is used for unloaded and loaded landblocks
            LandblockId landblockid = new LandblockId((byte)selrow, (byte)selcol);

            txtDetail.Text = string.Format("Landblock: {0} ", landblockid.Raw.ToString("X"));

            // this only works if the landblock is loaded..
            LandBlockStatus status = new LandBlockStatus();

            status = Diagnostics.GetLandBlockKey(selrow, selcol);
            if (status != null)
            {
                txtDetail.Text += Environment.NewLine + string.Format("Status:  {0} ", status.LandBlockStatusFlag.ToString());
                txtDetail.Text += Environment.NewLine + string.Format("Players:  {0} ", status.PlayerCount);
            }
        }