using Robust.Shared.GameStates; using Robust.Shared.Prototypes; using Robust.Shared.Serialization; using Robust.Shared.Serialization.TypeSerializers.Implementations.Custom.Prototype; namespace Content.Shared.RatKing; [RegisterComponent, NetworkedComponent, Access(typeof(SharedRatKingSystem))] [AutoGenerateComponentState] public sealed partial class RatKingComponent : Component { [DataField("actionRaiseArmy", customTypeSerializer: typeof(PrototypeIdSerializer))] public string ActionRaiseArmy = "ActionRatKingRaiseArmy"; /// /// The action for the Raise Army ability /// [DataField("actionRaiseArmyEntity")] public EntityUid? ActionRaiseArmyEntity; /// /// The amount of hunger one use of Raise Army consumes /// [ViewVariables(VVAccess.ReadWrite), DataField("hungerPerArmyUse", required: true)] public float HungerPerArmyUse = 25f; /// /// The entity prototype of the mob that Raise Army summons /// [ViewVariables(VVAccess.ReadWrite), DataField("armyMobSpawnId", customTypeSerializer: typeof(PrototypeIdSerializer))] public string ArmyMobSpawnId = "MobRatServant"; [DataField("actionDomain", customTypeSerializer: typeof(PrototypeIdSerializer))] public string ActionDomain = "ActionRatKingDomain"; /// /// The action for the Domain ability /// [DataField("actionDomainEntity")] public EntityUid? ActionDomainEntity; /// /// The amount of hunger one use of Domain consumes /// [DataField("hungerPerDomainUse", required: true), ViewVariables(VVAccess.ReadWrite)] public float HungerPerDomainUse = 50f; /// /// How many moles of ammonia are released after one us of Domain /// [DataField("molesAmmoniaPerDomain"), ViewVariables(VVAccess.ReadWrite)] public float MolesAmmoniaPerDomain = 200f; /// /// The current order that the Rat King assigned. /// [DataField("currentOrders"), ViewVariables(VVAccess.ReadWrite)] [AutoNetworkedField] public RatKingOrderType CurrentOrder = RatKingOrderType.Loose; /// /// The servants that the rat king is currently controlling /// [DataField("servants")] public HashSet Servants = new(); [DataField("actionOrderStay", customTypeSerializer: typeof(PrototypeIdSerializer))] public string ActionOrderStay = "ActionRatKingOrderStay"; [DataField("actionOrderStayEntity")] public EntityUid? ActionOrderStayEntity; [DataField("actionOrderFollow", customTypeSerializer: typeof(PrototypeIdSerializer))] public string ActionOrderFollow = "ActionRatKingOrderFollow"; [DataField("actionOrderFollowEntity")] public EntityUid? ActionOrderFollowEntity; [DataField("actionOrderCheeseEm", customTypeSerializer: typeof(PrototypeIdSerializer))] public string ActionOrderCheeseEm = "ActionRatKingOrderCheeseEm"; [DataField("actionOrderCheeseEmEntity")] public EntityUid? ActionOrderCheeseEmEntity; [DataField("actionOrderLoose", customTypeSerializer: typeof(PrototypeIdSerializer))] public string ActionOrderLoose = "ActionRatKingOrderLoose"; [DataField("actionOrderLooseEntity")] public EntityUid? ActionOrderLooseEntity; /// /// A dictionary with an order type to the corresponding callout dataset. /// [DataField("orderCallouts")] public Dictionary OrderCallouts = new() { { RatKingOrderType.Stay, "RatKingCommandStay" }, { RatKingOrderType.Follow, "RatKingCommandFollow" }, { RatKingOrderType.CheeseEm, "RatKingCommandCheeseEm" }, { RatKingOrderType.Loose, "RatKingCommandLoose" } }; } [Serializable, NetSerializable] public enum RatKingOrderType : byte { Stay, Follow, CheeseEm, Loose }