Ejemplo n.º 1
0
    void Start()
    {
        VariousCount = GameObject.Find("CountManager");
        variousCount = VariousCount.GetComponent <VariousCount>();

        ProgressManager = GameObject.Find("ProgressManager");
        gameProgress    = ProgressManager.GetComponent <GameProgress>();
    }
Ejemplo n.º 2
0
    void Start()
    {
        DungeonInfo = GameObject.Find("MapGenerator");
        dungeon     = DungeonInfo.GetComponent <MapGenerate>();
        firstSet    = true;
        pathCount   = 0;

        energyCountAll = 0;
        CountManager   = GameObject.Find("CountManager");
        variousCount   = CountManager.GetComponent <VariousCount>();

        MainCamera       = GameObject.Find("MainCamera");
        playerController = MainCamera.GetComponent <PlayerController>();
    }
Ejemplo n.º 3
0
    void Start()
    {
        fadeFlag = 0;

        Player           = GameObject.Find("MainCamera");
        playerCamera     = Player.GetComponent <Camera>();
        playerController = Player.GetComponent <PlayerController>();

        Encount     = GameObject.Find("EncountPlaceGenerator");
        encountSign = Encount.GetComponent <VariousGenerate>();
        objectOnOff = Encount.GetComponent <ObjectOnOffController>();

        MapGenerator = GameObject.Find("MapGenerator");
        gate         = MapGenerator.GetComponent <VariousGenerate>();

        RadarCamera = GameObject.Find("RadarCamera");
        radarCam    = RadarCamera.GetComponent <Camera>();

        BattleCamera = GameObject.Find("BattleCamera");
        battleCam    = BattleCamera.GetComponent <Camera>();

        EnemyNameCamera = GameObject.Find("EnemyNameCamera");
        enemyNameCam    = EnemyNameCamera.GetComponent <Camera>();

        DirectionArrow = GameObject.Find("ArrowPivot");
        DirectionArrow.SetActive(false);

        MainGameCanvas = GameObject.Find("Canvas_mainGame");
        mainGameCanvas = MainGameCanvas.GetComponent <Canvas>();

        BattleGameEnergyCanvas            = GameObject.Find("Canvas_battleGameEnergy");
        battleGameEnergyCanvas_mouseInput = BattleGameEnergyCanvas.GetComponent <MouseInput>();


        fade = GameObject.Find("FadeCanvas").GetComponent <Fade>();

        battleCam.enabled    = false;
        enemyNameCam.enabled = false;

        battleGameEnergyCanvas_mouseInput.enabled = false;

        phase = Phase.energyLeft;
        //PhaseをPlayerPrefsセーブするのにintじゃないとだめだからphaseValueをつくった。めんどい。やばそうな作りだ・・・
        switch (phaseValue)
        {
        case 10:
            phase = Phase.energyLeft;
            break;

        case 20:
            phase = Phase.energyAllGet;
            break;

        case 30:
            phase = Phase.leaveHere;
            break;

        case 40:
            phase = Phase.setArrowAndMapUI;
            break;

        case 50:
            phase = Phase.energyDecrease;
            break;

        case 60:
            phase = Phase.arriveGate;
            break;

        case 80:
            phase = Phase.waitForArriveGate;
            break;

        case 70:
            phase = Phase.energyZero;
            break;

        case 90:
            phase = Phase.waitForGameOver;
            break;

        case 100:
            phase = Phase.justEncount;
            break;

        default:
            break;
        }

        //諸々、表示したいのを取得しとく。なんかこれも、効率悪そう。
        Announce_AllEnergyGet = GameObject.Find("AllEnergyGet");
        Announce_AllEnergyGet.SetActive(false);
        Announce_LeaveHere = GameObject.Find("LeaveHere");
        Announce_LeaveHere.SetActive(false);
        Announce_ArriveGate = GameObject.Find("ArriveGate");
        Announce_ArriveGate.SetActive(false);
        Announce_EnergyZero = GameObject.Find("EnergyZero");
        Announce_EnergyZero.SetActive(false);
        Announce_GameOver = GameObject.Find("GameOver");
        Announce_GameOver.SetActive(false);

        //m_shinny = new ShinyEffectForUGUI();

        //全部取った時は、総量の表示を消しておきたいと思ったので、その表示部分のオブジェクトを取得しておく
        //減るカウントとそのままのカウントがあるのがおかしいし。
        energyAllCountObj = GameObject.FindGameObjectWithTag("energyAllCount");
        //こっちは取得した数を示す。減少させるのはこっち
        CountManager         = GameObject.Find("CountManager");
        variousCount         = CountManager.GetComponent <VariousCount>();
        ui_energyCountHeader = GameObject.Find("energy");
        ui_energyCount       = GameObject.Find("count");
        energyCount          = PlayerPrefs.GetInt("Energy");
    }