コード例 #1
0
ファイル: PasswordHash.cs プロジェクト: jestin/libsodium-net
        /// <summary>Derives a secret key of any size from a password and a salt.</summary>
        /// <param name="password">The password.</param>
        /// <param name="salt">The salt.</param>
        /// <param name="limit">The limit for computation.</param>
        /// <param name="outputLength">The length of the computed output array.</param>
        /// <returns>Returns a byte array of the given size.</returns>
        /// <exception cref="ArgumentNullException"></exception>
        /// <exception cref="ArgumentOutOfRangeException"></exception>
        /// <exception cref="SaltOutOfRangeException"></exception>
        /// <exception cref="OutOfMemoryException"></exception>
        public static byte[] ScryptHashBinary(byte[] password, byte[] salt, Strength limit = Strength.Interactive, long outputLength = SCRYPT_SALSA208_SHA256_SALTBYTES)
        {
            int memLimit;
              long opsLimit;

              switch (limit)
              {
            case Strength.Interactive:
              opsLimit = OPSLIMIT_INTERACTIVE;
              memLimit = MEMLIMIT_INTERACTIVE;
              break;
            case Strength.Moderate:
              opsLimit = OPSLIMIT_MODERATE;
              memLimit = MEMLIMIT_MODERATE;
              break;
            case Strength.Sensitive:
              opsLimit = OPSLIMIT_SENSITIVE;
              memLimit = MEMLIMIT_SENSITIVE;
              break;
            default:
              opsLimit = OPSLIMIT_INTERACTIVE;
              memLimit = MEMLIMIT_INTERACTIVE;
              break;
              }

              return ScryptHashBinary(password, salt, opsLimit, memLimit, outputLength);
        }
コード例 #2
0
ファイル: Blend.cs プロジェクト: serakrin/presentations
 public Blend()
 {
     Name = String.Empty;
     Drinks = new HashedSet<Drink>();
     Acidity = 0;
     Strength = new Strength();
     Upcharge = 0M;
 }
コード例 #3
0
ファイル: Controls.cs プロジェクト: TylerStein/Capstone
    //Use this for initialization
    void Start()
    {
        currentHealth = maxHealth;
        currentStamina = maxStamina;
        currentMS = 0;

        strength = GetComponent<Strength>();
        agility = GetComponent<Agility>();
        haste = GetComponent<Haste>();
        perception = GetComponent<Perception>();
        intelligence = GetComponent<Intelligence>();
        wisdom = GetComponent<Wisdom>();

        cont = GetComponent<CharacterController>();
        Cursor.lockState = CursorLockMode.Locked;
        Cursor.visible = false;
        cameraReference = GameObject.FindWithTag("cameraReference");
        lookTarget = GameObject.FindWithTag("LookTarget");
    }
コード例 #4
0
        protected override void OnTarget(object o)
        {
            IPoint3D p = o as IPoint3D;

            if (p != null && CheckSequence())
            {
                Rectangle2D rec = new Rectangle2D(p.X - 3, p.Y - 3, 6, 6);
                Skulls = new List <Item>();

                Item skull = new InternalItem();
                skull.MoveToWorld(new Point3D(rec.X, rec.Y, Caster.Map.GetAverageZ(rec.X, rec.Y)), Caster.Map);
                Skulls.Add(skull);

                skull = new InternalItem();
                skull.MoveToWorld(new Point3D(rec.X + rec.Width, rec.Y + rec.Height, Caster.Map.GetAverageZ(rec.X + rec.Width, rec.Y + rec.Height)), Caster.Map);
                Skulls.Add(skull);

                skull = new InternalItem();
                skull.MoveToWorld(new Point3D(rec.X + rec.Width, rec.Y, Caster.Map.GetAverageZ(rec.X + rec.Width, rec.Y)), Caster.Map);
                Skulls.Add(skull);

                skull = new InternalItem();
                skull.MoveToWorld(new Point3D(rec.X, rec.Y + rec.Height, Caster.Map.GetAverageZ(rec.X, rec.Y + rec.Height)), Caster.Map);
                Skulls.Add(skull);

                skull = new InternalItem();
                skull.MoveToWorld(new Point3D(rec.X + (rec.Width / 2), rec.Y + (rec.Height / 2), Caster.Map.GetAverageZ(rec.X + (rec.Width / 2), rec.Y + (rec.Height / 2))), Caster.Map);
                Skulls.Add(skull);

                Zone     = rec;
                Strength = (int)((Caster.Skills[CastSkill].Value + Caster.Skills[DamageSkill].Value + (GetMasteryLevel() * 20)) / 3.75);
                Expires  = DateTime.UtcNow + TimeSpan.FromSeconds(10);

                BuffInfo.AddBuff(Caster, new BuffInfo(BuffIcon.Conduit, 1155901, 1156053, Strength.ToString())); //Targeted Necromancy spells used on a target within the Conduit field will affect all valid targets within the field at ~1_PERCT~% strength.

                BeginTimer();
            }
        }
コード例 #5
0
        public void Effect(Player player, string effect, int level, int duration)
        {
            if ("clear".Equals(effect, StringComparison.InvariantCultureIgnoreCase))
            {
                player.Level.BroadcastMessage($"Removed all effects for {player.Username}.", MessageType.Raw);
                player.RemoveAllEffects();
                return;
            }

            EffectType effectType;

            if (Enum.TryParse(effect, true, out effectType))
            {
                Effect eff = null;
                switch (effectType)
                {
                case EffectType.Speed:
                    eff = new Speed();
                    break;

                case EffectType.Slowness:
                    eff = new Slowness();
                    break;

                case EffectType.Haste:
                    eff = new Haste();
                    break;

                case EffectType.MiningFatigue:
                    eff = new MiningFatigue();
                    break;

                case EffectType.Strength:
                    eff = new Strength();
                    break;

                case EffectType.InstantHealth:
                    eff = new InstantHealth();
                    break;

                case EffectType.InstantDamage:
                    eff = new InstantDamage();
                    break;

                case EffectType.JumpBoost:
                    eff = new JumpBoost();
                    break;

                case EffectType.Nausea:
                    eff = new Nausea();
                    break;

                case EffectType.Regeneration:
                    eff = new Regeneration();
                    break;

                case EffectType.Resistance:
                    eff = new Resistance();
                    break;

                case EffectType.FireResistance:
                    eff = new FireResistance();
                    break;

                case EffectType.WaterBreathing:
                    eff = new WaterBreathing();
                    break;

                case EffectType.Invisibility:
                    eff = new Invisibility();
                    break;

                case EffectType.Blindness:
                    eff = new Blindness();
                    break;

                case EffectType.NightVision:
                    eff = new NightVision();
                    break;

                case EffectType.Hunger:
                    eff = new Hunger();
                    break;

                case EffectType.Weakness:
                    eff = new Weakness();
                    break;

                case EffectType.Poison:
                    eff = new Poison();
                    break;

                case EffectType.Wither:
                    eff = new Wither();
                    break;

                case EffectType.HealthBoost:
                    eff = new HealthBoost();
                    break;

                case EffectType.Absorption:
                    eff = new Absorption();
                    break;

                case EffectType.Saturation:
                    eff = new Saturation();
                    break;
                }

                if (eff != null)
                {
                    eff.Level     = level;
                    eff.Duration  = duration;
                    eff.Particles = false;

                    player.SetEffect(eff);
                    player.Level.BroadcastMessage($"{player.Username} added effect {effectType} with strenght {level}", MessageType.Raw);
                }
            }
        }
コード例 #6
0
 public Capuccino()
 {
     DrinkStrength = Strength.Normal;
 }
コード例 #7
0
ファイル: DeltaBlue.cs プロジェクト: Smith-yue/coreclr
    public Variable offset; // offset input variable

    // Install a scale constraint with the given strength on the given variables.
    public ScaleConstraint(Variable src, Variable scale, Variable offset,
                   Variable dest, Strength strength)
    {
        // Curse this wretched language for insisting that constructor invocation
        // must be the first thing in a method...
        // ..because of that, we must copy the code from the inherited
        // constructors.
        this.strength = strength;
        v1 = src;
        v2 = dest;
        direction = nodirection;
        this.scale = scale;
        this.offset = offset;
        addConstraint();
    }
コード例 #8
0
ファイル: DeltaBlue.cs プロジェクト: Smith-yue/coreclr
    public BinaryConstraint() { } // this has to be here because of
                                  // Java's constructor idiocy.

    public BinaryConstraint(Variable var1, Variable var2, Strength strength)
      : base(strength)
    {
        v1 = var1;
        v2 = var2;
        direction = nodirection;
        addConstraint();
    }
コード例 #9
0
ファイル: DeltaBlue.cs プロジェクト: Smith-yue/coreclr
    public Boolean satisfied; // true if I am currently satisfied

    public UnaryConstraint(Variable v, Strength strength) : base(strength)

    {
        myOutput = v;
        satisfied = false;
        addConstraint();
    }
コード例 #10
0
 }                                             //valid
 public override void getHeroStats()
 {
     System.Console.WriteLine("Hero Name: " + myHero.HeroName + " Hero Type: " + myHero.HeroType + " Strength:" + Strength.ToString() +
                              " Speed:" + Speed.ToString() + " Health:" + Health.ToString());
 }
コード例 #11
0
ファイル: CoreCommands.cs プロジェクト: CavinMiana/MiNET
        public void Effect(Player player, string effect, int level = 1, int duration = 20)
        {
            EffectType effectType;

            if (Enum.TryParse(effect, true, out effectType))
            {
                Effect eff = null;
                switch (effectType)
                {
                case EffectType.Speed:
                    eff = new Speed();
                    break;

                case EffectType.Slowness:
                    eff = new Slowness();
                    break;

                case EffectType.Haste:
                    eff = new Haste();
                    break;

                case EffectType.MiningFatigue:
                    eff = new MiningFatigue();
                    break;

                case EffectType.Strenght:
                    eff = new Strength();
                    break;

                case EffectType.InstandHealth:
                    eff = new InstandHealth();
                    break;

                case EffectType.InstantDamage:
                    eff = new InstantDamage();
                    break;

                case EffectType.JumpBoost:
                    eff = new JumpBoost();
                    break;

                case EffectType.Nausea:
                    eff = new Nausea();
                    break;

                case EffectType.Regeneration:
                    eff = new Regeneration();
                    break;

                case EffectType.Resistance:
                    eff = new Resistance();
                    break;

                case EffectType.FireResistance:
                    eff = new FireResistance();
                    break;

                case EffectType.WaterBreathing:
                    eff = new WaterBreathing();
                    break;

                case EffectType.Invisibility:
                    eff = new Invisibility();
                    break;

                case EffectType.Blindness:
                    eff = new Blindness();
                    break;

                case EffectType.NightVision:
                    eff = new NightVision();
                    break;

                case EffectType.Hunger:
                    eff = new Hunger();
                    break;

                case EffectType.Weakness:
                    eff = new Weakness();
                    break;

                case EffectType.Poison:
                    eff = new Poison();
                    break;

                case EffectType.Wither:
                    eff = new Wither();
                    break;

                case EffectType.HealthBoost:
                    eff = new HealthBoost();
                    break;

                case EffectType.Absorption:
                    eff = new Absorption();
                    break;

                case EffectType.Saturation:
                    eff = new Saturation();
                    break;

                case EffectType.Glowing:
                    eff = new Glowing();
                    break;

                case EffectType.Levitation:
                    eff = new Levitation();
                    break;
                }

                if (eff != null)
                {
                    eff.Level    = level;
                    eff.Duration = duration;

                    player.SetEffect(eff);
                    player.Level.BroadcastMessage(string.Format("{0} added effect {1} with strenght {2}", player.Username, effectType, level), MessageType.Raw);
                }
            }
        }
コード例 #12
0
 public HitEffectParams[] GetDamageEffect(Strength strength)
 {
     return(this.hitEffects.GetObject(AffectEffect.Damage.ToString(), strength.ToString()));
 }
コード例 #13
0
ファイル: Draft.cs プロジェクト: LazyBallsZealots/dnd-ddd
 internal override void SetStrength(Character character, int strength) => character.Strength = Strength.FromInteger(strength);
コード例 #14
0
        public void Calculate_EntropyIsValid_ResultAsExpected(Double entropy, Strength strength)
        {
            Strength actual = this.GetInstance().Calculate(entropy);

            Assert.That(actual, Is.EqualTo(strength));
        }
コード例 #15
0
        public void Calculate_EntropyPositiveMaximum_ResultIsStrengthVeryStrong()
        {
            Strength actual = this.GetInstance().Calculate(Double.MaxValue);

            Assert.That(actual, Is.EqualTo(Strength.VeryStrong));
        }
コード例 #16
0
        public void Calculate_EntropyPositiveInfinity_ResultIsStrengthUnknown()
        {
            Strength actual = this.GetInstance().Calculate(Double.PositiveInfinity);

            Assert.That(actual, Is.EqualTo(Strength.Unknown));
        }
コード例 #17
0
ファイル: DeltaBlue.cs プロジェクト: Smith-yue/coreclr
 // Attempt to assign the given value to me using the given strength.
 public void setValue(int value, Strength strength)
 {
     EditConstraint e = new EditConstraint(this, strength);
     if (e.isSatisfied())
     {
         this.value = value;
         deltablue.planner.propagateFrom(this);
     }
     e.destroyConstraint();
 }
コード例 #18
0
 public WienerMelange(Strength coffeeStrength)
 {
     Name          = "Wiener Melange";
     DrinkStrength = coffeeStrength;
     BasePrice     = 1.50;
 }
コード例 #19
0
ファイル: DeltaBlue.cs プロジェクト: Smith-yue/coreclr
 // Install a stay constraint with the given strength on the given variable.
 public StayConstraint(Variable v, Strength str) : base(v, str) { }
コード例 #20
0
ファイル: DrinkFactory.cs プロジェクト: joeryvanegmond/DPINT
        public static IDrink CreateDrink(DrinkInformation info, Strength strength, Dictionary <string, Amount> additionals)
        {
            IDrink baseDrink;

            switch (info.Name)
            {
            case "Coffee":
                baseDrink = new Drink(info.Name);
                baseDrink = new CoffeeDecorator(baseDrink, strength, 1);
                break;

            case "Coffee With Milk":
                baseDrink = new Drink(info.Name);
                baseDrink = new CoffeeDecorator(baseDrink, strength, 1);
                baseDrink = new MilkDecorator(baseDrink, additionals["milk"], 0.1);
                break;

            case "Coffee With Sugar":
                baseDrink = new Drink(info.Name);
                baseDrink = new CoffeeDecorator(baseDrink, strength, 1);
                baseDrink = new SugarDecorator(baseDrink, additionals["sugar"], 0.1);
                break;

            case "Coffee With Sugar And Milk":
                baseDrink = new Drink(info.Name);
                baseDrink = new CoffeeDecorator(baseDrink, strength, 1);
                baseDrink = new SugarDecorator(baseDrink, additionals["sugar"], 0.1);
                baseDrink = new MilkDecorator(baseDrink, additionals["milk"], 0.1);
                break;

            case "Espresso":
                baseDrink = new Drink(info.Name);
                baseDrink = new CoffeeDecorator(baseDrink, Strength.Strong, 1.7, Amount.Few);
                break;

            case "Capuccino":
                baseDrink = new Drink(info.Name);
                baseDrink = new CoffeeDecorator(baseDrink, Strength.Strong, 1.7, Amount.Few);
                baseDrink = new MilkDecorator(baseDrink, additionals["milk"], 0.1);
                break;

            case "Wiener Melange":
                baseDrink = new Drink(info.Name);
                baseDrink = new CoffeeDecorator(baseDrink, strength, 1.6);
                baseDrink = new SugarDecorator(baseDrink, Amount.Normal, 0.1);
                baseDrink = new WhippedCreamDecorator(baseDrink, 0.3);
                break;

            case "Café au Lait":
                baseDrink = new Drink(info.Name);
                baseDrink = new CoffeeDecorator(baseDrink, strength, 1.4);
                baseDrink = new MilkDecorator(baseDrink, Amount.Extra, 0.1);
                break;

            case "Chocolate":
                baseDrink = new HotChocolateDrinkAdapter();
                break;

            case "Chocolate Deluxe":
                IHotChocolateDrinkAdapter hotChocolate = new HotChocolateDrinkAdapter();
                baseDrink = new HotChocolateDeluxeDecorator(hotChocolate);
                break;

            case "Tea":
                ITeaDrinkAdapter tea = new TeaDrinkAdapter();
                baseDrink = new TeaBlendDecorator(tea, info.Blend);
                break;

            case "Tea With Sugar":
                ITeaDrinkAdapter teaWithSugar = new TeaDrinkAdapter();
                baseDrink = new TeaBlendDecorator(teaWithSugar, info.Blend);
                baseDrink = new SugarDecorator(baseDrink, Amount.Normal, 0.1);
                break;

            case "Irish Coffee":
                baseDrink = new Drink(info.Name);
                baseDrink = new CoffeeDecorator(baseDrink, strength, 2.5);
                baseDrink = new SugarDecorator(baseDrink, Amount.Normal, 0.1);
                baseDrink = new WhiskeyDecorator(baseDrink);
                baseDrink = new WhippedCreamDecorator(baseDrink, 0.3);
                break;

            case "Spanish Coffee":
                baseDrink = new Drink(info.Name);
                baseDrink = new CoffeeDecorator(baseDrink, strength, 2.5);
                baseDrink = new SugarDecorator(baseDrink, Amount.Normal, 0.1);
                baseDrink = new CognacDecorator(baseDrink);
                baseDrink = new CointreauDecorator(baseDrink);
                baseDrink = new WhippedCreamDecorator(baseDrink, 0.3);
                break;

            case "Italian Coffee":
                baseDrink = new Drink(info.Name);
                baseDrink = new CoffeeDecorator(baseDrink, strength, 2.5);
                baseDrink = new SugarDecorator(baseDrink, Amount.Normal, 0.1);
                baseDrink = new AmarettoDecorator(baseDrink);
                baseDrink = new WhippedCreamDecorator(baseDrink, 0.3);
                break;

            case "CoffeeChoc":
                baseDrink = new Drink(info.Name);
                baseDrink = new CoffeeDecorator(baseDrink, strength, 2.0);
                baseDrink = new HotChocolateAdapter(baseDrink);
                break;

            case "SpecialDrink":
                baseDrink = new Drink(info.SpecialDrink.Name, info.SpecialDrink.Price);
                foreach (var item in info.SpecialDrink.Ingredients)
                {
                    baseDrink = new SpecialDrinkAdapter(baseDrink, item);
                }
                break;

            default:
                return(null);
            }

            return(new ReleaseDecorator(baseDrink));
        }
コード例 #21
0
ファイル: DeltaBlue.cs プロジェクト: Smith-yue/coreclr
 public static Strength weakestOf(Strength s1, Strength s2)
 {
     return weaker(s1, s2) ? s1 : s2;
 }
コード例 #22
0
 public static void SignArchive(MPQ archive, Strength signingStrength)
 {
 }
コード例 #23
0
ファイル: PasswordHash.cs プロジェクト: jkiv/libsodium-net
        /// <summary>Returns the hash in a string format, which includes the generated salt.</summary>
        /// <param name="password">The password.</param>
        /// <param name="limit">The limit for computation.</param>
        /// <returns>Returns an zero-terminated ASCII encoded string of the computed password and hash.</returns>
        /// <exception cref="ArgumentNullException"></exception>
        /// <exception cref="ArgumentOutOfRangeException"></exception>
        /// <exception cref="OutOfMemoryException"></exception>
        public static string ScryptHashString(string password, Strength limit = Strength.Interactive)
        {
            int memLimit;
              long opsLimit;

              switch (limit)
              {
            case Strength.Interactive:
              opsLimit = OPSLIMIT_INTERACTIVE;
              memLimit = MEMLIMIT_INTERACTIVE;
              break;
            case Strength.Moderate:
              opsLimit = OPSLIMIT_MODERATE;
              memLimit = MEMLIMIT_MODERATE;
              break;
            case Strength.Medium:
              opsLimit = OPSLIMIT_MEDIUM;
              memLimit = MEMLIMIT_MEDIUM;
              break;
            case Strength.MediumSlow:
              //to slow the process down, use the sensitive ops limit
              opsLimit = OPSLIMIT_SENSITIVE;
              memLimit = MEMLIMIT_MEDIUM;
              break;
            case Strength.Sensitive:
              opsLimit = OPSLIMIT_SENSITIVE;
              memLimit = MEMLIMIT_SENSITIVE;
              break;
            default:
              opsLimit = OPSLIMIT_INTERACTIVE;
              memLimit = MEMLIMIT_INTERACTIVE;
              break;
              }

              return ScryptHashString(password, opsLimit, memLimit);
        }
コード例 #24
0
ファイル: DrinkFactory.cs プロジェクト: kennethgerrits/DPINT
 public IBeverage GetBeverage(string name, Strength strength, string blendString)
 {
     _blendString = blendString;
     return(GetBaseBeverage(name, strength));
 }
コード例 #25
0
        public void Calculate_EntropyNegativeMinimum_ResultIsStrengthVeryWeak()
        {
            Strength actual = this.GetInstance().Calculate(Double.MinValue);

            Assert.That(actual, Is.EqualTo(Strength.VeryWeak));
        }
コード例 #26
0
 public static int ToInverseInt(this Strength str)
 {
     return(-str.ToInt());
 }
コード例 #27
0
 public MoveWheel(WheelSide side, Strength str, Direction dir)
 {
     this.side = side;
     this.str  = str;
     this.dir  = dir;
 }
コード例 #28
0
 public override int GetHashCode()
 {
     return(Strength.GetHashCode());
 }
コード例 #29
0
ファイル: PasswordHash.cs プロジェクト: Siiver/libsodium-net
 /// <summary>Derives a secret key of any size from a password and a salt.</summary>
 /// <param name="password">The password.</param>
 /// <param name="salt">The salt.</param>
 /// <param name="limit">The limit for computation.</param>
 /// <param name="outputLength">The length of the computed output array.</param>
 /// <returns>Returns a byte array of the given size.</returns>
 /// <exception cref="ArgumentNullException"></exception>
 /// <exception cref="ArgumentOutOfRangeException"></exception>
 /// <exception cref="SaltOutOfRangeException"></exception>
 /// <exception cref="OutOfMemoryException"></exception>
 public static byte[] ScryptHashBinary(string password, string salt, Strength limit = Strength.Interactive, long outputLength = SCRYPT_SALSA208_SHA256_SALTBYTES)
 {
     return(ScryptHashBinary(Encoding.UTF8.GetBytes(password), Encoding.UTF8.GetBytes(salt), limit, outputLength));
 }
コード例 #30
0
 public Coffee(Strength coffeeStrength)
 {
     Name          = "Coffee";
     DrinkStrength = coffeeStrength;
     BasePrice     = 1.50;
 }
コード例 #31
0
ファイル: PasswordHash.cs プロジェクト: jestin/libsodium-net
        /// <summary>Returns the hash in a string format, which includes the generated salt.</summary>
        /// <param name="password">The password.</param>
        /// <param name="limit">The limit for computation.</param>
        /// <returns>Returns an zero-terminated ASCII encoded string of the computed password and hash.</returns>
        /// <exception cref="ArgumentNullException"></exception>
        /// <exception cref="ArgumentOutOfRangeException"></exception>
        /// <exception cref="OutOfMemoryException"></exception>
        public static string ScryptHashString(string password, Strength limit = Strength.Interactive)
        {
            int memLimit;
              long opsLimit;

              switch (limit)
              {
            case Strength.Interactive:
              opsLimit = OPSLIMIT_INTERACTIVE;
              memLimit = MEMLIMIT_INTERACTIVE;
              break;
            case Strength.Moderate:
              opsLimit = OPSLIMIT_MODERATE;
              memLimit = MEMLIMIT_MODERATE;
              break;
            case Strength.Sensitive:
              opsLimit = OPSLIMIT_SENSITIVE;
              memLimit = MEMLIMIT_SENSITIVE;
              break;
            default:
              opsLimit = OPSLIMIT_INTERACTIVE;
              memLimit = MEMLIMIT_INTERACTIVE;
              break;
              }

              return ScryptHashString(password, opsLimit, memLimit);
        }
コード例 #32
0
 public StrengthDrinkDecorator(IDrink drink, Strength strength) : base(drink)
 {
     Strength = strength;
 }
コード例 #33
0
ファイル: DeltaBlue.cs プロジェクト: Smith-yue/coreclr
    public String name;             // a symbolic name for reporting purposes


    private Variable(String name, int initialValue, Strength walkStrength,
             int nconstraints)
    {
        value = initialValue;
        constraints = new ArrayList(nconstraints);
        determinedBy = null;
        mark = 0;
        this.walkStrength = walkStrength;
        stay = true;
        this.name = name;
    }
コード例 #34
0
 public uint Total()
 {
     return((uint)(Strength.Total() + Chance.Total() + Intelligence.Total() + Agility.Total()));
 }
コード例 #35
0
ファイル: DeltaBlue.cs プロジェクト: Smith-yue/coreclr
    public Constraint() { } // this has to be here because of
                            // Java's constructor idiocy.

    public Constraint(Strength strength)
    {
        this.strength = strength;
    }
コード例 #36
0
        public CharacterCharacteristicsInformations GetCharacterCharacteristics(Character character)
        {
            ulong expFloor     = ExperienceRecord.GetExperienceForLevel(character.Level).Player;
            ulong expNextFloor = ExperienceRecord.GetExperienceForNextLevel(character.Level).Player;

            CharacterCharacteristicsInformations informations = new CharacterCharacteristicsInformations()
            {
                actionPoints            = ActionPoints.GetBaseCharacteristic(),
                actionPointsCurrent     = ActionPoints.TotalInContext(),
                additionnalPoints       = 0,
                agility                 = Agility.GetBaseCharacteristic(),
                airDamageBonus          = AirDamageBonus.GetBaseCharacteristic(),
                airElementReduction     = AirReduction.GetBaseCharacteristic(),
                airElementResistPercent = AirResistPercent.GetBaseCharacteristic(),
                alignmentInfos          = character.Record.Alignment.GetActorExtendedAlignement(),
                allDamagesBonus         = AllDamagesBonus.GetBaseCharacteristic(),
                chance = Chance.GetBaseCharacteristic(),
                criticalDamageBonus          = CriticalDamageBonus.GetBaseCharacteristic(),
                criticalDamageReduction      = CriticalDamageReduction.GetBaseCharacteristic(),
                criticalHit                  = CriticalHit.GetBaseCharacteristic(),
                criticalHitWeapon            = CriticalHitWeapon,
                criticalMiss                 = Characteristic.Zero().GetBaseCharacteristic(),
                damagesBonusPercent          = DamagesBonusPercent.GetBaseCharacteristic(),
                dodgePALostProbability       = DodgePAProbability.GetBaseCharacteristic(),
                dodgePMLostProbability       = DodgePMProbability.GetBaseCharacteristic(),
                earthDamageBonus             = EarthDamageBonus.GetBaseCharacteristic(),
                earthElementReduction        = EarthReduction.GetBaseCharacteristic(),
                earthElementResistPercent    = EarthResistPercent.GetBaseCharacteristic(),
                pvpEarthElementReduction     = PvPEarthReduction.GetBaseCharacteristic(),
                pvpEarthElementResistPercent = PvPEarthResistPercent.GetBaseCharacteristic(),
                fireDamageBonus              = FireDamageBonus.GetBaseCharacteristic(),
                fireElementReduction         = FireReduction.GetBaseCharacteristic(),
                fireElementResistPercent     = FireResistPercent.GetBaseCharacteristic(),
                pvpFireElementReduction      = PvPFireReduction.GetBaseCharacteristic(),
                pvpFireElementResistPercent  = PvPFireResistPercent.GetBaseCharacteristic(),
                glyphBonusPercent            = GlyphBonusPercent.GetBaseCharacteristic(),
                healBonus                      = HealBonus.GetBaseCharacteristic(),
                initiative                     = new CharacterBaseCharacteristic((short)FormulasProvider.Instance.BaseInitiative(this), 0, Initiative.Total(), 0, 0),
                intelligence                   = Intelligence.GetBaseCharacteristic(),
                kamas                          = character.Record.Kamas,
                lifePoints                     = (uint)LifePoints,
                maxEnergyPoints                = MaxEnergyPoints,
                maxLifePoints                  = (uint)MaxLifePoints,
                movementPoints                 = MovementPoints.GetBaseCharacteristic(),
                movementPointsCurrent          = MovementPoints.TotalInContext(),
                PMAttack                       = PMAttack.GetBaseCharacteristic(),
                PAAttack                       = PAAttack.GetBaseCharacteristic(),
                pvpAirElementReduction         = PvPAirReduction.GetBaseCharacteristic(),
                pvpAirElementResistPercent     = PvPAirResistPercent.GetBaseCharacteristic(),
                pvpNeutralElementReduction     = PvPNeutralReduction.GetBaseCharacteristic(),
                pvpNeutralElementResistPercent = PvPNeutralResistPercent.GetBaseCharacteristic(),
                pvpWaterElementReduction       = PvPWaterReduction.GetBaseCharacteristic(),
                pvpWaterElementResistPercent   = PvPWaterResistPercent.GetBaseCharacteristic(),
                energyPoints                   = Energy,
                experience                     = character.Experience,
                experienceLevelFloor           = expFloor,
                experienceNextLevelFloor       = expNextFloor,
                neutralDamageBonus             = NeutralDamageBonus.GetBaseCharacteristic(),
                neutralElementReduction        = NeutralReduction.GetBaseCharacteristic(),
                neutralElementResistPercent    = NeutralResistPercent.GetBaseCharacteristic(),
                tackleEvade                    = TackleEvade.GetBaseCharacteristic(),
                tackleBlock                    = TackleBlock.GetBaseCharacteristic(),
                range                          = Range.GetBaseCharacteristic(),
                waterElementReduction          = WaterReduction.GetBaseCharacteristic(),
                waterDamageBonus               = WaterDamageBonus.GetBaseCharacteristic(),
                waterElementResistPercent      = WaterResistPercent.GetBaseCharacteristic(),
                reflect                        = Reflect.GetBaseCharacteristic(),
                permanentDamagePercent         = PermanentDamagePercent.GetBaseCharacteristic(),
                prospecting                    = Prospecting.GetBaseCharacteristic(),
                pushDamageBonus                = PushDamageBonus.GetBaseCharacteristic(),
                pushDamageReduction            = PushDamageReduction.GetBaseCharacteristic(),
                runeBonusPercent               = RuneBonusPercent.GetBaseCharacteristic(),
                spellModifications             = new CharacterSpellModification[0],
                spellsPoints                   = character.Record.SpellPoints,
                statsPoints                    = character.Record.StatsPoints,
                vitality                       = Vitality.GetBaseCharacteristic(),
                strength                       = Strength.GetBaseCharacteristic(),
                summonableCreaturesBoost       = SummonableCreaturesBoost.GetBaseCharacteristic(),
                trapBonus                      = TrapBonus.GetBaseCharacteristic(),
                trapBonusPercent               = TrapBonusPercent.GetBaseCharacteristic(),
                weaponDamagesBonusPercent      = WeaponDamagesBonusPercent.GetBaseCharacteristic(),
                wisdom                         = Wisdom.GetBaseCharacteristic(),
                probationTime                  = 0
            };

            return(informations);
        }
コード例 #37
0
ファイル: DeltaBlue.cs プロジェクト: Smith-yue/coreclr
 public EditConstraint(Variable v, Strength str) : base(v, str) { }
コード例 #38
0
 public CoffeeDecorator(IDrink drink, Strength strength = Strength.Normal, double price = 0, Amount amount = Amount.Normal) : base(drink, strength)
 {
     _amount = amount;
     _price  = price;
 }
コード例 #39
0
ファイル: DeltaBlue.cs プロジェクト: Smith-yue/coreclr
 public static Boolean stronger(Strength s1, Strength s2)
 {
     return s1._strengthValue < s2._strengthValue;
 }
コード例 #40
0
        public virtual void Consume(Player player)
        {
            Effect e = null;

            switch (Metadata)
            {
            case 5:
                e = new NightVision
                {
                    Duration = 3600,
                    Level    = 0
                };
                break;

            case 6:
                e = new NightVision
                {
                    Duration = 9600,
                    Level    = 0
                };
                break;

            case 7:
                e = new Invisibility
                {
                    Duration = 3600,
                    Level    = 0
                };
                break;

            case 8:
                e = new Invisibility
                {
                    Duration = 9600,
                    Level    = 0
                };
                break;

            case 9:
                e = new JumpBoost
                {
                    Duration = 3600,
                    Level    = 0
                };
                break;

            case 10:
                e = new JumpBoost
                {
                    Duration = 9600,
                    Level    = 0
                };
                break;

            case 11:
                e = new JumpBoost
                {
                    Duration = 1800,
                    Level    = 1
                };
                break;

            case 12:
                e = new FireResistance
                {
                    Duration = 3600,
                    Level    = 0
                };
                break;

            case 13:
                e = new FireResistance
                {
                    Duration = 9600,
                    Level    = 0
                };
                break;

            case 14:
                e = new Speed
                {
                    Duration = 3600,
                    Level    = 0
                };
                break;

            case 15:
                e = new Speed
                {
                    Duration = 9600,
                    Level    = 0
                };
                break;

            case 16:
                e = new Speed
                {
                    Duration = 1800,
                    Level    = 1
                };
                break;

            case 17:
                e = new Slowness
                {
                    Duration = 3600,
                    Level    = 0
                };
                break;

            case 18:
                e = new Slowness
                {
                    Duration = 4800,
                    Level    = 0
                };
                break;

            case 19:
                e = new WaterBreathing
                {
                    Duration = 3600,
                    Level    = 0
                };
                break;

            case 20:
                e = new WaterBreathing
                {
                    Duration = 9600,
                    Level    = 0
                };
                break;

            case 21:
                e = new InstantHealth
                {
                    Duration = 0,
                    Level    = 0
                };
                break;

            case 22:
                e = new InstantHealth
                {
                    Duration = 0,
                    Level    = 1
                };
                break;

            case 23:
                e = new InstantDamage
                {
                    Duration = 0,
                    Level    = 0
                };
                break;

            case 24:
                e = new InstantDamage
                {
                    Duration = 0,
                    Level    = 1
                };
                break;

            case 25:
                e = new Poison
                {
                    Duration = 900,
                    Level    = 0
                };
                break;

            case 26:
                e = new Poison
                {
                    Duration = 2400,
                    Level    = 0
                };
                break;

            case 27:
                e = new Poison
                {
                    Duration = 440,
                    Level    = 1
                };
                break;

            case 28:
                e = new Regeneration
                {
                    Duration = 900,
                    Level    = 0
                };
                break;

            case 29:
                e = new Regeneration
                {
                    Duration = 2400,
                    Level    = 0
                };
                break;

            case 30:
                e = new Regeneration
                {
                    Duration = 440,
                    Level    = 1
                };
                break;

            case 31:
                e = new Strength
                {
                    Duration = 3600,
                    Level    = 0
                };
                break;

            case 32:
                e = new Strength
                {
                    Duration = 9600,
                    Level    = 0
                };
                break;

            case 33:
                e = new Strength
                {
                    Duration = 1800,
                    Level    = 1
                };
                break;

            case 34:
                e = new Weakness
                {
                    Duration = 1800,
                    Level    = 0
                };
                break;

            case 35:
                e = new Weakness
                {
                    Duration = 4800,
                    Level    = 0
                };
                break;
            }

            if (e != null)
            {
                player.SetEffect(e);
            }
        }
コード例 #41
0
ファイル: DeltaBlue.cs プロジェクト: Smith-yue/coreclr
 public static Boolean weaker(Strength s1, Strength s2)
 {
     return s1._strengthValue > s2._strengthValue;
 }
コード例 #42
0
        public IHttpActionResult GetUser(string username)
        {
            response.status = "FAILURE";
            string informationPath = AppDomain.CurrentDomain.BaseDirectory + @"ResumeList\" + username + "\\" + "Information.txt";
            string skillPath = AppDomain.CurrentDomain.BaseDirectory + @"ResumeList\" + username + "\\" + "Skill.txt";
            string strengthPath = AppDomain.CurrentDomain.BaseDirectory + @"ResumeList\" + username + "\\" + "Strengths.txt";
            string postGraduatePath = AppDomain.CurrentDomain.BaseDirectory + @"ResumeList\" + username + "\\" + "PostGraduate.txt";
            string tertiaryPath = AppDomain.CurrentDomain.BaseDirectory + @"ResumeList\" + username + "\\" + "Tertiary.txt";
            string secondaryPath = AppDomain.CurrentDomain.BaseDirectory + @"ResumeList\" + username + "\\" + "Secondary.txt";
            string primaryPath = AppDomain.CurrentDomain.BaseDirectory + @"ResumeList\" + username + "\\" + "Primary.txt";
            string workExperiencePath = AppDomain.CurrentDomain.BaseDirectory + @"ResumeList\" + username + "\\" + "WorkExperience.txt";
            string trainingPath = AppDomain.CurrentDomain.BaseDirectory + @"ResumeList\" + username + "\\" + "Training.txt";
            string characterReferencePath = AppDomain.CurrentDomain.BaseDirectory + @"ResumeList\" + username + "\\" + "CharacterReference.txt";
            int    index = 0, iterationCount = 0;

            if (Directory.Exists(AppDomain.CurrentDomain.BaseDirectory + @"ResumeList\" + username))
            {
                User user = new User();
                //Information
                if (System.IO.File.Exists(informationPath))
                {
                    string[] information = System.IO.File.ReadAllLines(informationPath);
                    //user.FirstName
                    user.FirstName     = information[0].Replace("�", "\u00f1");
                    user.MiddleName    = information[1].Replace("�", "\u00f1");
                    user.LastName      = information[2].Replace("�", "\u00f1");
                    user.Address       = information[3].Replace("�", "\u00f1");
                    user.ContactNo     = information[4].Replace("�", "\u00f1");
                    user.EmailAddress  = information[5].Replace("�", "\u00f1");
                    user.Objectives    = information[6].Replace("�", "\u00f1");
                    user.Age           = Convert.ToInt32(information[7]);
                    user.DateOfBirth   = Convert.ToDateTime(information[8]);
                    user.Gender        = information[9].Replace("�", "\u00f1");
                    user.CivilStatus   = information[10].Replace("�", "\u00f1");
                    user.Height        = information[11].Replace("�", "\u00f1");
                    user.Weight        = information[12].Replace("�", "\u00f1");
                    user.Citizenship   = information[13].Replace("�", "\u00f1");
                    user.Hobbies       = information[14].Replace("�", "\u00f1");
                    user.Template      = Convert.ToInt32(information[15]);
                    user.ImageName     = information[16].Replace("�", "\u00f1");
                    response.objParam1 = user;
                }
                //Skill
                if (System.IO.File.Exists(skillPath))
                {
                    string[] skill = System.IO.File.ReadAllLines(skillPath);
                    for (int i = 0; i < skill.Length; i++)
                    {
                        Skill skills = new Skill();
                        skills.Description = skill[i].Replace("�", "\u00f1");
                        user.Skills.Add(skills);
                    }
                }
                //Strengths
                if (System.IO.File.Exists(strengthPath))
                {
                    string[] strength = System.IO.File.ReadAllLines(strengthPath);
                    for (int i = 0; i < strength.Length; i++)
                    {
                        Strength strengths = new Strength();
                        strengths.Description = strength[i];
                        user.Strengths.Add(strengths);
                    }
                }
                //PostGraduate
                if (System.IO.File.Exists(postGraduatePath))
                {
                    string[] postGraduate = System.IO.File.ReadAllLines(postGraduatePath);
                    iterationCount = postGraduate.Length / 3;
                    index          = 0;
                    for (int i = 0; i < iterationCount; i++)
                    {
                        PostGraduate postGraduates = new PostGraduate();
                        postGraduates.School = postGraduate[index].Replace("�", "\u00f1");
                        index = index + 1;
                        postGraduates.Degree = postGraduate[index].Replace("�", "\u00f1");
                        index = index + 1;
                        postGraduates.Address = postGraduate[index].Replace("�", "\u00f1");
                        index = index + 1;
                        if (postGraduate[index].Equals("N"))
                        {
                            postGraduates.Achievement = "";
                        }
                        else
                        {
                            postGraduates.Achievement = postGraduate[index].Replace("�", "\u00f1");
                        }
                        index = index + 1;
                        user.PostGraduates.Add(postGraduates);
                    }
                }
                //Tertiary
                if (System.IO.File.Exists(tertiaryPath))
                {
                    string[] tertiary = System.IO.File.ReadAllLines(tertiaryPath);
                    iterationCount = tertiary.Length / 3;
                    index          = 0;
                    for (int i = 0; i < iterationCount; i++)
                    {
                        Tertiary tertiaries = new Tertiary();
                        tertiaries.School  = tertiary[index].Replace("�", "\u00f1");
                        index              = index + 1;
                        tertiaries.Degree  = tertiary[index].Replace("�", "\u00f1");
                        index              = index + 1;
                        tertiaries.Address = tertiary[index].Replace("�", "\u00f1");
                        index              = index + 1;
                        if (tertiary[index].Equals("N"))
                        {
                            tertiaries.Achievement = "";
                        }
                        else
                        {
                            tertiaries.Achievement = tertiary[index].Replace("�", "\u00f1");
                        }
                        index = index + 1;
                        user.Tertiaries.Add(tertiaries);
                    }
                }
                //Secondary
                if (System.IO.File.Exists(secondaryPath))
                {
                    string[] secondary = System.IO.File.ReadAllLines(secondaryPath);
                    iterationCount = secondary.Length / 2;
                    index          = 0;
                    for (int i = 0; i < iterationCount; i++)
                    {
                        Secondary secondaries = new Secondary();
                        secondaries.School = secondary[index].Replace("�", "\u00f1");
                        index = index + 1;
                        secondaries.Address = secondary[index].Replace("�", "\u00f1");
                        index = index + 1;
                        if (secondary[index].Equals("N"))
                        {
                            secondaries.Achievement = "";
                        }
                        else
                        {
                            secondaries.Achievement = secondary[index].Replace("�", "\u00f1");
                        }
                        index = index + 1;
                        user.Secondaries.Add(secondaries);
                    }
                }
                //Primary
                if (System.IO.File.Exists(primaryPath))
                {
                    string[] primary = System.IO.File.ReadAllLines(primaryPath);
                    iterationCount = primary.Length / 2;
                    index          = 0;
                    for (int i = 0; i < iterationCount; i++)
                    {
                        Primary primaries = new Primary();
                        primaries.School  = primary[index].Replace("�", "\u00f1");
                        index             = index + 1;
                        primaries.Address = primary[index].Replace("�", "\u00f1");
                        index             = index + 1;
                        if (primary[index].Equals("N"))
                        {
                            primaries.Achievement = "";
                        }
                        else
                        {
                            primaries.Achievement = primary[index].Replace("�", "\u00f1");
                        }
                        index = index + 1;
                        user.Primaries.Add(primaries);
                    }
                }
                //Work Experience
                if (System.IO.File.Exists(workExperiencePath))
                {
                    string[] workExperience = System.IO.File.ReadAllLines(workExperiencePath);
                    iterationCount = workExperience.Length / 5;
                    index          = 0;
                    for (int i = 0; i < iterationCount; i++)
                    {
                        WorkExperience workExperiences = new WorkExperience();
                        workExperiences.Company = workExperience[index].Replace("�", "\u00f1");
                        index = index + 1;
                        workExperiences.Address = workExperience[index].Replace("�", "\u00f1");
                        index = index + 1;
                        workExperiences.Period = workExperience[index].Replace("�", "\u00f1");
                        index = index + 1;
                        workExperiences.Position = workExperience[index].Replace("�", "\u00f1");
                        index = index + 1;
                        workExperiences.MainRole = workExperience[index].Replace("�", "\u00f1");
                        index = index + 1;
                        user.WorkExperiences.Add(workExperiences);
                    }
                }
                //Training
                if (System.IO.File.Exists(trainingPath))
                {
                    string[] training = System.IO.File.ReadAllLines(trainingPath);
                    iterationCount = training.Length / 3;
                    index          = 0;
                    for (int i = 0; i < iterationCount; i++)
                    {
                        Training trainings = new Training();
                        trainings.Name        = training[index].Replace("�", "\u00f1");
                        index                 = index + 1;
                        trainings.Description = training[index].Replace("�", "\u00f1");
                        index                 = index + 1;
                        trainings.Period      = training[index].Replace("�", "\u00f1");
                        index                 = index + 1;
                        user.Trainings.Add(trainings);
                    }
                }
                //character Reference
                if (System.IO.File.Exists(characterReferencePath))
                {
                    string[] characterReference = System.IO.File.ReadAllLines(characterReferencePath);
                    iterationCount = characterReference.Length / 3;
                    index          = 0;
                    for (int i = 0; i < iterationCount; i++)
                    {
                        CharacterReference characterReferences = new CharacterReference();
                        characterReferences.Name = characterReference[index];
                        index = index + 1;
                        characterReferences.Profession = characterReference[index].Replace("�", "\u00f1");
                        index = index + 1;
                        characterReferences.ContactNo = characterReference[index].Replace("�", "\u00f1");
                        index = index + 1;
                        user.CharacterReferences.Add(characterReferences);
                    }
                }
                TokenGenerator tokenGenerator = new TokenGenerator();
                response.stringParam1 = tokenGenerator.Encrypt(tokenGenerator.generateCode(10)) + ":" + tokenGenerator.Encrypt("ARJOCAMAHAMAGEAPP");
                response.status       = "SUCCESS";
            }
            else
            {
                response.message = "User not found.";
            }

            return(Ok(response));
        }
コード例 #43
0
ファイル: DeltaBlue.cs プロジェクト: Smith-yue/coreclr
    // Install a constraint with the given strength equating the given variables.
    public EqualityConstraint(Variable var1, Variable var2, Strength strength)
        : base(var1, var2, strength)

    {
    }
コード例 #44
0
 public Tobacco(string brandName, Strength brandStrength, HeatTolerance brandHeatTolerance, float brandSmokingTime, float brandPrice, Flavour flavour)
 {
     this.brand   = new Brand(brandName, brandStrength, brandHeatTolerance, brandSmokingTime, brandPrice);
     this.flavour = flavour;
 }
コード例 #45
0
ファイル: DeltaBlue.cs プロジェクト: Smith-yue/coreclr
 public static Strength strongest(Strength s1, Strength s2)
 {
     return stronger(s1, s2) ? s1 : s2;
 }
コード例 #46
0
 public override string ToDebugString()
 {
     return($"{ToolBox.GetDebugSymbol(isFinished)} {nameof(AfflictionAction)} -> (TargetTag: {TargetTag.ColorizeObject()}, " +
            $"Affliction: {Affliction.ColorizeObject()}, Strength: {Strength.ColorizeObject()}, " +
            $"LimbType: {LimbType.ColorizeObject()})");
 }
コード例 #47
0
ファイル: PasswordHash.cs プロジェクト: jkiv/libsodium-net
 /// <summary>Derives a secret key of any size from a password and a salt.</summary>
 /// <param name="password">The password.</param>
 /// <param name="salt">The salt.</param>
 /// <param name="limit">The limit for computation.</param>
 /// <param name="outputLength">The length of the computed output array.</param>
 /// <returns>Returns a byte array of the given size.</returns>
 /// <exception cref="ArgumentNullException"></exception>
 /// <exception cref="ArgumentOutOfRangeException"></exception>
 /// <exception cref="SaltOutOfRangeException"></exception>
 /// <exception cref="OutOfMemoryException"></exception>
 public static byte[] ScryptHashBinary(string password, string salt, Strength limit = Strength.Interactive, long outputLength = SCRYPT_SALSA208_SHA256_SALTBYTES)
 {
     return ScryptHashBinary(Encoding.UTF8.GetBytes(password), Encoding.UTF8.GetBytes(salt), limit, outputLength);
 }
コード例 #48
0
ファイル: MPQSign.cs プロジェクト: Nihlus/libwarcraft
 public static void SignArchive(MPQ archive, Strength signingStrength)
 {
 }
コード例 #49
0
 public override void Serialize(IDataWriter writer)
 {
     writer.WriteVarUhLong(Experience);
     writer.WriteVarUhLong(ExperienceLevelFloor);
     writer.WriteVarUhLong(ExperienceNextLevelFloor);
     writer.WriteVarUhLong(ExperienceBonusLimit);
     writer.WriteVarUhLong(Kamas);
     writer.WriteVarUhShort(StatsPoints);
     writer.WriteVarUhShort(AdditionnalPoints);
     writer.WriteVarUhShort(SpellsPoints);
     AlignmentInfos.Serialize(writer);
     writer.WriteVarUhInt(LifePoints);
     writer.WriteVarUhInt(MaxLifePoints);
     writer.WriteVarUhShort(EnergyPoints);
     writer.WriteVarUhShort(MaxEnergyPoints);
     writer.WriteVarShort(ActionPointsCurrent);
     writer.WriteVarShort(MovementPointsCurrent);
     Initiative.Serialize(writer);
     Prospecting.Serialize(writer);
     ActionPoints.Serialize(writer);
     MovementPoints.Serialize(writer);
     Strength.Serialize(writer);
     Vitality.Serialize(writer);
     Wisdom.Serialize(writer);
     Chance.Serialize(writer);
     Agility.Serialize(writer);
     Intelligence.Serialize(writer);
     Range.Serialize(writer);
     SummonableCreaturesBoost.Serialize(writer);
     Reflect.Serialize(writer);
     CriticalHit.Serialize(writer);
     writer.WriteVarUhShort(CriticalHitWeapon);
     CriticalMiss.Serialize(writer);
     HealBonus.Serialize(writer);
     AllDamagesBonus.Serialize(writer);
     WeaponDamagesBonusPercent.Serialize(writer);
     DamagesBonusPercent.Serialize(writer);
     TrapBonus.Serialize(writer);
     TrapBonusPercent.Serialize(writer);
     GlyphBonusPercent.Serialize(writer);
     RuneBonusPercent.Serialize(writer);
     PermanentDamagePercent.Serialize(writer);
     TackleBlock.Serialize(writer);
     TackleEvade.Serialize(writer);
     PAAttack.Serialize(writer);
     PMAttack.Serialize(writer);
     PushDamageBonus.Serialize(writer);
     CriticalDamageBonus.Serialize(writer);
     NeutralDamageBonus.Serialize(writer);
     EarthDamageBonus.Serialize(writer);
     WaterDamageBonus.Serialize(writer);
     AirDamageBonus.Serialize(writer);
     FireDamageBonus.Serialize(writer);
     DodgePALostProbability.Serialize(writer);
     DodgePMLostProbability.Serialize(writer);
     NeutralElementResistPercent.Serialize(writer);
     EarthElementResistPercent.Serialize(writer);
     WaterElementResistPercent.Serialize(writer);
     AirElementResistPercent.Serialize(writer);
     FireElementResistPercent.Serialize(writer);
     NeutralElementReduction.Serialize(writer);
     EarthElementReduction.Serialize(writer);
     WaterElementReduction.Serialize(writer);
     AirElementReduction.Serialize(writer);
     FireElementReduction.Serialize(writer);
     PushDamageReduction.Serialize(writer);
     CriticalDamageReduction.Serialize(writer);
     PvpNeutralElementResistPercent.Serialize(writer);
     PvpEarthElementResistPercent.Serialize(writer);
     PvpWaterElementResistPercent.Serialize(writer);
     PvpAirElementResistPercent.Serialize(writer);
     PvpFireElementResistPercent.Serialize(writer);
     PvpNeutralElementReduction.Serialize(writer);
     PvpEarthElementReduction.Serialize(writer);
     PvpWaterElementReduction.Serialize(writer);
     PvpAirElementReduction.Serialize(writer);
     PvpFireElementReduction.Serialize(writer);
     MeleeDamageDonePercent.Serialize(writer);
     MeleeDamageReceivedPercent.Serialize(writer);
     RangedDamageDonePercent.Serialize(writer);
     RangedDamageReceivedPercent.Serialize(writer);
     WeaponDamageDonePercent.Serialize(writer);
     WeaponDamageReceivedPercent.Serialize(writer);
     SpellDamageDonePercent.Serialize(writer);
     SpellDamageReceivedPercent.Serialize(writer);
     writer.WriteShort((short)SpellModifications.Count);
     for (var spellModificationsIndex = 0;
          spellModificationsIndex < SpellModifications.Count;
          spellModificationsIndex++)
     {
         var objectToSend = SpellModifications[spellModificationsIndex];
         objectToSend.Serialize(writer);
     }
     writer.WriteInt(ProbationTime);
 }
コード例 #50
0
 public Response Attack(Strength strength)
 {
     return(Response.Success);
 }