override public void PerformEffectOnPlayer(PlayerControllerBase player) { // Only consume the pickup and activate the effect if the player // doesn't have this effect active already. if (!player.HasPlayerEffect(typeof(InvisibilityPlayerEffect))) { // "Pick up" the item. ConsumePickup(); PlayerEffect effect = new InvisibilityPlayerEffect( player, InvisibilityDuration, InvisibilityMaterial, VisualLerpDuration, NormalWeaponShotExposeDuration, QuickCloakingWeaponShotExposeDuration, QuickCloakingWeaponSwitchThreshold, PlayerDamageExposeDuration); player.ActivatePlayerEffect(effect); } }