|
المشاركات 1,941 |
+التقييم 1.00 |
تاريخ التسجيل Apr 2019 |
الاقامة Egypt |
نظام التشغيل windows 7 |
رقم العضوية 1 |
#region Wrath Of Emperor[Reparado 100%]
case 12570:
{
if (CanUseSpell(spell, attacker.Owner))
{
PrepareSpell(spell, attacker.Owner);
SpellUse suse = new SpellUse(true);
suse.Attacker = attacker.UID;
suse.SpellID = SpellID;
suse.SpellLevel = attacker.Owner.Spells[SpellID].Level;
suse.X = X;
suse.Y = Y;
suse.SpellEffect = 1;
foreach (Interfaces.IMapObject _obj in attacker.Owner.Screen.Objects)
{
if (_obj == null) continue;
if (_obj.MapObjType == MapObjectType.Monster || _obj.MapObjType == MapObjectType.Player)
{
attacked = _obj as Entity;
if (Kernel.GetDistance(attacker.X, attacker.Y, attacked.X, attacked.Y) <= 2)
{
if (CanAttack(attacker, attacked, spell, attack.AttackType == Attack.Melee))
{
uint damage = Game.Attacking.Calculate.Melee(attacker, attacked, ref attack);
suse.Effect1 = attack.Effect1;
attack.Effect1 = Attack.AttackEffects1.None;
ReceiveAttack(attacker, attacked, attack, ref damage, spell);
suse.AddTarget(attacked, damage, attack);
}
}
}
else if (_obj.MapObjType == MapObjectType.SobNpc)
{
attackedsob = _obj as SobNpcSpawn;
if (Kernel.GetDistance(attacker.X, attacker.Y, attackedsob.X, attackedsob.Y) <= 2)
{
if (CanAttack(attacker, attackedsob, spell))
{
uint damage = Game.Attacking.Calculate.Melee(attacker, attackedsob, ref attack);
suse.Effect1 = attack.Effect1;
attack.Effect1 = Attack.AttackEffects1.None;
ReceiveAttack(attacker, attackedsob, attack, damage, spell);
suse.AddTarget(attackedsob, damage, attack);
}
}
}
}
attacker.Owner.SendScreen(suse, true);
}
break;
}
#endregion
#region Melee
#region Melee
else if (attack.AttackType == Attack.Melee)
{
if (attacker.Assassin() || attacker.IsBowEquipped)
{
attack.AttackType = Attack.Ranged;
new Game.Attacking.Handle(attack, attacker, attacked);
return;
}
if (attacker.MapID == DeathMatch.MAPID)
{
attacker.Owner.Send(new Message("You have to use manual linear skills(FastBlade/ScentSword)", System.Drawing.Color.Red, Message.Talk));
return;
}
if (attacker.MapID == DeathMatch2.MAPID)
{
attacker.Owner.Send(new Message("You have to use manual linear skills(FastBlade/ScentSword)", System.Drawing.Color.Red, Message.Talk));
return;
}
if (attacker.Owner.Screen.TryGetValue(attack.Attacked, out attacked))
{
CheckForExtraWeaponPowers(attacker.Owner, attacked);
if (!CanAttack(attacker, attacked, null, attack.AttackType == Attack.Melee)) return;
pass = false;
if (attacker.OnFatalStrike())
{
if (attacked.EntityFlag == EntityFlag.Monster)
{
pass = true;
}
}
ushort range = attacker.AttackRange;
if (attacker.Transformed)
range = (ushort)attacker.TransformationAttackRange;
if (Kernel.GetDistance(attacker.X, attacker.Y, attacked.X, attacked.Y) <= range || pass)
{
#region EpicMonk
if (Kernel.Rate(50))
{
if (attack.SpellID == 12580 || attack.SpellID == 12590 || attack.SpellID == 12600)
{
SpellUse suse = new SpellUse(true);
suse.Attacker = attacker.UID;
suse.SpellID = 0;
suse.SpellLevel = 0;
suse.X = attacker.X;
suse.Y = attacker.Y;
Fan fan = new Fan(attacker.X, attacker.Y, attacked.X, attacked.Y, 7, 240);
foreach (Interfaces.IMapObject _obj in attacker.Owner.Screen.Objects)
{
if (_obj == null) continue;
if (_obj.MapObjType == MapObjectType.Monster || _obj.MapObjType == MapObjectType.Player)
{
attacked = _obj as Entity;
if (Kernel.GetDistance(attacker.X, attacker.Y, attacked.X, attacked.Y) <= 7)
{
if (CanAttack(attacker, attacked, null, attack.AttackType == Attack.Melee))
{
attack.Effect1 = Attack.AttackEffects1.None;
uint damages = Game.Attacking.Calculate.Melee(attacker, attacked, ref attack);
attack.Attacked = attacked.UID;
attack.Damage = damages;
suse.Effect1 = attack.Effect1;
ReceiveAttack(attacker, attacked, attack, ref damages, null);
}
}
}
}
attacker.AttackPacket = null;
attack = null;
return;
}
}
#endregion
attack.Effect1 = Attack.AttackEffects1.None;
uint damage = Game.Attacking.Calculate.Melee(attacker, attacked, ref attack);
attack.Damage = damage;
if (attacker.OnFatalStrike())
{
if (attacked.EntityFlag == EntityFlag.Monster)
{
var weaps = attacker.Owner.Weapons;
bool can = false;
if (weaps.Item1 != null)
if (weaps.Item1 != null) if (weaps.Item1.ID / 1000 == 601 || weaps.Item1.ID / 1000 == 616) can = true; if (weaps.Item2 != null) if (weaps.Item2.ID / 1000 == 601 || weaps.Item2.ID / 1000 == 616) can = true;
can = true;
if (weaps.Item2 != null)
if (weaps.Item1 != null) if (weaps.Item1.ID / 1000 == 601 || weaps.Item1.ID / 1000 == 616) can = true; if (weaps.Item2 != null) if (weaps.Item2.ID / 1000 == 601 || weaps.Item2.ID / 1000 == 616) can = true;
can = true;
if (!can)
return;
ushort x = attacked.X;
ushort y = attacked.Y;
Map.UpdateCoordonatesForAngle(ref x, ref y, Kernel.GetAngle(attacked.X, attacked.Y, attacker.X, attacker.Y));
attacker.Shift(x, y);
attack.X = x;
attack.Y = y;
//double dmg = (double)damage * 3.5;
//damage = (uint)dmg;
damage = damage / 8;
attack.Damage = damage;
attack.AttackType = Attack.FatalStrike;
}
}
//over:
var weapons = attacker.Owner.Weapons;
if (weapons.Item1 != null)
{
ConquerItem rightweapon = weapons.Item1;
ushort wep1subyte = (ushort)(rightweapon.ID / 1000), wep2subyte = 0;
bool wep1bs = false, wep2bs = false;
if (wep1subyte == 421)
{
wep1bs = true;
wep1subyte--;
}
ushort wep1spellid = 0, wep2spellid = 0;
Database.SpellInformation wep1spell = null, wep2spell = null;
if (Database.SpellTable.WeaponSpells.ContainsKey(wep1subyte))
{
var weaponskill = Database.SpellTable.WeaponSpells[wep1subyte];
for (int i = 0; i < weaponskill.Count; i++)
{
if (!doWep1Spell)
{
wep1spellid = weaponskill[i];
if (wep1subyte == 622)
{
if (attacker.WrathoftheEmperor == true)
{
if (attacker.WrathoftheEmperorStamp <= DateTime.Now.AddMilliseconds(1500))
{
wep1spellid = 12570;
}
attacker.WrathoftheEmperor = false;
}
}
if (attacker.Owner.Spells.ContainsKey(wep1spellid) && Database.SpellTable.SpellInformations.ContainsKey(wep1spellid))
{
wep1spell = Database.SpellTable.SpellInformations[wep1spellid][attacker.Owner.Spells[wep1spellid].Level];
doWep1Spell = Kernel.Rate(wep1spell.Percent);
if (attacked.EntityFlag == EntityFlag.Player && wep1spellid == 10490)
doWep1Spell = Kernel.Rate(15);
}
}
}
}
if (!doWep1Spell)
{
if (weapons.Item2 != null)
{
ConquerItem leftweapon = weapons.Item2;
wep2subyte = (ushort)(leftweapon.ID / 1000);
if (wep2subyte == 421)
{
wep2bs = true;
wep2subyte--;
}
if (Database.SpellTable.WeaponSpells.ContainsKey(wep2subyte))
{
var weaponskill2 = Database.SpellTable.WeaponSpells[wep2subyte];
for (int i = 0; i < weaponskill2.Count; i++)
{
if (!doWep2Spell)
{
wep2spellid = weaponskill2[i];
if (wep2subyte == 622)
{
if (attacker.WrathoftheEmperor == true)
{
if (attacker.WrathoftheEmperorStamp <= DateTime.Now.AddMilliseconds(1500))
{
wep2spellid = 12570;
}
attacker.WrathoftheEmperor = false;
}
}
if (attacker.Owner.Spells.ContainsKey(wep2spellid) && Database.SpellTable.SpellInformations.ContainsKey(wep2spellid))
{
wep2spell = Database.SpellTable.SpellInformations[wep2spellid][attacker.Owner.Spells[wep2spellid].Level];
doWep2Spell = Kernel.Rate(wep2spell.Percent);
if (attacked.EntityFlag == EntityFlag.Player && wep2spellid == 10490)
doWep2Spell = Kernel.Rate(15);
}
}
}
}
}
}
if (!attacker.Transformed)
{
if (doWep1Spell)
{
attack.AttackType = Attack.Magic;
attack.Decoded = true;
attack.weaponspell = true;
attack.X = attacked.X;
attack.Y = attacked.Y;
attack.Attacked = attacked.UID;
attack.Damage = wep1spell.ID;
goto restart;
}
if (doWep2Spell)
{
attack.AttackType = Attack.Magic;
attack.Decoded = true;
attack.weaponspell = true;
attack.X = attacked.X;
attack.Y = attacked.Y;
attack.Attacked = attacked.UID;
attack.Damage = wep2spell.ID;
goto restart;
}
if (wep1bs)
wep1subyte++;
if (attacker.EntityFlag == EntityFlag.Player && attacked.EntityFlag != EntityFlag.Player)
if (damage > attacked.Hitpoints)
{
attacker.Owner.IncreaseProficiencyExperience(Math.Min(damage, attacked.Hitpoints), wep1subyte);
if (wep2subyte != 0)
{
if (wep2bs)
wep2subyte++;
attacker.Owner.IncreaseProficiencyExperience(Math.Min(damage, attacked.Hitpoints), wep2subyte);
}
}
else
{
attacker.Owner.IncreaseProficiencyExperience(damage, wep1subyte);
if (wep2subyte != 0)
{
if (wep2bs)
wep2subyte++;
attacker.Owner.IncreaseProficiencyExperience(damage, wep2subyte);
}
}
}
}
else
{
if (!attacker.Transformed)
{
if (attacker.EntityFlag == EntityFlag.Player && attacked.EntityFlag != EntityFlag.Player)
if (damage > attacked.Hitpoints)
{
attacker.Owner.IncreaseProficiencyExperience(Math.Min(damage, attacked.Hitpoints), 0);
}
else
{
attacker.Owner.IncreaseProficiencyExperience(damage, 0);
}
}
}
ReceiveAttack(attacker, attacked, attack, ref damage, null);
attack.AttackType = Attack.Melee;
}
else
{
attacker.AttackPacket = null;
}
}
else if (attacker.Owner.Screen.TryGetSob(attack.Attacked, out attackedsob))
{
CheckForExtraWeaponPowers(attacker.Owner, null);
if (CanAttack(attacker, attackedsob, null))
{
ushort range = attacker.AttackRange;
if (attacker.Transformed)
range = (ushort)attacker.TransformationAttackRange;
if (Kernel.GetDistance(attacker.X, attacker.Y, attackedsob.X, attackedsob.Y) <= range)
{
attack.Effect1 = Attack.AttackEffects1.None;
uint damage = Game.Attacking.Calculate.Melee(attacker, attackedsob, ref attack);
var weapons = attacker.Owner.Weapons;
if (weapons.Item1 != null)
{
ConquerItem rightweapon = weapons.Item1;
ushort wep1subyte = (ushort)(rightweapon.ID / 1000), wep2subyte = 0;
bool wep1bs = false, wep2bs = false;
if (wep1subyte == 421)
{
wep1bs = true;
wep1subyte--;
}
ushort wep1spellid = 0, wep2spellid = 0;
Database.SpellInformation wep1spell = null, wep2spell = null;
if (Database.SpellTable.WeaponSpells.ContainsKey(wep1subyte))
{
var wep1 = Database.SpellTable.WeaponSpells[wep1subyte];
for (int i = 0; i < wep1.Count; i++)
{
if (!doWep1Spell)
{
wep1spellid = wep1[i];
if (attacker.Owner.Spells.ContainsKey(wep1spellid) && Database.SpellTable.SpellInformations.ContainsKey(wep1spellid))
{
wep1spell = Database.SpellTable.SpellInformations[wep1spellid][attacker.Owner.Spells[wep1spellid].Level];
doWep1Spell = Kernel.Rate(10);
}
}
}
}
if (!doWep1Spell)
{
if (weapons.Item2 != null)
{
ConquerItem leftweapon = weapons.Item2;
wep2subyte = (ushort)(leftweapon.ID / 1000);
if (wep2subyte == 421)
{
wep2bs = true;
wep2subyte--;
}
if (Database.SpellTable.WeaponSpells.ContainsKey(wep2subyte))
{
var wep2 = Database.SpellTable.WeaponSpells[wep2subyte];
for (int i = 0; i < wep2.Count; i++)
{
wep2spellid = wep2[i];
if (attacker.Owner.Spells.ContainsKey(wep2spellid) && Database.SpellTable.SpellInformations.ContainsKey(wep2spellid))
{
wep2spell = Database.SpellTable.SpellInformations[wep2spellid][attacker.Owner.Spells[wep2spellid].Level];
doWep2Spell = Kernel.Rate(10);
}
}
}
}
}
if (!attacker.Transformed)
{
if (doWep1Spell)
{
attack.AttackType = Attack.Magic;
attack.Decoded = true;
attack.weaponspell = true;
attack.X = attackedsob.X;
attack.Y = attackedsob.Y;
attack.Attacked = attackedsob.UID;
attack.Damage = wep1spell.ID;
goto restart;
}
if (doWep2Spell)
{
attack.AttackType = Attack.Magic;
attack.Decoded = true;
attack.weaponspell = true;
attack.X = attackedsob.X;
attack.Y = attackedsob.Y;
attack.Attacked = attackedsob.UID;
attack.Damage = wep2spell.ID;
goto restart;
}
if (attacker.MapID == 1039)
{
if (wep1bs)
wep1subyte++;
if (attacker.EntityFlag == EntityFlag.Player)
if (damage > attackedsob.Hitpoints)
{
attacker.Owner.IncreaseProficiencyExperience(Math.Min(damage, attackedsob.Hitpoints), wep1subyte);
if (wep2subyte != 0)
{
if (wep2bs)
wep2subyte++;
attacker.Owner.IncreaseProficiencyExperience(Math.Min(damage, attackedsob.Hitpoints), wep2subyte);
}
}
else
{
attacker.Owner.IncreaseProficiencyExperience(damage, wep1subyte);
if (wep2subyte != 0)
{
if (wep2bs)
wep2subyte++;
attacker.Owner.IncreaseProficiencyExperience(damage, wep2subyte);
}
}
}
}
}
attack.Damage = damage;
ReceiveAttack(attacker, attackedsob, attack, damage, null);
}
else
{
attacker.AttackPacket = null;
}
}
}
else
{
attacker.AttackPacket = null;
}
}
#endregion
private void CharactersCallback(GameState client, int time)
if (!Valid(client)) return;
Time32 Now32 = new Time32(time);
DateTime Now64 = DateTime.Now;
if (client.Spells != null)
if (!Valid(client)) return;
Time32 Now32 = new Time32(time);
DateTime Now64 = DateTime.Now;
if (client.Spells != null)
{
if (client.Spells.ContainsKey(12550) ||
client.Spells.ContainsKey(12560) ||
client.Spells.ContainsKey(12570))
{
if (!DataHolder.IsMonk(client.Entity.Class))
{
client.RemoveSpell(client.Spells[12550]);
client.RemoveSpell(client.Spells[12560]);
client.RemoveSpell(client.Spells[12570]);
}
}
}
public bool EpicMonk()
public bool EpicMonk()
{
if (EntityFlag == Game.EntityFlag.Player)
{
var weapons = Owner.Weapons;
if (weapons.Item1 != null)
if (weapons.Item1.ID / 1000 == 622)
return true;
if (weapons.Item2 != null)
if (weapons.Item2.ID / 1000 == 622)
return true;
}
return false;
}
public bool WrathoftheEmperor { get; set; }
public DateTime WrathoftheEmperorStamp { get; set; }
الذين يشاهدون محتوى الموضوع الآن : 1 ( الأعضاء 0 والزوار 1) | |
|
الموضوع | كاتب الموضوع | المنتدى | مشاركات | آخر مشاركة |
سورس كونكر 6120 فول فيكسد بدون مشاكل اتاكات كاملة | ElSaher | سورسات كونكر | 76 | يوم أمس 03:07 PM |
أرض Giant Chasm كاملة | BigBosses Added | khaledxodia | تطوير سيرفرات كونكر | 116 | 2024-07-02 09:35 PM |
كويست الكنج دوم كاملة بدون اي مشاكل | Mero | تطوير سيرفرات كونكر | 2 | 2019-10-23 02:29 PM |
deathwar السيرفر محمي 100 % الاتاك كامل جميع شخصيات كاملة العبه صعبه | محمودمحمدسالم | اعلانات السيرفيرات الشخصية | 2 | 2019-09-07 06:41 PM |
Power Arena كاملة 100% | محمد ياسر | تطوير سيرفرات كونكر | 0 | 2019-06-27 07:24 PM |