public override bool OnDropItem(InventorySlotBehaviour inventorySlotBehaviour) { _playerMovementBehaviour.MaxVelocity -= IncreaseValue; inventorySlotBehaviour.PlayAnimation("InventorySlotBounceContract"); AudioManager.Play(ItemDrop, AudioCategory.Effect, 0.55f); return(true); }
public override void OnPickupItem(InventorySlotBehaviour inventorySlotBehaviour) { _playerShootBehaviour.HomingStrength += 1; AudioManager.Play(PickupItemAudioCip, AudioCategory.Effect); inventorySlotBehaviour.PlayAnimation("InventorySlotBounceLoop"); }
public override bool OnDropItem(InventorySlotBehaviour inventorySlotBehaviour) { _playerShootBehaviour.AdditionalDamage -= IncreaseValue; inventorySlotBehaviour.PlayAnimation("InventorySlotBounceContract"); AudioManager.Play(itemDrop, AudioCategory.Effect, 0.55f); return(true); }
public override void OnPickupItem(InventorySlotBehaviour inventorySlotBehaviour) { Persistent.CollectedKeyCardCount += 1; AudioManager.Play(ItemPickup, AudioCategory.Effect, 0.9f); MenuManager.ShowDialogue(_dialogueContentBehaviour.DialogueContent, () => { MenuManager.GoInto("MenuGameOver"); }); }
public override void OnPickupItem(InventorySlotBehaviour inventorySlotBehaviour) { inventorySlotBehaviour.PlayAnimation("InventorySlotBounceLoop"); _healthBehaviour.MaxHealth += IncreaseValue; AudioManager.Play(healthSFX, AudioCategory.Effect, 0.75f, false); }
public override bool OnDropItem(InventorySlotBehaviour inventorySlotBehaviour) { _playerShootBehaviour.HomingStrength -= 1; inventorySlotBehaviour.PlayAnimation("InventorySlotBounceContract"); AudioManager.Play(DropItemAudioClip, AudioCategory.Effect, 0.55f); return(true); }
public override bool OnDropItem(InventorySlotBehaviour inventorySlotBehaviour) { _healthBehaviour.MaxHealth -= IncreaseValue; inventorySlotBehaviour.PlayAnimation("InventorySlotBounceContract"); AudioManager.Play(itemDrop, AudioCategory.Effect, 0.45f); return(true); }
public override bool OnDropItem(InventorySlotBehaviour inventorySlotBehaviour) { if (!_isUsed) { inventorySlotBehaviour.PlayAnimation("InventorySlotBounceContract"); AudioManager.Play(itemDrop, AudioCategory.Effect, 0.55f); } return(true); }
public override void OnUseItem(InventorySlotBehaviour inventorySlotBehaviour) { if (_healthBehaviour.Value < _healthBehaviour.MaxHealth) { _isUsed = true; _healthBehaviour.Value += IncreaseValue; AudioManager.Play(healthSFX, AudioCategory.Effect); inventorySlotBehaviour.PlayAnimation("InventorySlotBounceExpand"); inventorySlotBehaviour.DropItem(); Destroy(gameObject); } }
public override void OnUpdateItem(InventorySlotBehaviour inventorySlotBehaviour) { IEnumerable <GameObject> enemies = TagBehaviour.FindWithTag("Enemy"); foreach (GameObject enemy in enemies) { _enemyHealthBehaviour = enemy.GetComponent <HealthBehaviour>(); if (_enemyHealthBehaviour.Value <= 0) { if (_healthBehaviour.Value < _healthBehaviour.MaxHealth) { _healthBehaviour.Value += IncreaseValue; AudioManager.Play(HealthSFX, AudioCategory.Effect); } } } }
public override void OnUseItem(InventorySlotBehaviour inventorySlotBehaviour) { if (_playerHealthBehaviour.Value < _playerHealthBehaviour.MaxHealth) { _isUsed = true; _playerHealthBehaviour.Value += IncreaseValue; AudioManager.Play(healthSFX, AudioCategory.Effect, 1.0f); inventorySlotBehaviour.PlayAnimation("InventorySlotBounceExpand"); inventorySlotBehaviour.DropItem(); // emit health event so tutorial room unlocks EventManager.Emit(new HealthChangedEventArgs { GameObject = gameObject, OldValue = 0, NewValue = 0, }); Destroy(gameObject); } }
public override bool OnDropItem(InventorySlotBehaviour inventorySlotBehaviour) => true;
public override void OnUpdateItem(InventorySlotBehaviour inventorySlotBehaviour) { }
public override void OnPickupItem(InventorySlotBehaviour inventorySlotBehaviour) { AudioManager.Play(ItemPickup, AudioCategory.Effect); inventorySlotBehaviour.PlayAnimation("InventorySlotBounceExpand"); }
public override void OnPickupItem(InventorySlotBehaviour inventorySlotBehaviour) { AudioManager.Play(RateOfFireSFX, AudioCategory.Effect); _playerShootBehaviour.FireRate += IncreaseValue; inventorySlotBehaviour.PlayAnimation("InventorySlotBounceLoop"); }
/// <summary> /// A callback method that is called to drop the item. /// </summary> /// <param name="inventorySlotBehaviour">The inventory slot that the item is stored in.</param> /// <returns>Returns true if the item is ready to be dropped, otherwise returns false.</returns> public abstract bool OnDropItem(InventorySlotBehaviour inventorySlotBehaviour);
/// <summary> /// A callback method that is called to update the item. /// </summary> /// <param name="inventorySlotBehaviour">The inventory slot that the item is stored in.</param> public abstract void OnUpdateItem(InventorySlotBehaviour inventorySlotBehaviour);
/// <summary> /// A callback method that is called to pick up an item. /// </summary> /// <param name="inventorySlotBehaviour">The inventory slot the item will be stored in.</param> public abstract void OnPickupItem(InventorySlotBehaviour inventorySlotBehaviour);
public override void OnPickupItem(InventorySlotBehaviour inventorySlotBehaviour) { AudioManager.Play(LifeStealSFX, AudioCategory.Effect, 0.9f); inventorySlotBehaviour.PlayAnimation("InventorySlotBounceLoop"); }
public override void OnPickupItem(InventorySlotBehaviour inventorySlotBehaviour) { _playerShootBehaviour.ProjectileScale += IncreaseValue; inventorySlotBehaviour.PlayAnimation("InventorySlotBounceLoop"); AudioManager.Play(PickupItemAudioCip, AudioCategory.Effect); }
public override void OnPickupItem(InventorySlotBehaviour inventorySlotBehaviour) { _playerMovementBehaviour.MaxVelocity += IncreaseValue; AudioManager.Play(SpeedUp, AudioCategory.Effect); inventorySlotBehaviour.PlayAnimation("InventorySlotBounceLoop"); }
public override void OnPickupItem(InventorySlotBehaviour inventorySlotBehaviour) { AudioManager.Play(WeaponDamageSFX, AudioCategory.Effect); _playerShootBehaviour.AdditionalDamage += IncreaseValue; inventorySlotBehaviour.PlayAnimation("InventorySlotBounceLoop"); }