Fix contraband never getting added to vend inventory (#32431)
* fix contraband never getting added to vend inventory * Revert "fix contraband never getting added to vend inventory" This reverts commit e7fb3a60c3cb6fcbf41d7f015f13dbc7b1c1901d. * readd setter method to system * fix again without reparenting
This commit is contained in:
@@ -192,6 +192,18 @@ namespace Content.Server.VendingMachines
|
||||
component.CanShoot = canShoot;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sets the <see cref="VendingMachineComponent.Contraband"/> property of the vending machine.
|
||||
/// </summary>
|
||||
public void SetContraband(EntityUid uid, bool contraband, VendingMachineComponent? component = null)
|
||||
{
|
||||
if (!Resolve(uid, ref component))
|
||||
return;
|
||||
|
||||
component.Contraband = contraband;
|
||||
Dirty(uid, component);
|
||||
}
|
||||
|
||||
public void Deny(EntityUid uid, VendingMachineComponent? vendComponent = null)
|
||||
{
|
||||
if (!Resolve(uid, ref vendComponent))
|
||||
|
||||
Reference in New Issue
Block a user