示例#1
0
    public static void Init()
    {
        if (particlesPlayer == null)
        {
            particlesPlayer = GameObject.FindObjectOfType <ParticlesPlayer>();
        }

        if (particlesDisplay == null)
        {
            particlesDisplay = GameObject.FindObjectOfType <ParticlesDisplay>();
        }
    }
示例#2
0
    public static void IntializeCheck()
    {
        if (player == null)
        {
            player = GameObject.FindObjectOfType <ParticlesPlayer>();
        }

        if (displayer == null)
        {
            displayer = GameObject.FindObjectOfType <ParticlesDisplayer>();
        }
    }
示例#3
0
    void Awake()
    {
        GetHeadAnimtorComponents();
        camTransform  = Camera.main.transform;
        camTransform  = Camera.main.transform;
        mInputManager = GameObject.Find("Managers").transform.GetChild(0).GetComponent <InputManager>();

        // If this script is on player
        if (transform.name != "Player Visual (1)")
        {
            mPlayerMovement = transform.parent.GetComponent <PlayerMovement>();
            mParticles      = transform.parent.transform.GetChild(4).GetComponent <ParticlesPlayer>();
            mBumSlider      = transform.GetChild(1).GetChild(1).gameObject;
            mBumSlider.SetActive(false);
            ThrowingComplete = true;
        }
        else
        {
            mPlayerMovement = GameObject.Find("Player_01").GetComponent <PlayerMovement>();
            mParticles      = GameObject.Find("Player_01").transform.GetChild(4).GetComponent <ParticlesPlayer>();
        }
    }