Exemple #1
0
    // Start is called before the first frame update
    void Start()
    {
        UI_Manager_script UI_values = UI_Man.GetComponent <UI_Manager_script>();

        if (SetBoardSize(UI_values.NUMBER_OF_PLAYERS) == false)
        {
            Debug.Log("Board Initilization failed");
            return;
        }
        int ErrorCode = InitializeBoard();

        switch (ErrorCode)
        {
        case 1:
            Debug.Log("Error 1: Description");
            break;

        case 2:
            Debug.Log("Error 2: Description");
            break;

        default:
            break;
        }
    }
Exemple #2
0
 // Start is called before the first frame update
 void Start()
 {
     activated = false;
     health    = 1;
     //Link to UI_Manager
     UI_Man    = GameObject.Find("UI_Manager");
     UI_values = UI_Man.GetComponent <UI_Manager_script>();
     HUD2GO    = GameObject.Find("Phase II");
     HUD2Value = HUD2GO.GetComponent <HUD2_display>();
 }
Exemple #3
0
    // Start is called before the first frame update
    void Start()
    {
        //Link to UI manager
        UI_Man = GameObject.Find("UI_Manager");
        UI_Manager_script UI_values = UI_Man.GetComponent <UI_Manager_script>();

        //Link to UI canvas to display/hide
        Intel_UI  = PH2_Intel.GetComponent <CanvasGroup>();
        Attack_UI = PH2_Attack.GetComponent <CanvasGroup>();
        Move_UI   = PH2_Move.GetComponent <CanvasGroup>();
        SD_UI     = PH2_SD.GetComponent <CanvasGroup>();

        ElementA = null;
        ElementB = null;
    }
Exemple #4
0
    // Start is called before the first frame update
    void Start()
    {
        //Link to UI
        UI_Manager_script UI_values = UI_Man.GetComponent <UI_Manager_script>();

        Display_status = GetComponent <CanvasGroup>();

        //Link to players
        Player_script Values_P1 = P1.GetComponent <Player_script>();
        Player_script Values_P2 = P2.GetComponent <Player_script>();
        Player_script Values_P3 = P3.GetComponent <Player_script>();
        Player_script Values_P4 = P4.GetComponent <Player_script>();

        //Set-up Phase 1
        UnitDeployed        = 0;
        Unit_To_Be_Deployed = Unit_script.UnitType.Default;
        Intel.text          = "";
    }
Exemple #5
0
    // Start is called before the first frame update
    void Start()
    {
        //Link to UI_Manager
        GameObject UI_Man = GameObject.Find("UI_Manager");

        UI_values = UI_Man.GetComponent <UI_Manager_script>();
        //Link to HUD1_display
        GameObject HUD1GO = GameObject.Find("Phase I");

        HUD1Value = HUD1GO.GetComponent <HUD1_script>();
        //Link to HUD2_display
        GameObject HUD2GO = GameObject.Find("Phase II");

        HUD2Value = HUD2GO.GetComponent <HUD2_display>();

        Owning_control = -1;
        Supply         = false;
        Occupation     = OccupationType.Free;
    }