1 using System.Collections.Generic;
3 using Microsoft.Xna.Framework;
7 internal class RadiationParams: ISerializableEntity
9 public string Name => nameof(RadiationParams);
10 public Dictionary<Identifier, SerializableProperty> SerializableProperties {
get; }
12 [Serialize(defaultValue: -100f, isSaveable:
IsPropertySaveable.No,
"How much radiation the world starts with.")]
13 public float StartingRadiation {
get;
set; }
15 [Serialize(defaultValue: 100f, isSaveable:
IsPropertySaveable.No,
"How much radiation is added on each step.")]
16 public float RadiationStep {
get;
set; }
18 [Serialize(defaultValue: 10, isSaveable:
IsPropertySaveable.No,
"How many turns in radiation does it take for an outpost to be removed from the map.")]
19 public int CriticalRadiationThreshold {
get;
set; }
21 [Serialize(defaultValue: 3, isSaveable:
IsPropertySaveable.No,
"Minimum amount of outposts in the level that cannot be removed due to radiation.")]
22 public int MinimumOutpostAmount {
get;
set; }
24 [Serialize(defaultValue: 3f, isSaveable:
IsPropertySaveable.No,
"How fast the radiation increase animation goes.")]
25 public float AnimationSpeed {
get;
set; }
27 [Serialize(defaultValue: 10f, isSaveable:
IsPropertySaveable.No,
"How long it takes to apply more radiation damage while in a radiated zone.")]
28 public float RadiationDamageDelay {
get;
set; }
30 [Serialize(defaultValue: 1f, isSaveable:
IsPropertySaveable.No,
"How much is the radiation affliction increased by while in a radiated zone.")]
31 public float RadiationDamageAmount {
get;
set; }
33 [Serialize(defaultValue: -1.0f, isSaveable:
IsPropertySaveable.No,
"Maximum amount of radiation.")]
34 public float MaxRadiation {
get;
set; }
36 [Serialize(defaultValue:
"139,0,0,85", isSaveable:
IsPropertySaveable.No,
"The color of the radiated area.")]
37 public Color RadiationAreaColor {
get;
set; }
39 [Serialize(defaultValue:
"255,0,0,255", isSaveable:
IsPropertySaveable.No,
"The tint of the radiation border sprites.")]
40 public Color RadiationBorderTint {
get;
set; }
42 [Serialize(defaultValue: 16.66f, isSaveable:
IsPropertySaveable.No,
"Speed of the border spritesheet animation.")]
43 public float BorderAnimationSpeed {
get;
set; }
45 public RadiationParams(XElement element)
47 SerializableProperties = SerializableProperty.DeserializeProperties(
this, element);