public virtual void ShootEffects(int clipInfoIndex) { Host.AssertClient(); if (clipInfoIndex < 0 || clipInfoIndex >= ClipInfos.Length) { return; } ClipInfo clipInfo = ClipInfos[clipInfoIndex]; if (clipInfo == null) { return; } if (CarriableInfo.Category != CarriableCategories.Melee) { foreach (KeyValuePair <string, string> keyValuePair in clipInfo.ShootEffectList) { Particles.Create(keyValuePair.Key, EffectEntity, keyValuePair.Value); } } if (IsLocalPawn && clipInfo.ShakeEffect != null) { _ = new Perlin(clipInfo.ShakeEffect.Length, clipInfo.ShakeEffect.Speed, clipInfo.ShakeEffect.Size, clipInfo.ShakeEffect.Rotation); } ViewModelEntity?.SetAnimParameter("fire", true); CrosshairPanel?.CreateEvent("fire"); }
protected override void ShootEffects() { Host.AssertClient(); if (Owner == Local.Pawn) { new Perlin(0.5f, 4.0f, 1.0f, 0.5f); } ViewModelEntity?.SetAnimBool("fire", true); CrosshairPanel?.CreateEvent("fire"); }
protected virtual void ShootEffects() { Host.AssertClient(); Particles.Create("particles/pistol_muzzleflash.vpcf", EffectEntity, "muzzle"); if (IsLocalPawn) { _ = new Sandbox.ScreenShake.Perlin(); } ViewModelEntity?.SetAnimParameter("fire", true); CrosshairPanel?.CreateEvent("fire"); }
protected virtual void DoubleShootEffects() { Host.AssertClient(); Particles.Create("particles/pistol_muzzleflash.vpcf", EffectEntity, "muzzle"); ViewModelEntity?.SetAnimBool("fire_double", true); CrosshairPanel?.CreateEvent("fire"); if (IsLocalPawn) { new Perlin(3.0f, 3.0f, 3.0f); } }
protected override void ShootEffects() { Host.AssertClient(); Particles.Create("particles/pistol_muzzleflash.vpcf", EffectEntity, "muzzle"); Particles.Create("particles/pistol_ejectbrass.vpcf", EffectEntity, "ejection_point"); if (Owner == Local.Pawn) { new Sandbox.ScreenShake.Perlin(0.5f, 4.0f, 1.0f, 0.5f); } ViewModelEntity?.SetAnimParameter("fire", true); CrosshairPanel?.CreateEvent("fire"); }
protected override void ShootEffects() { Host.AssertClient(); Particles.Create("particles/pistol_muzzleflash.vpcf", EffectEntity, "muzzle"); Particles.Create("particles/pistol_ejectbrass.vpcf", EffectEntity, "ejection_point"); ViewModelEntity?.SetAnimBool("fire", true); if (IsLocalPawn) { new Perlin(1.0f, 1.5f, 2.0f); } CrosshairPanel?.CreateEvent("fire"); }
protected virtual void ShootEffects() { Host.AssertClient(); var particle = Particles.Create("particles/pistol_muzzleflash.vpcf", EffectEntity, "muzzle"); var Light = new Light(EffectEntity.Position, 1000, Color.Yellow * 100); //EffectEntity.AddChild(Light); if (IsLocalPawn) { new Perlin(); } ViewModelEntity?.SetAnimBool("fire", true); CrosshairPanel?.CreateEvent("fire"); HandleLight(Light); }