private bool CheckConditionsInternal() { switch (m_Config.m_GuardCrushType) { case PlayerGuardCrushTriggerAttackConfig.EGuardCrushType.NextNonSuperProjectile: return(!PlayerProjectileAttackLogic.IsNextNonSuperProjectileGuardCrush(m_InfoComponent.GetPlayerIndex())); default: return(false); } }
private bool IsAValidNonSuperProjectile() { //If there is a projectile in the scene and this is not a super attack AND destruction has not been requested yet //then the projectile is valid bool isAValidProjectile = false; if (m_CurrentProjectile != null) { PlayerProjectileAttackLogic projectileLogic = m_CurrentProjectile.GetLogic(); isAValidProjectile = !projectileLogic.IsASuper() && !m_CurrentProjectile.HasDestructionBeenRequested(); } return(isAValidProjectile); }
private void TriggerGuardCrushEffect() { switch (m_Config.m_GuardCrushType) { case PlayerGuardCrushTriggerAttackConfig.EGuardCrushType.NextNonSuperProjectile: PlayerProjectileAttackLogic.SetNextNonSuperProjectileGuardCrush(m_InfoComponent.GetPlayerIndex(), true); break; default: break; } SetTriggerPointStatus(m_InfoComponent, ETriggerPointStatus.Triggered); // Set trigger point in triggered status as it has been used }
void OnGUI() { if (ScenesConfig.GetDebugSettings().m_DisplayAttackTriggerInfo) { // Display Trigger : Non Super Projectile Guard Crush for PLAYER 1 /////////////// if (PlayerProjectileAttackLogic.IsNextNonSuperProjectileGuardCrush(0)) { DisplayNextNonSuperProjectileGuardCrush(0); } // Display Trigger : Non Super Projectile Guard Crush for PLAYER 2 /////////////// if (PlayerProjectileAttackLogic.IsNextNonSuperProjectileGuardCrush(1)) { DisplayNextNonSuperProjectileGuardCrush(1); } } }
public void OnInit(PlayerProjectileAttackLogic logic, PlayerProjectileAttackConfig config) { m_Logic = logic; m_Config = config; m_PlayerTag = logic.GetOwner().tag; m_ProjectileSFX = AttackConfig.Instance.m_ProjectileSFX; m_ProjectileType = GetProjectileType(); m_Animator.SetInteger(K_ANIM_ANGLE_INT, Mathf.FloorToInt(m_Config.m_ProjectileAngle)); m_Animator.SetBool(K_ANIM_ISSUPER_BOOL, m_Logic.IsASuper()); m_Animator.SetBool(K_ANIM_ISGUARDCRUSH_BOOL, m_Logic.IsGuardCrush()); InitPalette(); PlaySFX(EProjectileSFXType.Movement); Utils.GetPlayerEventManager(m_PlayerTag).TriggerEvent(EPlayerEvent.ProjectileSpawned, new ProjectileSpawnedEventParameters(this)); GamePauseMenuComponent.IsInPauseChanged += IsInPauseChanged; }