Exemple #1
0
    void endRaceDataCheck(int _place, float _timeRace, float _timeBestLap)
    {
        ProgressDataManager progressDataMgrTmp = progressDataObj.GetComponent <ProgressDataManager>();

        recordTextBestLapEverFL = progressDataMgrTmp.checkLapRecordEver(_timeBestLap);              //true if new record, false if not
        recordTextBestLapLvlFL  = progressDataMgrTmp.checkLapRecordThisLvlPlayerData(_timeBestLap); //true if new record, false if not
        recordTextBestRaceLvlFL = progressDataMgrTmp.checkRaceRecordThisLvlPlayerData(_timeRace);   //true if new record, false if not
        recordTextBestRaceFoeFL = progressDataMgrTmp.checkRaceRecordNrOppPlayerData(_timeRace);     //true if new record, false if not

        Text nextBtnTextTmp = nextBtnTextObj.GetComponent <Text>();

        if (progressDataMgrTmp.endRace(_place))
        {
            nextBtnTextTmp.text     = "Unlock Next";
            nextBtnTextTmp.fontSize = 44;
            restartBtnObj.SetActive(false);
            int tmpNrNewLvl = progressDataMgrTmp.getPlayerData().getMaxLvl();
            if (tmpNrNewLvl > 10 && (tmpNrNewLvl - 1) % 10 == 0)
            {
                showAnimationInformationFL = true;
            }
        }
        else
        {
            nextBtnTextTmp.text     = "End";
            nextBtnTextTmp.fontSize = 50;
            restartBtnObj.SetActive(true);
        };
    }
Exemple #2
0
    void Start()
    {
        progressData = progressDataObj.GetComponent <ProgressDataManager>();
        playerData   = progressData.getPlayerData();

        textEngineLvl   = textEngineLvlObj.GetComponent <Text>();
        textEngineMoney = textEngineMoneyObj.GetComponent <Text>();
        textMassLvl     = textMassLvlObj.GetComponent <Text>();
        textMassMoney   = textMassMoneyObj.GetComponent <Text>();
    }
Exemple #3
0
    void Start()
    {
        textNrLvl = textNrLvlObj.GetComponent <Text>();
        textPrize = textPrizeObj.GetComponent <Text>();

        lapRecEverText     = lapRecEverTextObj.GetComponent <Text>();
        lapRecThisLvlText  = lapRecThisLvlObj.GetComponent <Text>();
        raceRecThisLvlText = raceRecThisLvlObj.GetComponent <Text>();
        raceRecNrOppText   = raceRecNrOppObj.GetComponent <Text>();

        raceRecNrOppTitleText = raceRecNrOppTitleObj.GetComponent <Text>();

        textWonAfterCountLvlInfo       = textWonAfterCountLvlInfoObj.GetComponent <Text>();
        textWonAfterCountLvlInfoShadow = textWonAfterCountLvlInfoShadowObj.GetComponent <Text>();

        progressDataMgr = progressDataObj.GetComponent <ProgressDataManager>();
        playerDataMgr   = playerDataObj.GetComponent <PlayerData>();

        updateStatisticsInterface();
        setStatiscicsInterfaceOff();
    }