diff --git a/Content.Server/Fax/FaxSystem.cs b/Content.Server/Fax/FaxSystem.cs
index 0a3a294f92b..38b781970f2 100644
--- a/Content.Server/Fax/FaxSystem.cs
+++ b/Content.Server/Fax/FaxSystem.cs
@@ -477,6 +477,13 @@ public void Copy(EntityUid uid, FaxMachineComponent? component, FaxCopyMessage a
// Don't play component.SendSound - it clashes with the printing sound, which
// will start immediately.
+ // Frontier: check if paper should be destroyed on sending.
+ if (paper.DestroyOnFax)
+ {
+ DeleteFax(uid, sendEntity.Value, paper);
+ }
+ // End Frontier
+
UpdateUserInterface(uid, component);
_adminLogger.Add(LogType.Action,
@@ -550,6 +557,13 @@ public void Send(EntityUid uid, FaxMachineComponent? component, FaxSendMessage a
_audioSystem.PlayPvs(component.SendSound, uid);
+ // Frontier: check if paper should be destroyed on sending.
+ if (paper.DestroyOnFax)
+ {
+ DeleteFax(uid, sendEntity.Value, paper);
+ }
+ // End Frontier
+
UpdateUserInterface(uid, component);
}
@@ -616,4 +630,16 @@ private void NotifyAdmins(string faxName)
_chat.SendAdminAnnouncement(Loc.GetString("fax-machine-chat-notify", ("fax", faxName)));
_audioSystem.PlayGlobal("/Audio/Machines/high_tech_confirm.ogg", Filter.Empty().AddPlayers(_adminManager.ActiveAdmins), false, AudioParams.Default.WithVolume(-8f));
}
+
+ // Frontier: delete sensitive items on fax to prevent duplication
+ private void DeleteFax(EntityUid faxMachine, EntityUid itemToFax, PaperComponent paper)
+ {
+ if (paper.DestroyMessage != null)
+ {
+ _popupSystem.PopupEntity(Loc.GetString(paper.DestroyMessage), faxMachine);
+ }
+
+ Del(itemToFax);
+ }
+ // End Frontier
}
diff --git a/Content.Shared/Paper/PaperComponent.cs b/Content.Shared/Paper/PaperComponent.cs
index cd0758589db..1bb98d93f40 100644
--- a/Content.Shared/Paper/PaperComponent.cs
+++ b/Content.Shared/Paper/PaperComponent.cs
@@ -32,6 +32,17 @@ public sealed partial class PaperComponent : Component
[DataField("sound")]
public SoundSpecifier? Sound { get; private set; } = new SoundCollectionSpecifier("PaperScribbles", AudioParams.Default.WithVariation(0.1f));
+ // Frontier:
+ ///
+ /// Sound played after writing to the paper.
+ ///
+ [DataField]
+ public bool DestroyOnFax { get; private set; }
+
+ [DataField]
+ public string? DestroyMessage { get; private set; }
+ // End Frontier
+
[Serializable, NetSerializable]
public sealed class PaperBoundUserInterfaceState : BoundUserInterfaceState
{
diff --git a/Resources/Locale/en-US/_NF/fax/fax.ftl b/Resources/Locale/en-US/_NF/fax/fax.ftl
new file mode 100644
index 00000000000..c89eef5d443
--- /dev/null
+++ b/Resources/Locale/en-US/_NF/fax/fax.ftl
@@ -0,0 +1 @@
+fax-delete-paper-intellectual-property = NT intellectual property detected, destroying original document.
diff --git a/Resources/Prototypes/Entities/Structures/Machines/lathe.yml b/Resources/Prototypes/Entities/Structures/Machines/lathe.yml
index 6408d3e2f86..e68f3203159 100644
--- a/Resources/Prototypes/Entities/Structures/Machines/lathe.yml
+++ b/Resources/Prototypes/Entities/Structures/Machines/lathe.yml
@@ -505,6 +505,7 @@
- StationAnchorCircuitboard
- SalvageMagnetMachineCircuitboard
- SalvageTechFabCircuitboardNF # Frontier
+ - BlueprintLithographMachineCircuitboard # Frontier
dynamicRecipes:
- ThermomachineFreezerMachineCircuitBoard
- HellfireFreezerMachineCircuitBoard
@@ -971,7 +972,7 @@
- type: entity
id: MedicalTechFab
- parent: BaseLatheLube
+ parent: [ BaseLatheLube, BlueprintReceiverBase ] # Frontier: added BlueprintReceiverBase
name: medical techfab
description: Prints equipment for use by the medbay.
components:
diff --git a/Resources/Prototypes/Nyanotrasen/Entities/Structures/Machines/lathe.yml b/Resources/Prototypes/Nyanotrasen/Entities/Structures/Machines/lathe.yml
index 55383245a78..aa924743276 100644
--- a/Resources/Prototypes/Nyanotrasen/Entities/Structures/Machines/lathe.yml
+++ b/Resources/Prototypes/Nyanotrasen/Entities/Structures/Machines/lathe.yml
@@ -1,5 +1,5 @@
- type: entity
- parent: BaseLatheLube # Frontier: Protolathe