Update ChemMasterSystem.cs
This commit is contained in:
@@ -42,6 +42,8 @@ namespace Content.Server.Chemistry.EntitySystems
|
||||
[ValidatePrototypeId<EntityPrototype>]
|
||||
private const string PillPrototypeId = "Pill";
|
||||
|
||||
private const int MaxPillsPerRequest = 50;
|
||||
|
||||
public override void Initialize()
|
||||
{
|
||||
base.Initialize();
|
||||
@@ -190,6 +192,12 @@ namespace Content.Server.Chemistry.EntitySystems
|
||||
if (message.Number == 0 || !_storageSystem.HasSpace((container, storage)))
|
||||
return;
|
||||
|
||||
if (message.Number > MaxPillsPerRequest)
|
||||
{
|
||||
_popupSystem.PopupCursor("ДИНАХУЙ", user);
|
||||
return;
|
||||
}
|
||||
|
||||
// Ensure the amount is valid.
|
||||
if (message.Dosage == 0 || message.Dosage > chemMaster.Comp.PillDosageLimit)
|
||||
return;
|
||||
|
||||
Reference in New Issue
Block a user