Beispiel #1
0
    private void DrawSelection()
    {
        GUI.skin = ResourceManager.SelectBoxSkin;
        Rect selectBox = WorkManager.CalculateSelectionBox(selectionBounds, playingArea);

        GUI.BeginGroup(playingArea);
        DrawSelectionBox(selectBox);
        GUI.EndGroup();
    }
Beispiel #2
0
    private void DrawSelection()
    {
        GUI.skin = ResourceManager.SelectBoxSkin;
        Rect selectBox = WorkManager.CalculateSelectionBox(selectionBounds, playingArea);

        //Draw the selection box around the currently selected object, within the bounds of the playing area
        GUI.BeginGroup(playingArea);
        DrawSelectionBox(selectBox);
        GUI.EndGroup();
    }
Beispiel #3
0
    /*** Private Methods ***/

    private void DrawBuildProgress()
    {
        GUI.skin = ResourceManager.SelectBoxSkin;
        Rect selectBox = WorkManager.CalculateSelectionBox(selectionBounds, playingArea);

        //Draw the selection box around the currently selected object, within the bounds of the main draw area
        GUI.BeginGroup(playingArea);
        CalculateCurrentHealth(0.5f, 0.99f);
        DrawHealthBar(selectBox, "Building ...");
    }
Beispiel #4
0
    private void DrawBuildProgress()
    {
        GUI.skin = ResourceManager.SelectBoxSkin;
        Rect selectBox = WorkManager.CalculateSelectionBox(selectionBounds, playingArea);

        GUI.BeginGroup(playingArea);
        CalculateCurrentHealth(0.5f, 0.99f);
        DrawHealthBar(selectBox, "Building ...");
        GUI.EndGroup();
    }
Beispiel #5
0
 private void DrawSelection()
 {                                                                               //draw selection only when player camera is active
     if (GameObject.FindWithTag("MapCamera").GetComponent <Camera>().depth != 1) ///yess it works
     {
         GUI.skin = ResourceManager.SelectBoxSkin;
         Rect selectBox = WorkManager.CalculateSelectionBox(selectionBounds, playingArea);
         //Draw the selection box around the currently selected object, within the bounds of the playing area
         GUI.BeginGroup(playingArea);
         DrawSelectionBox(selectBox);
         GUI.EndGroup();
     }
 }