fix emitter examining (#13369)
This commit is contained in:
@@ -113,6 +113,13 @@ public class GunComponent : Component
|
|||||||
|
|
||||||
[DataField("selectModeAction")]
|
[DataField("selectModeAction")]
|
||||||
public InstantAction? SelectModeAction;
|
public InstantAction? SelectModeAction;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Whether or not information about
|
||||||
|
/// the gun will be shown on examine.
|
||||||
|
/// </summary>
|
||||||
|
[DataField("showExamineText")]
|
||||||
|
public bool ShowExamineText = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
[Flags]
|
[Flags]
|
||||||
|
|||||||
@@ -12,7 +12,7 @@ public abstract partial class SharedGunSystem
|
|||||||
{
|
{
|
||||||
private void OnExamine(EntityUid uid, GunComponent component, ExaminedEvent args)
|
private void OnExamine(EntityUid uid, GunComponent component, ExaminedEvent args)
|
||||||
{
|
{
|
||||||
if (!args.IsInDetailsRange)
|
if (!args.IsInDetailsRange || !component.ShowExamineText)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
args.PushMarkup(Loc.GetString("gun-selected-mode-examine", ("color", ModeExamineColor), ("mode", GetLocSelector(component.SelectedMode))));
|
args.PushMarkup(Loc.GetString("gun-selected-mode-examine", ("color", ModeExamineColor), ("mode", GetLocSelector(component.SelectedMode))));
|
||||||
|
|||||||
@@ -37,6 +37,7 @@
|
|||||||
map: ["enum.StorageVisualLayers.Lock"]
|
map: ["enum.StorageVisualLayers.Lock"]
|
||||||
- type: Emitter
|
- type: Emitter
|
||||||
- type: Gun
|
- type: Gun
|
||||||
|
showExamineText: false
|
||||||
fireRate: 10 #just has to be fast enough to keep up with upgrades
|
fireRate: 10 #just has to be fast enough to keep up with upgrades
|
||||||
selectedMode: SemiAuto
|
selectedMode: SemiAuto
|
||||||
availableModes:
|
availableModes:
|
||||||
|
|||||||
Reference in New Issue
Block a user