Ejemplo n.º 1
0
        public void BuildWeapon(WorldObject weapon, WorldObject wielder)
        {
            WeaponProfile   = new WeaponProfile(weapon, wielder);
            WeaponHighlight = WeaponMaskHelper.GetHighlightMask(weapon, wielder);
            WeaponColor     = WeaponMaskHelper.GetColorMask(weapon, wielder);

            // item enchantments can also be on wielder currently
            AddSpells(SpellBook, wielder);
        }
Ejemplo n.º 2
0
 /// <summary>
 /// Writes the weapon appraisal info to the network stream
 /// </summary>
 public static void Write(this BinaryWriter writer, WeaponProfile profile)
 {
     writer.Write((uint)profile.DamageType);
     writer.Write(profile.WeaponTime);
     writer.Write((uint)profile.WeaponSkill);
     writer.Write(profile.Damage);
     writer.Write(profile.DamageVariance);
     writer.Write(profile.DamageMod);
     writer.Write(profile.WeaponLength);
     writer.Write(profile.MaxVelocity);
     writer.Write(profile.WeaponOffense);
     writer.Write(profile.MaxVelocityEstimated);
 }
Ejemplo n.º 3
0
        private void BuildWeapon(WorldObject weapon, WorldObject wielder)
        {
            var weaponProfile = new WeaponProfile(weapon, wielder);

            //WeaponHighlight = WeaponMaskHelper.GetHighlightMask(weapon, wielder);
            //WeaponColor = WeaponMaskHelper.GetColorMask(weapon, wielder);
            WeaponHighlight = WeaponMaskHelper.GetHighlightMask(weaponProfile);
            WeaponColor = WeaponMaskHelper.GetColorMask(weaponProfile);

            if (!(weapon is Caster))
                WeaponProfile = weaponProfile;

            // item enchantments can also be on wielder currently
            AddSpells(SpellBook, weapon, wielder);
        }
Ejemplo n.º 4
0
        private void BuildWeapon(WorldObject weapon)
        {
            if (!Success)
            {
                return;
            }

            var weaponProfile = new WeaponProfile(weapon);

            //WeaponHighlight = WeaponMaskHelper.GetHighlightMask(weapon, wielder);
            //WeaponColor = WeaponMaskHelper.GetColorMask(weapon, wielder);
            WeaponHighlight = WeaponMaskHelper.GetHighlightMask(weaponProfile);
            WeaponColor     = WeaponMaskHelper.GetColorMask(weaponProfile);

            if (!(weapon is Caster))
            {
                WeaponProfile = weaponProfile;
            }

            // item enchantments can also be on wielder currently
            AddEnchantments(weapon);
        }