2021-02-27 04:12:09 +01:00
|
|
|
|
#nullable enable
|
|
|
|
|
|
using System;
|
2019-09-03 22:51:19 +02:00
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
|
using Robust.Shared.Prototypes;
|
|
|
|
|
|
using Robust.Shared.Serialization;
|
2021-03-05 01:08:38 +01:00
|
|
|
|
using Robust.Shared.Serialization.Manager.Attributes;
|
2019-09-03 22:51:19 +02:00
|
|
|
|
using Robust.Shared.Utility;
|
|
|
|
|
|
using Robust.Shared.ViewVariables;
|
|
|
|
|
|
|
|
|
|
|
|
namespace Content.Shared.Research
|
|
|
|
|
|
{
|
|
|
|
|
|
[NetSerializable, Serializable, Prototype("technology")]
|
2021-02-20 00:05:24 +01:00
|
|
|
|
public class TechnologyPrototype : IPrototype
|
2019-09-03 22:51:19 +02:00
|
|
|
|
{
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
/// The ID of this technology prototype.
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
[ViewVariables]
|
2021-05-04 15:37:16 +02:00
|
|
|
|
[DataField("id", required: true)]
|
2021-03-05 01:08:38 +01:00
|
|
|
|
public string ID { get; } = default!;
|
|
|
|
|
|
|
2019-09-03 22:51:19 +02:00
|
|
|
|
/// <summary>
|
|
|
|
|
|
/// The name this technology will have on user interfaces.
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
[ViewVariables]
|
2021-05-04 15:37:16 +02:00
|
|
|
|
[DataField("name")]
|
2021-03-05 01:08:38 +01:00
|
|
|
|
public string Name { get; } = string.Empty;
|
2019-09-03 22:51:19 +02:00
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
/// An icon that represent this technology.
|
|
|
|
|
|
/// </summary>
|
2021-05-04 15:37:16 +02:00
|
|
|
|
[DataField("icon")]
|
2021-03-05 01:08:38 +01:00
|
|
|
|
public SpriteSpecifier Icon { get; } = SpriteSpecifier.Invalid;
|
2019-09-03 22:51:19 +02:00
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
/// A short description of the technology.
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
[ViewVariables]
|
2021-05-04 15:37:16 +02:00
|
|
|
|
[DataField("description")]
|
2021-03-05 01:08:38 +01:00
|
|
|
|
public string Description { get; } = string.Empty;
|
2019-09-03 22:51:19 +02:00
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
/// The required research points to unlock this technology.
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
[ViewVariables]
|
2021-05-04 15:37:16 +02:00
|
|
|
|
[DataField("requiredPoints")]
|
2021-03-05 01:08:38 +01:00
|
|
|
|
public int RequiredPoints { get; }
|
2019-09-03 22:51:19 +02:00
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
/// A list of technology IDs required to unlock this technology.
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
[ViewVariables]
|
2021-05-04 15:37:16 +02:00
|
|
|
|
[DataField("requiredTechnologies")]
|
2021-03-05 01:08:38 +01:00
|
|
|
|
public List<string> RequiredTechnologies { get; } = new();
|
2019-09-03 22:51:19 +02:00
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
/// A list of recipe IDs this technology unlocks.
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
[ViewVariables]
|
2021-05-04 15:37:16 +02:00
|
|
|
|
[DataField("unlockedRecipes")]
|
2021-03-05 01:08:38 +01:00
|
|
|
|
public List<string> UnlockedRecipes { get; } = new();
|
2019-09-03 22:51:19 +02:00
|
|
|
|
}
|
|
|
|
|
|
}
|