1
0

ActionUpgradeComponent.cs 811 B

12345678910111213141516171819202122232425
  1. using Robust.Shared.GameStates;
  2. using Robust.Shared.Prototypes;
  3. namespace Content.Shared.Actions;
  4. // For actions that can use basic upgrades
  5. // Not all actions should be upgradable
  6. [RegisterComponent, NetworkedComponent, Access(typeof(ActionUpgradeSystem))]
  7. public sealed partial class ActionUpgradeComponent : Component
  8. {
  9. /// <summary>
  10. /// Current Level of the action.
  11. /// </summary>
  12. [ViewVariables]
  13. public int Level = 1;
  14. /// <summary>
  15. /// What level(s) effect this action?
  16. /// You can skip levels, so you can have this entity change at level 2 but then won't change again until level 5.
  17. /// </summary>
  18. [DataField("effectedLevels"), ViewVariables]
  19. public Dictionary<int, EntProtoId> EffectedLevels = new();
  20. // TODO: Branching level upgrades
  21. }