Beispiel #1
0
    void Awake()
    {
        playerController     = GetComponent <PlayerController>();
        playerCombat         = GetComponent <PlayerCombat>();
        playerSpriteAnimator = GetComponent <PlayerSpriteAnimator>();

        playerInput = new PlayerInput();
    }
Beispiel #2
0
    // Use this for initialization
    void Start()
    {
        player = this.gameObject;

        rigidBody2D   = GetComponent <Rigidbody2D> ();
        boxCollider2D = GetComponent <BoxCollider2D> ();
        spriteRender  = GetComponent <SpriteRenderer> ();

        c_groundCheck = GameObject.Find("c_groundCheck").transform;
        l_groundCheck = GameObject.Find("l_groundCheck").transform;
        r_groundCheck = GameObject.Find("r_groundCheck").transform;

        checkPoint = GameObject.Find("checkPoint").transform;

        PLreload   = GetComponent <PlayerReloadCP> ();
        PLmovement = GetComponent <PlayerMovement> ();
        PLanimator = GetComponent <PlayerSpriteAnimator> ();

        selectGround = 1 << 8;
    }