コード例 #1
0
    public void OnAdsCompleted()
    {
        StartCoroutine(FadeController.FadeOut(adsObject));
        GameSceneController.instance.isPlayable = true;
        GameSceneController.instance.CrackPlanet(false);
        SoundManager.instance.PlayBGM(bgm);

        SceneManager.UnloadSceneAsync(5);
    }
コード例 #2
0
        public static void StartEventStage(GameWebAPI.WD_Req_DngStart startInfo)
        {
            QuestEventInfoList.EventInfo eventInfo = ClassSingleton <QuestData> .Instance.GetEventInfo(startInfo.dungeonId);

            AdventureSceneController instance = ClassSingleton <AdventureSceneController> .Instance;
            string scriptFileName             = eventInfo.scriptFileName;

            if (QuestStart.< > f__mg$cache0 == null)
            {
                QuestStart.< > f__mg$cache0 = new Action(QuestStart.BeginEventScene);
            }
            Action beginAction = QuestStart.< > f__mg$cache0;

            if (QuestStart.< > f__mg$cache1 == null)
            {
                QuestStart.< > f__mg$cache1 = new Action(QuestStart.EndEventScene);
            }
            instance.Ready(scriptFileName, beginAction, QuestStart.< > f__mg$cache1);
            RestrictionInput.StartLoad(RestrictionInput.LoadType.LARGE_IMAGE_MASK_ON);
            GameWebAPI.RequestWD_WorldStart requestWD_WorldStart = new GameWebAPI.RequestWD_WorldStart();
            requestWD_WorldStart.SetSendData = delegate(GameWebAPI.WD_Req_DngStart param)
            {
                param.dungeonId           = startInfo.dungeonId;
                param.deckNum             = startInfo.deckNum;
                param.userDungeonTicketId = startInfo.userDungeonTicketId;
            };
            requestWD_WorldStart.OnReceived = delegate(GameWebAPI.RespDataWD_DungeonStart response)
            {
                ClassSingleton <QuestData> .Instance.RespDataWD_DungeonStart = response;
            };
            GameWebAPI.RequestWD_WorldStart request = requestWD_WorldStart;
            AppCoroutine.Start(request.RunOneTime(delegate()
            {
                if (null != DataMng.Instance() && DataMng.Instance().WD_ReqDngResult != null)
                {
                    DataMng.Instance().WD_ReqDngResult.startId   = ClassSingleton <QuestData> .Instance.RespDataWD_DungeonStart.startId;
                    DataMng.Instance().WD_ReqDngResult.dungeonId = startInfo.dungeonId;
                    DataMng.Instance().WD_ReqDngResult.clear     = 0;
                }
                DataMng.Instance().GetResultUtilData().last_dng_req = startInfo;
                FadeController fadeController = FadeController.Instance();
                float startAlpha = 0f;
                float endAlpha   = 1f;
                float time       = 0.5f;
                if (QuestStart.< > f__mg$cache2 == null)
                {
                    QuestStart.< > f__mg$cache2 = new Action(QuestStart.OnFinishedFadeoutEventStage);
                }
                fadeController.StartBlackFade(startAlpha, endAlpha, time, QuestStart.< > f__mg$cache2, null);
                SoundMng.Instance().StopBGM(0.5f, null);
            }, delegate(Exception noop)
            {
                RestrictionInput.EndLoad();
                CMD_QuestTOP.instance.ClosePanel(true);
            }, null), false);
        }
コード例 #3
0
    // Start is called before the first frame update
    void Start()
    {
        fC = this;

        faderObj.SetActive(true);
        faderImg = faderObj.GetComponent <Image>();

        // Fade in the Scene
        StartCoroutine(Fade(0f, 3f));
    }
コード例 #4
0
 void Start()
 {
     fadeObj      = GameObject.Find("FadePanel");
     fade         = fadeObj.GetComponent <FadeController>();
     fade.outFlag = false;
     if (SceneManager.GetActiveScene().name == "main")
     {
         time = GameObject.Find("Timer").GetComponent <GameTimer>();//制限時間
     }
 }
コード例 #5
0
 // Use this for initialization
 void Start()
 {
     //Cursor.visible = false;
     self = GetComponent <FadeController>();
     if (InitMeshsOnStart)
     {
         InitMeshs();
     }
     BatteryParent = BatteryAnimator.gameObject.transform.parent.gameObject;
 }
コード例 #6
0
 private void Start()
 {
     HC       = HighlightController.instance;
     baseCont = BaseController.instance;
     FC       = FadeController.self;
     GrabData(false);
     HideData();
     initDuraPos = SubBtns.btns[4].transform.localPosition;
     subInitPos  = SubCategoryPanel.transform.position;
 }
コード例 #7
0
 // Start is called before the first frame update
 private void Start()
 {
     _AudioController = FindObjectOfType(typeof(AudioController)) as AudioController;
     transition.SetActive(true);
     _FadeController = FindObjectOfType(typeof(FadeController)) as FadeController;
     timeStepPadrao  = timeStep;
     txt.text        = "";
     UpdateFalasList();
     falaAtual = falas[idFala];
 }
コード例 #8
0
    private void Start()
    {
        frame   = 0;
        m_state = EState.Wait;

        BgmSet();
        fadeController = FindObjectOfType <FadeController>();
        m_stageCreater = FindObjectOfType <StageCreate>();
        armatureSave   = FindObjectOfType <ArtArmatureSave>();
    }
コード例 #9
0
 private void Start()
 {
     m_fc = FindObjectOfType <FadeController>();
     m_am = FindObjectOfType <AudioManager>();
     if (m_fc)
     {
         Debug.Log($"GameManager::{m_fc.GetType().ToString()}");
     }
     PlayerIsFound = false;
     m_fc.FadeIn(m_waitoToStartFadeIn);
 }
コード例 #10
0
ファイル: Spawner.cs プロジェクト: Yeis/Scratchy
    void Start()
    {
        screenBounds   = Camera.main.ScreenToWorldPoint(new Vector3(Screen.width, Screen.height, Camera.main.transform.position.z));
        audioData      = GetComponent <AudioSource>();
        fadeController = GetComponent <FadeController>();
        //ensure game start with fade black
        fadeController.FadeIn(0);

        fadeController.FadeOut(2);
        StartCoroutine(ItchSpawner());
    }
コード例 #11
0
 void Awake()
 {
     if (_sSingleton != null && _sSingleton != this)
     {
         Destroy(this.gameObject);
     }
     else
     {
         _sSingleton = this;
     }
 }
コード例 #12
0
 // Use this for initialization
 void Start()
 {
     this.nextScene         = EScenes.NONE;
     this.nextSceneName     = "";
     this.currentSceneState = ESceneState.IN;
     this.currentScene      = EScenes.NONE;
     this._fadeController   = GetComponentInParent <FadeController> ();
     this._fadeController.setFadeTime(1.5f);
     this._isLoadSceneAsync = false;
     this.canLoadNextScene  = false;
 }
コード例 #13
0
    private void Start()
    {
        m_fadeController = FadeController.Instance;
        m_fadeController.SetSortingOrder(0);
        m_fadeController.FadeIn(1.0f, Color.black);

        if (TextObj != null)
        {
            TextObj.SetActive(false);
        }
    }
コード例 #14
0
 void Start()
 {
     timer          = resetTime;
     startCheck     = false;
     tutorialCheck  = false;
     resultCheck    = false;
     titleCheck     = false;
     endCheck       = false;
     fadeCheck      = false;
     fadeController = GameObject.Find("Panel").GetComponent <FadeController>();
 }
コード例 #15
0
ファイル: FadeController.cs プロジェクト: haseleyi/Nightfall
    private int m_FadeGUIDepth = -1000;                                 // Make sure this texture is drawn on top of everything


    // Initialize the texture, background-style and initial color
    private void Awake()
    {
        instance      = this;
        m_FadeTexture = new Texture2D(1, 1);
        m_BackgroundStyle.normal.background = m_FadeTexture;
        SetScreenOverlayColor(m_CurrentScreenOverlayColor);

        // TEMP:
        // usage: use "SetScreenOverlayColor" to set the initial color, then use "StartFade" to set the desired color & fade duration and start the fade
        // StartFadeIn(10);
    }
コード例 #16
0
    private void Start()
    {
        FadeController.CreateInstance(this);
        m_fadeController = FadeController.Instance;
        m_fadeController.SetSortingOrder(0);

        if (TextObj != null)
        {
            TextObj.SetActive(false);
        }
    }
コード例 #17
0
 private void Update()
 {
     fadeController = GameObject.Find("Panel").GetComponent <FadeController>();
     if (fadeController.isFadeOutEnd && fadeController.alfa >= 1)            //フェードアウトが完了しているかどうか
     {
         scenecontroller = GameObject.Find("SceneController(Clone)").GetComponent <SceneController>();
         scenecontroller.NextStage();            //次のステージを読みます。
         //fadeController.isFadeIn = true;
         Debug.Log("来たよ!");
         fadeController.isFadeOutEnd = false;    //二度読み防止
     }
 }
コード例 #18
0
 private void Awake()
 {
     if (Instance == null)
     {
         Instance = this;
     }
     else
     {
         Debug.Log("You have too many fade controllers!");
         Destroy(this);
     }
 }
コード例 #19
0
        void Awake()
        {
            #if !UNITY_EDITOR
            Debug.unityLogger.logEnabled = false;
                        #endif

            //SetResoultion
            Screen.SetResolution(360, 640, false);

            this.fade = this.transform.Find("Fade").GetComponent <FadeController>();
            Util.SpriteFactory.Instance.AddAtlas("Default");
        }
コード例 #20
0
    /// <summary>
    /// Objectのフェード開始
    /// </summary>
    /// <param name="_target"></param>
    /// <param name="_isFadeOut"></param>
    /// <param name="_duration"></param>
    public static void Begin(GameObject _target, bool _isFadeOut, float _duration)
    {
        FadeController fadeController = _target.GetComponent <FadeController>();

        if (fadeController == null)
        {
            fadeController = _target.AddComponent <FadeController>();
        }
        fadeController.enabled = true;

        fadeController.Play(_isFadeOut, _duration);
    }
コード例 #21
0
    public void OnAdsCompleted()
    {
        StartCoroutine(FadeController.FadeOut(adsObject));
        particle.SetActive(true);

        coinText.gameObject.SetActive(true);
        coinText.text = string.Format(LocalizedString.GetString("earned"), adsCoin);
        StartCoroutine(PlayCoinSound());

        GameManager.instance.playerData.playerCoin += adsCoin;
        playerCoin.text = GameManager.instance.playerData.playerCoin.ToString();
    }
コード例 #22
0
    private void Awake()
    {
        scenicCamera        = cameraRig.GetComponentInChildren <Camera>();
        scenicAudioListener = scenicCamera.GetComponent <AudioListener>();
        playerCamera        = player.GetComponentInChildren <Camera>();
        playerAudioListener = playerCamera.GetComponent <AudioListener>();
        canvas = menu.GetComponent <Canvas>();

        initialPlayerTransform = player.gameObject.transform;

        fadeController = FindObjectOfType <FadeController>();
    }
コード例 #23
0
 void Awake()
 {
     if (instance == null)
     {
         instance = this;
     }
     else if (instance != this)
     {
         Destroy(gameObject);
     }
     DontDestroyOnLoad(gameObject);
 }
コード例 #24
0
ファイル: AsyncLoader.cs プロジェクト: bonzajplc/LocusSolus
    void Start()
    {
        PlasticApplication app = FindObjectOfType <PlasticApplication>();

        //Plastic application is needed to perform it

        if (app)
        {
            if (app.XRCamera && app.XRCamera.gameObject.activeSelf)
            {
                fader = app.XRCamera.GetComponent <FadeController>();
                if (!fader)
                {
                    Debug.LogError("FadeController is needed to perform Fade!");
                }
            }
            if (app.FlatCamera && app.FlatCamera.gameObject.activeSelf && (!fadeInOnlyInXRMode || !fadeOutOnlyInXRMode))
            {
                fader = app.FlatCamera.GetComponent <FadeController>();
                if (!fader)
                {
                    Debug.LogError("FadeController is needed to perform Fade!");
                }
            }
        }
        else
        {
            Debug.LogError("Plastic Application is needed to perform FadeIn!");
        }

        if (fadeOut)
        {
            if (fadeOutTimer <= fadeOutTime)
            {
                PerformFade(FadeType.FadeOut, 0.0f);
            }
        }

        if (stopwatch.IsRunning)
        {
            stopwatch.Stop();
            Debug.LogError(SceneManager.GetActiveScene().name + " start/awake time: " + stopwatch.Elapsed);
            stopwatch.Reset();
        }
        #if UNITY_EDITOR
        if (loadSceneInEditor)
        #endif
        if (sceneName != "")
        {
            StartCoroutine(AsyncLoad());
        }
    }
コード例 #25
0
 // Use this for initialization
 void Awake()
 {
     if (skipTutorial)
     {
         forceTutorial = false;
     }
     buttonPressed      = false;
     fade               = GetComponent <FadeController> ();
     buttonPressedAudio = GetComponent <AudioSource> ();
     continueText.color = new Color(continueText.color.r, continueText.color.g, continueText.color.b, 0f);
     StartCoroutine("ShowButton");
     GameState.LoadGame();
 }
コード例 #26
0
    private void Awake()
    {
        DOTween.Init();

        battleController = FindObjectOfType <BattleController>();
        battleController.OnTurnValueChangedEvent  += UpdateTurnUI;
        battleController.OnPlayerInfoChangedEvent += UpdatePlayerUI;
        battleController.OnBattleOverEvent        += OnBattleOver;
        fadeController = new FadeController();

        continueButton.interactable = false;
        summaryPanel.gameObject.SetActive(false);
    }
コード例 #27
0
    public void GoMainMenu()
    {
        Debug.Log("Going Main Menu!");
        FadeController fader = mPlayer.GetComponentInChildren <FadeController>();

        if (fader != null)
        {
            fader.GetComponent <FadeController>().FadeToLevel(() => { Application.LoadLevel("MainMenu"); });
        }
        else
        {
            Application.LoadLevel("MainMenu");
        }
    }
コード例 #28
0
    void Start()
    {
        rb              = GetComponent <Rigidbody>();
        camTF           = Camera.main.transform;
        camStandHeight  = camTF.localPosition.y;
        standingSpeed   = speed;
        crouchingSpeed  = speed * 0.5f;
        magnifyingGlass = GetComponentInChildren <MagnifyingGlassManager>();

        Cursor.lockState = CursorLockMode.Locked;
        Cursor.visible   = false;
        fadeController   = FindObjectOfType <FadeController>();
        fadeController.SetTransparent();
    }
コード例 #29
0
 private void Start()
 {
     _AudioController = FindObjectOfType(typeof(AudioController)) as AudioController;
     transition.SetActive(true);
     mainCam         = Camera.main;
     _FadeController = FindObjectOfType(typeof(FadeController)) as FadeController;
     cena.SetActive(true);
     title.SetActive(false);
     timeStepPadrao = timeStep;
     txt.text       = "";
     UpdateFalasList();
     falaAtual             = falas[idFala];
     spriteRenderer.sprite = cenas[idDialogo];
 }
コード例 #30
0
ファイル: GameManager.cs プロジェクト: shshwdr/lollygagger
    public void GoMainMenu()
    {
        Debug.Log("Going Main Menu!");
        FadeController fader = mPlayer.GetComponentInChildren <FadeController>();

        if (fader != null)
        {
            fader.GetComponent <FadeController>().FadeToLevel(() => SceneManager.LoadScene("MainMenu"));
        }
        else
        {
            SceneManager.LoadScene("MainMenu");
        }
    }
コード例 #31
0
	void Start(){
		instance = this;
		StartFadeOut ();
	}