Exemple #1
0
    public override void Start()
    {
        Dbg.LogCheckAssigned(Target, this);

        selfExpTimer = new Timer(10.0f);
        aimTimer     = 0;
    }
Exemple #2
0
 void Start()
 {
     Dbg.LogCheckAssigned(PressAnyKeys, this);
     Dbg.LogCheckAssigned(PressAnyKeysTransparent, this);
     PressAnyKeys.SetAlpha(1.0f);
     PressAnyKeysTransparent.SetAlpha(1.0f);
 }
    void Start()
    {
        Dbg.LogCheckAssigned(UserName, this);
        Dbg.LogCheckAssigned(Password, this);
        Dbg.LogCheckAssigned(LoginBtn, this);

        if (Utils.IsValid(LoginBtn))
        {
            LoginBtn.onClick.AddListener(OnLogin);
        }

        Dbg.LogCheckAssigned(FlyAwayAnims[0], this);
        Dbg.LogCheckAssigned(FlyAwayAnims[1], this);
    }
    void Start()
    {
        Dbg.LogCheckAssigned(Target, this);

        int arrayLen = 0;

        foreach (var e in Target.GetComponentsInChildren <Outline_AvgNormal>())
        {
            if (Utils.IsValid(e))
            {
                ++arrayLen;
            }
        }
        SkinnedMesh = new SkinnedMeshRenderer[arrayLen];
    }
Exemple #5
0
    void Start()
    {
        IsCloseMenuClicked = false;
        // Error check.
        Dbg.LogCheckAssigned(Exit, this);
        Dbg.LogCheckAssigned(CloseMenu, this);

        if (Utils.IsValid(Exit))
        {
            // Add listener to onClick.
            Exit.onClick.AddListener(OnLeaveRoom);
        }

        if (Utils.IsValid(CloseMenu))
        {
            CloseMenu.onClick.AddListener(OnCloseMenuClicked);
        }
    }
Exemple #6
0
    void Start()
    {
        Dbg.LogCheckAssigned(BtnMissionStart, this);
        Dbg.LogCheckAssigned(BtnReturnToTitle, this);
        ConnectRuleCache = FindObjectOfType <ConnectRule>();
        ChatRuleCache    = FindObjectOfType <ChatRule>();

        if (Utils.IsValid(ConnectRuleCache))
        {
            if (Utils.IsValid(BtnMissionStart))
            {
                BtnMissionStart.onClick.AddListener(OnMissionStartBtnClicked);
            }

            if (Utils.IsValid(BtnReturnToTitle))
            {
                BtnReturnToTitle.onClick.AddListener(OnReturnToTitleBtnClicked);
            }
        }
    }
Exemple #7
0
    void Start()
    {
        Dbg.LogCheckAssigned(PlayerPf, this);

        //if (Application.isEditor)
        //{
        //    var loadedLevel = SceneManager.GetSceneByName("Stage1");
        //    if (true == loadedLevel.isLoaded)
        //    {
        //        SceneManager.SetActiveScene(loadedLevel);
        //    }
        //}

        if (Utils.IsNull(WeaponView.LocalPlayerInst) && Utils.IsNull(HealthView.LocalPlayerInst))
        {
            var player = PhotonNetwork.Instantiate(PlayerPf.name, new Vector3(0.0f, 50.0f, 150.0f), Quaternion.identity);
            player.name = "Player";
        }

        // Preload all the required scenes for the stage1.
        //AsyncOperation[] additionalSceneStatus = new AsyncOperation[2]{
        //    SceneManager.LoadSceneAsync("ChatUI", LoadSceneMode.Additive),
        //    SceneManager.LoadSceneAsync("MenuUI", LoadSceneMode.Additive)
        //};

        SceneManager.LoadScene("ChatUI", LoadSceneMode.Additive);
        SceneManager.LoadScene("MenuUI", LoadSceneMode.Additive);

        Scenes[0] = SceneManager.GetSceneAt(1);
        Scenes[1] = SceneManager.GetSceneAt(2);

        // GetRootGameObjects works properly after the scene has been fully loaded!
        StartCoroutine(Yielder.GetCoroutine(() =>
        {
            Scenes[0].GetRootGameObjects(ChatSceneGOs);
            SwitchChatUI(false);

            Scenes[1].GetRootGameObjects(MenuSceneGOs);
            SwitchMenuUI(false);
        }, 0.25f));
    }
    void Start()
    {
        Dbg.LogCheckAssigned(UserName, this);
        Dbg.LogCheckAssigned(Password, this);
        Dbg.LogCheckAssigned(LoginBtn, this);

        if (Utils.IsValid(LoginBtn))
        {
            LoginBtn.onClick.AddListener(OnLogin);
        }

        Dbg.LogCheckAssigned(FlyAwayAnims[0], this);
        Dbg.LogCheckAssigned(FlyAwayAnims[1], this);

        if (!AppManager.Instance().isOnline)
        {
            InputField name = UserName.GetComponent <InputField>();
            name.interactable = false;

            Password.GetComponent <InputField>().interactable = false;

            offlineCanvas.gameObject.SetActive(true);
        }
    }
 void Start()
 {
     Dbg.LogCheckAssigned(AssaultRifleCache, this);
 }
 void Start()
 {
     Dbg.LogCheckAssigned(SniperRifleCache, this);
 }
 void Start()
 {
     Dbg.LogCheckAssigned(Missile, this);
 }
 void Awake()
 {
     Timing = GetComponent <MEC.Timing>();
     Dbg.LogCheckAssigned(Timing, this);
     DontDestroyOnLoad(gameObject);
 }
 void Start()
 {
     RemainingTimeBar            = GetComponent <Image>();
     RemainingTimeBar.fillMethod = Image.FillMethod.Horizontal;
     Dbg.LogCheckAssigned(RemainingTimeBar);
 }
Exemple #14
0
 void Start()
 {
     Dbg.LogCheckAssigned(AssaultRifle, this);
     Dbg.LogCheckAssigned(SniperRifle, this);
 }
Exemple #15
0
 void Start()
 {
     Dbg.LogCheckAssigned(BossCache, this);
 }
 void Start()
 {
     HealthPointText = GetComponent <Text>();
     Dbg.LogCheckAssigned(HealthPointText);
 }
Exemple #17
0
 public override void Start()
 {
     Target = GameObject.FindGameObjectWithTag("Player").transform;
     Dbg.LogCheckAssigned(Target, this);
     timer = 0;
 }
 void Start()
 {
     AmmoCountText = GetComponent <Text>();
     Dbg.LogCheckAssigned(AmmoCountText);
 }