// Display the selection with a GUI image private void OnGUI() { if (isClicking) { drawnRect = GraphicsController.DrawRectangle(startScreenMousePOS, screenMousePOS); } }
/// <summary> /// todo: convert this to any color /// Draws the rectangle on the GUI /// </summary> /// <param name="rect"></param> /// <param name="color"></param> public static void DrawScreen(this Rect rect, Color color) { GUI.color = color; GUI.DrawTexture(rect, GraphicsController.WhiteTexture()); GUI.color = Color.white; }