protected override void Prepare() { base.Prepare(); if (Vector3.Angle((this.m_AI.m_EnemyModule.m_Enemy.transform.position - this.m_AI.transform.position).GetNormalized2D(), this.m_AI.transform.forward.GetNormalized2D()) >= 10f) { HumanRotateTo humanRotateTo = base.CreateAction(typeof(HumanRotateTo)) as HumanRotateTo; humanRotateTo.SetupParams(this.m_AI.m_EnemyModule.m_Enemy.transform.position, 10f); base.StartAction(humanRotateTo); return; } base.StartAction(this.m_ThrowStone); }
private void SetupAction() { if (!this.m_AI.m_EnemyModule.m_Enemy) { base.StartAction(this.m_Taunt); return; } if (Vector3.Angle((this.m_AI.m_EnemyModule.m_Enemy.transform.position - this.m_AI.transform.position).GetNormalized2D(), this.m_AI.transform.forward.GetNormalized2D()) >= 10f) { HumanRotateTo humanRotateTo = base.CreateAction(typeof(HumanRotateTo)) as HumanRotateTo; humanRotateTo.SetupParams(this.m_AI.m_EnemyModule.m_Enemy.transform.position, 10f); base.StartAction(humanRotateTo); } }
private void SetupAction() { Vector3 normalized2D = (Player.Get().transform.position - this.m_AI.transform.position).GetNormalized2D(); float num = Vector3.Angle(normalized2D, this.m_AI.transform.forward.GetNormalized2D()); if (num >= 10f) { HumanRotateTo humanRotateTo = base.CreateAction(typeof(HumanRotateTo)) as HumanRotateTo; humanRotateTo.SetupParams(Player.Get().transform.position, 10f); base.StartAction(humanRotateTo); } else { base.StartAction(this.m_Taunt); } }
protected override void Prepare() { base.Prepare(); Vector3 normalized2D = (Player.Get().transform.position - this.m_AI.transform.position).GetNormalized2D(); float num = Vector3.Angle(normalized2D, this.m_AI.transform.forward.GetNormalized2D()); if (num >= 10f) { HumanRotateTo humanRotateTo = base.CreateAction(typeof(HumanRotateTo)) as HumanRotateTo; humanRotateTo.SetupParams(Player.Get().transform.position, 10f); base.StartAction(humanRotateTo); } else { base.StartAction(this.m_ThrowStone); } }