コード例 #1
0
 public Teleport(
     EffectName name,
     BehaviourName?waitBefore     = null,
     IList <Validator>?validators = null) : base(name, $"{nameof(Effect)}.{nameof(Teleport)}", validators ?? new List <Validator>())
 {
     WaitBefore = waitBefore;
 }
コード例 #2
0
 public CreateEntity(
     EffectName name,
     EntityName entityToCreate,
     IList <BehaviourName>?initialEntityBehaviours = null,
     IList <Validator>?validators = null) : base(name, $"{nameof(Effect)}.{nameof(CreateEntity)}", validators ?? new List <Validator>())
 {
     EntityToCreate          = entityToCreate;
     InitialEntityBehaviours = initialEntityBehaviours ?? new List <BehaviourName>();
 }
コード例 #3
0
 public Reload(
     EffectName name,
     BehaviourName ammunitionToTarget,
     Location?location            = null,
     IList <Validator>?validators = null) : base(name, $"{nameof(Effect)}.{nameof(Reload)}", validators ?? new List <Validator>())
 {
     AmmunitionToTarget = ammunitionToTarget;
     Location           = location ?? Location.Inherited;
 }
コード例 #4
0
 public ModifyAbility(
     EffectName name,
     AbilityName abilityToModify,
     AbilityName modifiedAbility,
     IList <Validator>?validators = null) : base(name, $"{nameof(Effect)}.{nameof(ModifyAbility)}", validators ?? new List <Validator>())
 {
     AbilityToModify = abilityToModify;
     ModifiedAbility = modifiedAbility;
 }
コード例 #5
0
 public Destroy(
     EffectName name,
     Location?target = null,
     IList <Validator>?validators = null,
     bool blocksBehaviours        = false) : base(name, $"{nameof(Effect)}.{nameof(Destroy)}", validators ?? new List <Validator>())
 {
     Target           = target ?? Location.Self;
     BlocksBehaviours = blocksBehaviours;
 }
コード例 #6
0
 public ApplyBehaviour(
     EffectName name,
     IList <BehaviourName> behavioursToApply,
     Location?location            = null,
     IList <Flag>?filterFlags     = null,
     IList <Validator>?validators = null) : base(name, $"{nameof(Effect)}.{nameof(ApplyBehaviour)}", validators ?? new List <Validator>())
 {
     BehavioursToApply = behavioursToApply;
     Location          = location ?? Location.Inherited;
     FilterFlags       = filterFlags ?? new List <Flag>();
 }
コード例 #7
0
 public Force(
     EffectName name,
     Location from,
     int amount,
     IList <EffectName>?onCollisionEffects = null,
     IList <Validator>?validators          = null) : base(name, $"{nameof(Effect)}.{nameof(Force)}", validators ?? new List <Validator>())
 {
     From               = from;
     Amount             = amount;
     OnCollisionEffects = onCollisionEffects ?? new List <EffectName>();
 }
コード例 #8
0
 public ModifyPlayer(
     EffectName name,
     IList <Flag> playerFilterFlags,
     IList <Flag>?modifyFlags = null,
     IList <ResourceModification>?resourceModifications = null,
     IList <Validator>?validators = null) : base(name, $"{nameof(Effect)}.{nameof(ModifyPlayer)}", validators ?? new List <Validator>())
 {
     PlayerFilterFlags     = playerFilterFlags;
     ModifyFlags           = modifyFlags ?? new List <Flag>();
     ResourceModifications = resourceModifications ?? new List <ResourceModification>();
 }
コード例 #9
0
 public Damage(
     EffectName name,
     DamageType damageType,
     Amount?amount                = null,
     CombatAttributes?bonusTo     = null,
     Amount?bonusAmount           = null,
     Location?location            = null,
     IList <Flag>?filterFlags     = null,
     IList <Validator>?validators = null) : base(name, $"{nameof(Effect)}.{nameof(Damage)}", validators ?? new List <Validator>())
 {
     DamageType  = damageType;
     Amount      = amount ?? new Amount(0);
     BonusTo     = bonusTo;
     BonusAmount = bonusAmount ?? new Amount(0);
     Location    = location ?? Location.Inherited;
     FilterFlags = filterFlags ?? new List <Flag>();
 }
コード例 #10
0
 public Search(
     EffectName name,
     int radius,
     IList <Flag> searchFlags,
     IList <Flag> filterFlags,
     IList <EffectName>?effects = null,
     Location?location          = null,
     Shape?shape                  = null,
     bool?ignoreCenter            = null,
     IList <Validator>?validators = null,
     bool?usedForValidator        = null) : base(name, $"{nameof(Effect)}.{nameof(Search)}", validators ?? new List <Validator>())
 {
     Radius           = radius;
     SearchFlags      = searchFlags;
     FilterFlags      = filterFlags;
     Effects          = effects ?? new List <EffectName>();
     Location         = location ?? Location.Inherited;
     Shape            = shape ?? Shape.Circle;
     IgnoreCenter     = ignoreCenter ?? false;
     UsedForValidator = usedForValidator ?? false;
 }
コード例 #11
0
 protected Effect(EffectName name, string type, IList <Validator> validators)
 {
     Name       = name;
     Type       = type;
     Validators = validators;
 }