void Start() { animator = GetComponent <Animator>(); playerBody = GetComponent <Rigidbody2D>(); groundSensor = transform.Find("GroundSensor").GetComponent <Sensor_Bandit>(); currentHealth = maxHealth; }
// Use this for initialization void Start() { m_hook = GetComponent <Hook>(); m_animator = GetComponent <Animator>(); m_body2d = GetComponent <Rigidbody2D>(); m_groundSensor = transform.Find("GroundSensor").GetComponent <Sensor_Bandit>(); }
// Use this for initialization void Start() { m_animator = GetComponent <Animator>(); m_body2d = GetComponent <Rigidbody2D>(); m_groundSensor = transform.Find("GroundSensor").GetComponent <Sensor_Bandit>(); playerCombat = GetComponent <PlayerCombat>(); }
// Use this for initialization void Start() { m_animator = GetComponent <Animator>(); m_body2d = GetComponent <Rigidbody2D>(); m_groundSensor = transform.Find("GroundSensor").GetComponent <Sensor_Bandit>(); knightMoement.GetComponent <KnightFight>(); }
void Start() { _animator = GetComponent <Animator>(); _body2d = GetComponent <Rigidbody2D>(); _groundSensor = transform.Find("GroundSensor").GetComponent <Sensor_Bandit>(); _LayerMaskToEnemy = LayerMask.GetMask("Enemy", "Bullet"); _HealthBar.SetIndex(_Health); _DefaultAttackPointPosition = _AttackPoint.localPosition; }
// Use this for initialization void Start() { Time.timeScale = 1f; m_animator = GetComponent <Animator>(); m_body2d = GetComponent <Rigidbody2D>(); m_groundSensor = transform.Find("GroundSensor").GetComponent <Sensor_Bandit>(); currentHealth = maxHealth; healthBar.SetMaxHealth(maxHealth); }
// Use this for initialization void Start() { transform.localScale = new Vector3(-1.0f, 1.0f, 1.0f); m_animator = GetComponent <Animator>(); m_body2d = GetComponent <Rigidbody2D>(); m_groundSensor = transform.Find("GroundSensor").GetComponent <Sensor_Bandit>(); SlashCollider.enabled = false; Combo.SetActive(false); }
// Start is called before the first frame update void Awake() { inputs = new PlayerInputActions(); rb = GetComponent <Rigidbody2D>(); sens = transform.Find("GroundSensor").GetComponent <Sensor_Bandit>(); inputs.Player.Jump.started += ctx => JumpStarted(); inputs.Player.Jump.canceled += ctx => JumpCancelled(); }
void Start() { m_animator = GetComponent <Animator>(); m_body2d = GetComponent <Rigidbody2D>(); m_groundSensor = transform.Find("GroundSensor").GetComponent <Sensor_Bandit>(); curHealth = maxHealth; m_wallSensor = transform.Find("WallSensor").GetComponent <Sensor_Bandit>(); m_animator.SetInteger("AnimState", 1); }
// Use this for initialization void Start() { winText.gameObject.SetActive(false); deadText.gameObject.SetActive(false); m_animator = GetComponent <Animator>(); m_body2d = GetComponent <Rigidbody2D>(); m_groundSensor = transform.Find("GroundSensor").GetComponent <Sensor_Bandit>(); sprite = GetComponent <SpriteRenderer>(); countText.text = "Money: " + (coins * 100).ToString(); }
// Use this for initialization void Start() { m_animator = GetComponent <Animator>(); m_body2d = GetComponent <Rigidbody2D>(); m_groundSensor = transform.Find("GroundSensor").GetComponent <Sensor_Bandit>(); sword = GameObject.FindGameObjectWithTag("Sword"); sword.gameObject.SetActive(false); steepAudio = GetComponent <AudioSource>(); //sword.transform.position = new Vector3(sword.transform.position.x, transform.position.y, 200); }
void Start() { animator = GetComponent <Animator>(); BoxColliderClick = gameObject.GetComponent <SpriteRenderer>(); _UIManager = GameObject.Find("GameMaster").GetComponent <UIManager>(); _UIManager.SetPlayHPMax(3); _UIManager.SetPlayMPMax(100); mSensor_Bandit = gameObject.transform.GetChild(0).gameObject.GetComponent <Sensor_Bandit>(); playStatu = 0; }
// Use this for initialization void Start() { m_animator = GetComponent <Animator>(); m_body2d = GetComponent <Rigidbody2D>(); m_groundSensor = transform.Find("GroundSensor").GetComponent <Sensor_Bandit>(); GetComponent <SpriteRenderer>().flipX = true; click = GlobalVariables.getClick(); dashTime = startDashTime; timeStamp = Time.time + cooldown; power = GlobalVariables.getPower(); }
// Use this for initialization void Start() { m_animator = GetComponent <Animator>(); m_body2d = GetComponent <Rigidbody2D>(); m_groundSensor = transform.Find("GroundSensor").GetComponent <Sensor_Bandit>(); currentHealth1 = maxHealth1; healthBar1.SetMaxHealth(maxHealth1); currentFB = 0; fillableBar.SetHealth(currentFB); }
void Start() { Time.timeScale = 1; m_animator = GetComponent <Animator>(); m_body2d = GetComponent <Rigidbody2D>(); m_groundSensor = transform.Find("GroundSensor").GetComponent <Sensor_Bandit>(); spriteRenderer = GetComponent <SpriteRenderer>(); AudioSource.PlayClipAtPoint(fightVoice, Camera.main.transform.position); StartCoroutine("attackVoiceTimer"); }
void Start() { controller = GetComponent <Controller2D> (); gravity = -(2 * maxJumpHeight) / Mathf.Pow(timeToJumpApex, 2); maxJumpVelocity = Mathf.Abs(gravity) * timeToJumpApex; minJumpVelocity = Mathf.Sqrt(2 * Mathf.Abs(gravity) * minJumpHeight); m_animator = GetComponent <Animator>(); m_body2d = GetComponent <Rigidbody2D>(); m_groundSensor = transform.Find("GroundSensor").GetComponent <Sensor_Bandit>(); originalPos = new Vector3(gameObject.transform.position.x, gameObject.transform.position.y, gameObject.transform.position.z); }
private void Start() { currentHealth = maxHealth; //display health bar at full health healthBar.SetMaxHealth(maxHealth); //if enemy keeps attacking, the enemies gruond sensor might have been tagged as player for some reason playerTarget = GameObject.FindGameObjectWithTag("Player"); attackDelay = 2f; damage = 30; attackRange = 150; //set animator, rigidbody and ground sensor components m_animator = GetComponent <Animator>(); m_body2d = GetComponent <Rigidbody2D>(); m_groundSensor = transform.Find("GroundSensor").GetComponent <Sensor_Bandit>(); }
private void Start() { animator = GetComponent <Animator>(); rb = GetComponent <Rigidbody2D>(); groundSensor = transform.Find("GroundSensor").GetComponent <Sensor_Bandit>(); }
// Use this for initialization void Start() { m_animator = GetComponent <Animator>(); m_body2d = GameObject.Find("Player").GetComponent <Rigidbody2D>(); m_groundSensor = GameObject.Find("Body").GetComponent <Sensor_Bandit>(); }