Data Rework Content Edition (#82)
* WiP Data Rework. * Convert stationstation to new map format. * stationstation.yml v2 * Update submodule
This commit is contained in:
committed by
GitHub
parent
8c874c76dc
commit
b34591ab59
@@ -1,4 +1,5 @@
|
||||
using SS14.Shared.GameObjects;
|
||||
using SS14.Shared.Serialization;
|
||||
using SS14.Shared.Utility;
|
||||
using YamlDotNet.RepresentationModel;
|
||||
|
||||
@@ -9,16 +10,20 @@ namespace Content.Server.GameObjects.Components.Interactable.Tools
|
||||
/// <summary>
|
||||
/// For tool interactions that have a delay before action this will modify the rate, time to wait is divided by this value
|
||||
/// </summary>
|
||||
public float SpeedModifier { get; set; } = 1;
|
||||
|
||||
public override void LoadParameters(YamlMappingNode mapping)
|
||||
public float SpeedModifier
|
||||
{
|
||||
if (mapping.TryGetNode("Speed", out YamlNode node))
|
||||
{
|
||||
SpeedModifier = node.AsFloat();
|
||||
}
|
||||
get => _speedModifier;
|
||||
set => _speedModifier = value;
|
||||
}
|
||||
|
||||
private float _speedModifier = 1;
|
||||
|
||||
public override void ExposeData(ObjectSerializer serializer)
|
||||
{
|
||||
base.ExposeData(serializer);
|
||||
|
||||
serializer.DataField(ref _speedModifier, "Speed", 1);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Status modifier which determines whether or not we can act as a tool at this time
|
||||
/// </summary>
|
||||
|
||||
Reference in New Issue
Block a user