Пример #1
0
    public void Start()
    {
        this.raycastEnemy = GetComponent <RaycastEnemy>();

        this.myTransform = gameObject.transform;

        this.canAttack = GetComponent <EnemyCanAttack>();

        this.enemyStateMachine = GetComponent <EnemyStateMachine>();

        this.enemyStateMachine.setStateMachineEnemy(StateMachineEnemy.Move);

        this.target = GameObject.Find("Jumba").transform;

        this.controllerHitSequence = target.GetComponent <ControllerHitSequence>();

        this.interfaceHitCombo = target.GetComponent <InterfaceHitCombo>();

        this.controllerHit = target.GetComponent <ControllerHitPlayer>();

        this.strikeForce = target.GetComponent <StrikeForce>();

        this.enemyLife = GetComponent <EnemyLife>();

        this.characterController = GetComponent <CharacterController>();

        this.enemyAnimation = GetComponent <EnemyAnimator>();
    }
Пример #2
0
    private ControllerHitSequence controllerHitSequence;     // controle da sequencia de Hit

    void Start()
    {
        var jumba = GameObject.Find("Jumba");

        controllerHit         = jumba.GetComponent <ControllerHitPlayer>();
        interfaceHitCombo     = jumba.GetComponent <InterfaceHitCombo>();
        controllerHitSequence = jumba.GetComponent <ControllerHitSequence>();
    }
Пример #3
0
    void Start()
    {
        player = GameObject.Find("Jumba").transform;

        // gets this scripts from player
        this.controllerHitSequence = player.GetComponent <ControllerHitSequence>();
        this.controllerHit         = player.GetComponent <ControllerHitPlayer>();
        this.interfaceHitCombo     = player.GetComponent <InterfaceHitCombo>();
    }
Пример #4
0
    private Vector3 direction;                // used to mark the direction

    #endregion

    void Start()
    {
        player = transform.parent.GetComponent <SniperMoviment>().player;           // it gets the player

        this.controllerHitSequence = player.GetComponent <ControllerHitSequence>(); // to control the hit sequence

        this.controllerHit = player.GetComponent <ControllerHitPlayer>();           // to control the hit

        this.interfaceHitCombo = player.GetComponent <InterfaceHitCombo>();         // to control the hit interface
    }
Пример #5
0
    void Start()
    {
        player = transform.parent.GetComponent <DragonHead>().player;

        this.controllerHitSequence = player.GetComponent <ControllerHitSequence>();

        this.controllerHit = player.GetComponent <ControllerHitPlayer>();

        this.interfaceHitCombo = player.GetComponent <InterfaceHitCombo>();

        interfaceLifeBoss = GameObject.Find("EnemyLife").GetComponent <InterfaceLifeBoss>();
    }
Пример #6
0
    private float life;                          // used to work with the life

    void Start()
    {
        player = GameObject.Find("Jumba").transform;

        this.controllerHitSequence = player.GetComponent <ControllerHitSequence>();

        this.controllerHit = player.GetComponent <ControllerHitPlayer>();

        this.interfaceHitCombo = player.GetComponent <InterfaceHitCombo>();

        interfaceLifeBoss = GameObject.Find("EnemyLife").GetComponent <InterfaceLifeBoss>();

        exterminatorMovement = transform.parent.GetComponent <ExterminatorMovement>();

        life = maxLife;

        // define the maximum angry degree of the boss
        maxAngryDegree = Random.Range(5, 10);

        // sends the difficulty factor
        exterminatorMovement.setDegreeOfDifficulty(life / maxLife);
    }