Beispiel #1
0
 private void setupSelectedBlockType()
 {
     selectedBlockTypeChanging = true;
     ((ListStore)selectedBlockType.Model).Clear();
     foreach (object o in Enum.GetValues(((Enum)BlockType.Walkable).GetType()))
     {
         selectedBlockType.AppendText(Field.BlockTypeToString((BlockType)o));
     }
     selectedBlockTypeChanging = false;
 }
Beispiel #2
0
 private void OnFieldMouseMove(FieldView sender, int x, int y)
 {
     if (x == -1 && y == -1)
     {
         currentCoord.Text = currentBlockType.Text = "-";
     }
     else
     {
         currentCoord.Text     = String.Format("{0:d}, {1:d}", x, y);
         currentBlockType.Text = Field.BlockTypeToString(
             fieldView.Field.GetBlock((uint)x, (uint)y)
             );
     }
 }