Xenoborg jammer now ignores xenoborg associated frequencies (#38005)
* stop jammer from jamming radio of certain frequency * xenoborg jammer no longer jamms xenoborg radio * stop jammer from jamming device network signals from certain frequency * xenoborg jammer no longer jamms xenoborg camera signal * the old tale of the missing ; * backwards * fix issue with readonly * comments to the frequencies excluded * triple typo * clearer summary * add summary * fixed 4th hidden typo
This commit is contained in:
@@ -60,4 +60,34 @@ public abstract class SharedDeviceNetworkJammerSystem : EntitySystem
|
||||
ent.Comp.JammableNetworks.Clear();
|
||||
Dirty(ent);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Enables this entity to stop packets with the specified frequency from being jammmed.
|
||||
/// </summary>
|
||||
public void AddExcludedFrequency(Entity<DeviceNetworkJammerComponent> ent, uint frequency)
|
||||
{
|
||||
if (ent.Comp.FrequenciesExcluded.Add(frequency))
|
||||
Dirty(ent);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Stops this entity to stop packets with the specified frequency from being jammmed.
|
||||
/// </summary>
|
||||
public void RemoveExcludedFrequency(Entity<DeviceNetworkJammerComponent> ent, uint frequency)
|
||||
{
|
||||
if (ent.Comp.FrequenciesExcluded.Remove(frequency))
|
||||
Dirty(ent);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Stops this entity to stop packets with any frequency from being jammmed.
|
||||
/// </summary>
|
||||
public void ClearExcludedFrequency(Entity<DeviceNetworkJammerComponent> ent)
|
||||
{
|
||||
if (ent.Comp.FrequenciesExcluded.Count == 0)
|
||||
return;
|
||||
|
||||
ent.Comp.FrequenciesExcluded.Clear();
|
||||
Dirty(ent);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user