Beispiel #1
0
 public void SetCellType(VCellType cellType)
 {
     if (cellType == VCellType.VOID)
     {
         this.gameObject.SetActive(false);
     }
 }
Beispiel #2
0
        public static Color CellTypeToColor(VCellType cellType)
        {
            Color toDraw;

            switch (cellType)
            {
            case VCellType.NORMAL:
                toDraw = new Color(1.0f, 1.0f, 1.0f, 0.5f);
                break;

            case VCellType.WALL:
                toDraw = new Color(1.0f, 0.0f, 0.0f);
                break;

            case VCellType.VOID:
                toDraw = new Color(0.0f, 0.0f, 0.0f, 0.5f);
                break;

            default:
                toDraw = new Color(0.0f, 0.0f, 0.0f, 0.5f);
                break;
            }
            return(toDraw);
        }