احصائياتى

الردود
3

المشاهدات
621
 
youssefabdelmanam
.:: عضو نشيط ::.

    غير متواجد

المشاركات
144

+التقييم
0.05

تاريخ التسجيل
May 2019

الاقامة

نظام التشغيل

رقم العضوية
238
2019-11-30, 01:51 PM
المشاركة 1
2019-11-30, 01:51 PM
المشاركة 1
افتراضي تمت الإجابة مشكلة في فيزيكال الننجا وتربل المونك والبيرت [Source khaled v5]
عندي مشكلة في فيزيكال الننجا وتربل والمونك والبيرت مبيشتغلش

باجي مثلا اضرب بي الننجا المفروض يطلع سكلة FatalSpain مبتطلعش بيضرب عادي من غير ما تطلع

ونفس الحوار دا في تربل المونك البيرت

ياريت الي يعرف الحل يقولي

وشكرا مقدما للجميع


أفضل جواب - كتبه Rider
Spell table


كود:
if (information.WeaponSubtype.Count != 0) 

بدل الي جواها ب دي

كود:
 switch (information.ID)
                {
                    case 
5010:
                    case 
7020:
                    case 
1290:
                    case 
1260:
                    case 
5030:
                    case 
5040:
                    case 
7000:
                    case 
7010:
                    case 
7030:
                    case 
7040:
                    case 
1250:
                    case 
5050:
                    case 
5020:
                    case 
10490:
                    case 
11140:
                    case 
1300:
                    case 
11990:
                    case 
12110:
                    case 
12240:
                    case 
12230:
                    case 
12220:
                    case 
12210:
                    case 
12570:
                    case 
12580:
                    case 
12590:
                    case 
12600:
                    case 
11230:
                    case 
13040:
                    case 
13050:
                        
//  if (spell.Distance >= 3)
                        //      spell.Distance = 3;
                        //  if (spell.Range > 3)
                        //      spell.Range = 3;
                        
for (int i = 0; i < information.WeaponSubtype.Count; i++)
                        {
                            var 
subtype = information.WeaponSubtype[i];
                            if (!
WeaponSpells.ContainsKey(subtype))
                                
WeaponSpells.Add(subtype, new List<ushort>());
                            if (!
WeaponSpells[subtype].Contains(information.ID))
                                
WeaponSpells[subtype].Add(information.ID);
                        }
                        break;
                } 

handle.cs
#region Melee


كود:
  #region Up - Down Sweep & Strike
                            
int rate = 0;
                            if (
attacker.Owner.Spells.ContainsKey(10490)) rate = 100 - Database.SpellTable.GetSpell(10490, attacker.Owner).Percent;
                            if (
Kernel.Rate(rate))
                            {
                                if (
attack.SpellID >= 12580 && attack.SpellID <= 12600 && attacker.EpicMonk())
                                {
                                    var 
spell = Database.SpellTable.GetSpell(attack.SpellID, attacker.Owner);
                                    if (
spell != null)
                                    {
                                        
SpellUse suse = new SpellUse(true);

                                        
suse.Attacker = attacker.UID;
                                        
suse.SpellID = attack.SpellID;
                                        
suse.SpellLevel = spell.ID;
                                        
suse.X = attacker.X;
                                        
suse.Y = attacker.Y;
                                        
Fan fan = new Fan(attacker.X, attacker.Y, attacked.X, attacked.Y, spell.Range, spell.Sector);

                                        foreach (
Interfaces.IMapObject _obj in attacker.Owner.Screen.Objects)
                                        {
                                            if (
_obj == null) continue;
                                            if (
_obj.MapObjType == MapObjectType.Monster || _obj.MapObjType == MapObjectType.Entity)
                                            {
                                                
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, spell, ref attack);
                                                        
damages = (damages * 22) / 100;
                                                        
attack.Attacked = attacked.UID;
                                                        
attack.Damage = damages;
                                                        
suse.Effect1 = attack.Effect1;
                                                        
suse.AddTarget(_obj, damages, attack);
                                                        
ReceiveAttack(attacker, attacked, attack, ref damages, null);
                                                    }
                                                }
                                            }
                                        }
                                        
attacker.SendScreen(suse);
                                        
attacker.AttackPacket = null;
                                        return;
                                    }
                                }
                            }
                            else if (
attacker.Owner.Spells.ContainsKey(10490) && attacker.Monk())
                            {
                                var 
spell = Database.SpellTable.GetSpell(10490, attacker.Owner);

                                if (
Kernel.Rate(spell.MonsterPower - 55) && attacker.Owner.Spells.ContainsKey(12570) && attacker.EpicMonk())
                                {
                                    
spell = Database.SpellTable.GetSpell(12570, attacker.Owner);
                                    if (
CanUseSpell(spell, attacker.Owner))
                                    {
                                        
PrepareSpell(spell, attacker.Owner);
                                        
SpellUse suse2 = new SpellUse(true);
                                        
suse2.Attacker = attacker.UID;
                                        
suse2.SpellID = spell.ID;
                                        
suse2.SpellLevel = spell.Level;
                                        if (
attacked != null)
                                        {
                                            
suse2.X = attacked.X;
                                            
suse2.Y = attacked.Y;
                                        }
                                        else
                                        {
                                            
suse2.X = attackedsob.X;
                                            
suse2.Y = attackedsob.Y;
                                        }
                                        
suse2.SpellEffect = 1;
                                        foreach (
Interfaces.IMapObject _obj in attacker.Owner.Screen.Objects)
                                        {
                                            if (
_obj == null) continue;
                                            if (
_obj.MapObjType == MapObjectType.Monster)
                                            {
                                                
attacked = _obj as Entity;
                                                if (
Kernel.GetDistance(attacker.X, attacker.Y, attacked.X, attacked.Y) <= spell.Range)
                                                {
                                                    if (
CanAttack(attacker, attacked, spell, attack.AttackType == Attack.Melee))
                                                    {
                                                        
uint damage = Game.Attacking.Calculate.Melee(attacker, attacked, spell, ref attack);
                                                        
damage = (damage * 22) / 100;
                                                        
attack.Damage = 0;
                                                        
ReceiveAttack(attacker, attacked, attack, ref damage, spell);
                                                        
suse2.AddTarget(attacked, damage, attack);
                                                    }
                                                }
                                            }
                                            else if (
_obj.MapObjType == MapObjectType.Entity)
                                            {
                                                
attacked = _obj as Entity;
                                                if (
Kernel.GetDistance(attacker.X, attacker.Y, attacked.X, attacked.Y) <= spell.Range)
                                                {
                                                    if (
CanAttack(attacker, attacked, spell, attack.AttackType == Attack.Melee))
                                                    {

                                                        
uint damage = Game.Attacking.Calculate.Melee(attacker, attacked, spell, ref attack);
                                                        
damage = (damage * 22) / 100;
                                                        
attack.Damage = 0;
                                                        
ReceiveAttack(attacker, attacked, attack, ref damage, spell);
                                                        
suse2.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) <= spell.Range)
                                                {
                                                    if (
CanAttack(attacker, attackedsob, spell))
                                                    {
                                                        
uint damage = Game.Attacking.Calculate.Melee(attacker, attackedsob, ref attack);
                                                        
damage = (damage * 22) / 100;
                                                        
attack.Damage = 0;
                                                        
ReceiveAttack(attacker, attackedsob, attack, damage, spell);
                                                        
suse2.AddTarget(attackedsob, damage, attack);
                                                    }
                                                }
                                            }
                                        }
                                        
attacker.Owner.SendScreen(suse2, true);
                                        
attacker.AttackPacket = null;
                                        return;

                                    }
                                }
                                else
                                {
                                    if (
CanUseSpell(spell, attacker.Owner))
                                    {
                                        
PrepareSpell(spell, attacker.Owner);
                                        
TryTrip suse = new TryTrip(true);
                                        
suse.Attacker = attacker.UID;
                                        
suse.SpellID = spell.ID;
                                        
suse.SpellLevel = spell.Level;
                                        
// if (Kernel.GetDistance(attacker.X, attacker.Y, X, Y) <= attacker.AttackRange + 1)
                                        
{
                                            if (
attackedsob != null)
                                            {
                                                if (
CanAttack(attacker, attackedsob, spell))
                                                {
                                                    
uint damage = Calculate.Melee(attacker, attackedsob, ref attack);
                                                    
damage = (damage * 22) / 100;
                                                    
suse.Attacked = attackedsob.UID;
                                                    
attack.Damage = 0;
                                                    
suse.Damage = damage;
                                                    
ReceiveAttack(attacker, attackedsob, attack, damage, spell);
                                                    
attacker.Owner.SendScreen(suse, true);
                                                }
                                            }
                                            else
                                            {
                                                if (
CanAttack(attacker, attacked, spell, attack.AttackType == Attack.Melee))
                                                {
                                                    
uint damage = Calculate.Melee(attacker, attacked, spell, ref attack);
                                                    
damage = (damage * 22) / 100;
                                                    
suse.Attacked = attacked.UID;
                                                    
suse.Damage = damage;
                                                    
attack.Damage = 0;
                                                    
ReceiveAttack(attacker, attacked, attack, ref damage, spell);
                                                    
attacker.Owner.SendScreen(suse, true);
                                                }
                                            }
                                            
attacker.AttackPacket = null; return;
                                        }
                                    }
                                }
                                
attacker.AttackPacket = null;
                                return;
                            }
                            
#endregion 

قديم 2019-11-30, 02:30 PM
المشاركة 2
Rider
.:: نائب المدير ::.
الإجابات المقدمة: 989
  • غير متواجد
افتراضي رد: مشكلة في فيزيكال الننجا وتربل المونك والبيرت [Source khaled v5]
Spell table


كود:
if (information.WeaponSubtype.Count != 0) 

بدل الي جواها ب دي

كود:
 switch (information.ID)
                {
                    case 
5010:
                    case 
7020:
                    case 
1290:
                    case 
1260:
                    case 
5030:
                    case 
5040:
                    case 
7000:
                    case 
7010:
                    case 
7030:
                    case 
7040:
                    case 
1250:
                    case 
5050:
                    case 
5020:
                    case 
10490:
                    case 
11140:
                    case 
1300:
                    case 
11990:
                    case 
12110:
                    case 
12240:
                    case 
12230:
                    case 
12220:
                    case 
12210:
                    case 
12570:
                    case 
12580:
                    case 
12590:
                    case 
12600:
                    case 
11230:
                    case 
13040:
                    case 
13050:
                        
//  if (spell.Distance >= 3)
                        //      spell.Distance = 3;
                        //  if (spell.Range > 3)
                        //      spell.Range = 3;
                        
for (int i = 0; i < information.WeaponSubtype.Count; i++)
                        {
                            var 
subtype = information.WeaponSubtype[i];
                            if (!
WeaponSpells.ContainsKey(subtype))
                                
WeaponSpells.Add(subtype, new List<ushort>());
                            if (!
WeaponSpells[subtype].Contains(information.ID))
                                
WeaponSpells[subtype].Add(information.ID);
                        }
                        break;
                } 

handle.cs
#region Melee


كود:
  #region Up - Down Sweep & Strike
                            
int rate = 0;
                            if (
attacker.Owner.Spells.ContainsKey(10490)) rate = 100 - Database.SpellTable.GetSpell(10490, attacker.Owner).Percent;
                            if (
Kernel.Rate(rate))
                            {
                                if (
attack.SpellID >= 12580 && attack.SpellID <= 12600 && attacker.EpicMonk())
                                {
                                    var 
spell = Database.SpellTable.GetSpell(attack.SpellID, attacker.Owner);
                                    if (
spell != null)
                                    {
                                        
SpellUse suse = new SpellUse(true);

                                        
suse.Attacker = attacker.UID;
                                        
suse.SpellID = attack.SpellID;
                                        
suse.SpellLevel = spell.ID;
                                        
suse.X = attacker.X;
                                        
suse.Y = attacker.Y;
                                        
Fan fan = new Fan(attacker.X, attacker.Y, attacked.X, attacked.Y, spell.Range, spell.Sector);

                                        foreach (
Interfaces.IMapObject _obj in attacker.Owner.Screen.Objects)
                                        {
                                            if (
_obj == null) continue;
                                            if (
_obj.MapObjType == MapObjectType.Monster || _obj.MapObjType == MapObjectType.Entity)
                                            {
                                                
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, spell, ref attack);
                                                        
damages = (damages * 22) / 100;
                                                        
attack.Attacked = attacked.UID;
                                                        
attack.Damage = damages;
                                                        
suse.Effect1 = attack.Effect1;
                                                        
suse.AddTarget(_obj, damages, attack);
                                                        
ReceiveAttack(attacker, attacked, attack, ref damages, null);
                                                    }
                                                }
                                            }
                                        }
                                        
attacker.SendScreen(suse);
                                        
attacker.AttackPacket = null;
                                        return;
                                    }
                                }
                            }
                            else if (
attacker.Owner.Spells.ContainsKey(10490) && attacker.Monk())
                            {
                                var 
spell = Database.SpellTable.GetSpell(10490, attacker.Owner);

                                if (
Kernel.Rate(spell.MonsterPower - 55) && attacker.Owner.Spells.ContainsKey(12570) && attacker.EpicMonk())
                                {
                                    
spell = Database.SpellTable.GetSpell(12570, attacker.Owner);
                                    if (
CanUseSpell(spell, attacker.Owner))
                                    {
                                        
PrepareSpell(spell, attacker.Owner);
                                        
SpellUse suse2 = new SpellUse(true);
                                        
suse2.Attacker = attacker.UID;
                                        
suse2.SpellID = spell.ID;
                                        
suse2.SpellLevel = spell.Level;
                                        if (
attacked != null)
                                        {
                                            
suse2.X = attacked.X;
                                            
suse2.Y = attacked.Y;
                                        }
                                        else
                                        {
                                            
suse2.X = attackedsob.X;
                                            
suse2.Y = attackedsob.Y;
                                        }
                                        
suse2.SpellEffect = 1;
                                        foreach (
Interfaces.IMapObject _obj in attacker.Owner.Screen.Objects)
                                        {
                                            if (
_obj == null) continue;
                                            if (
_obj.MapObjType == MapObjectType.Monster)
                                            {
                                                
attacked = _obj as Entity;
                                                if (
Kernel.GetDistance(attacker.X, attacker.Y, attacked.X, attacked.Y) <= spell.Range)
                                                {
                                                    if (
CanAttack(attacker, attacked, spell, attack.AttackType == Attack.Melee))
                                                    {
                                                        
uint damage = Game.Attacking.Calculate.Melee(attacker, attacked, spell, ref attack);
                                                        
damage = (damage * 22) / 100;
                                                        
attack.Damage = 0;
                                                        
ReceiveAttack(attacker, attacked, attack, ref damage, spell);
                                                        
suse2.AddTarget(attacked, damage, attack);
                                                    }
                                                }
                                            }
                                            else if (
_obj.MapObjType == MapObjectType.Entity)
                                            {
                                                
attacked = _obj as Entity;
                                                if (
Kernel.GetDistance(attacker.X, attacker.Y, attacked.X, attacked.Y) <= spell.Range)
                                                {
                                                    if (
CanAttack(attacker, attacked, spell, attack.AttackType == Attack.Melee))
                                                    {

                                                        
uint damage = Game.Attacking.Calculate.Melee(attacker, attacked, spell, ref attack);
                                                        
damage = (damage * 22) / 100;
                                                        
attack.Damage = 0;
                                                        
ReceiveAttack(attacker, attacked, attack, ref damage, spell);
                                                        
suse2.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) <= spell.Range)
                                                {
                                                    if (
CanAttack(attacker, attackedsob, spell))
                                                    {
                                                        
uint damage = Game.Attacking.Calculate.Melee(attacker, attackedsob, ref attack);
                                                        
damage = (damage * 22) / 100;
                                                        
attack.Damage = 0;
                                                        
ReceiveAttack(attacker, attackedsob, attack, damage, spell);
                                                        
suse2.AddTarget(attackedsob, damage, attack);
                                                    }
                                                }
                                            }
                                        }
                                        
attacker.Owner.SendScreen(suse2, true);
                                        
attacker.AttackPacket = null;
                                        return;

                                    }
                                }
                                else
                                {
                                    if (
CanUseSpell(spell, attacker.Owner))
                                    {
                                        
PrepareSpell(spell, attacker.Owner);
                                        
TryTrip suse = new TryTrip(true);
                                        
suse.Attacker = attacker.UID;
                                        
suse.SpellID = spell.ID;
                                        
suse.SpellLevel = spell.Level;
                                        
// if (Kernel.GetDistance(attacker.X, attacker.Y, X, Y) <= attacker.AttackRange + 1)
                                        
{
                                            if (
attackedsob != null)
                                            {
                                                if (
CanAttack(attacker, attackedsob, spell))
                                                {
                                                    
uint damage = Calculate.Melee(attacker, attackedsob, ref attack);
                                                    
damage = (damage * 22) / 100;
                                                    
suse.Attacked = attackedsob.UID;
                                                    
attack.Damage = 0;
                                                    
suse.Damage = damage;
                                                    
ReceiveAttack(attacker, attackedsob, attack, damage, spell);
                                                    
attacker.Owner.SendScreen(suse, true);
                                                }
                                            }
                                            else
                                            {
                                                if (
CanAttack(attacker, attacked, spell, attack.AttackType == Attack.Melee))
                                                {
                                                    
uint damage = Calculate.Melee(attacker, attacked, spell, ref attack);
                                                    
damage = (damage * 22) / 100;
                                                    
suse.Attacked = attacked.UID;
                                                    
suse.Damage = damage;
                                                    
attack.Damage = 0;
                                                    
ReceiveAttack(attacker, attacked, attack, ref damage, spell);
                                                    
attacker.Owner.SendScreen(suse, true);
                                                }
                                            }
                                            
attacker.AttackPacket = null; return;
                                        }
                                    }
                                }
                                
attacker.AttackPacket = null;
                                return;
                            }
                            
#endregion 


قديم 2019-11-30, 09:28 PM
المشاركة 3
youssefabdelmanam
.:: عضو نشيط ::.
  • غير متواجد
افتراضي رد: مشكلة في فيزيكال الننجا وتربل المونك والبيرت [Source khaled v5]
spell table


كود:
if (information.weaponsubtype.count != 0) 

بدل الي جواها ب دي

كود:
 switch (information.id)
                {
                    case 
5010:
                    Case 
7020:
                    Case 
1290:
                    Case 
1260:
                    Case 
5030:
                    Case 
5040:
                    Case 
7000:
                    Case 
7010:
                    Case 
7030:
                    Case 
7040:
                    Case 
1250:
                    Case 
5050:
                    Case 
5020:
                    Case 
10490:
                    Case 
11140:
                    Case 
1300:
                    Case 
11990:
                    Case 
12110:
                    Case 
12240:
                    Case 
12230:
                    Case 
12220:
                    Case 
12210:
                    Case 
12570:
                    Case 
12580:
                    Case 
12590:
                    Case 
12600:
                    Case 
11230:
                    Case 
13040:
                    Case 
13050:
                        
//  if (spell.distance >= 3)
                        //      spell.distance = 3;
                        //  if (spell.range > 3)
                        //      spell.range = 3;
                        
for (int i = 0; i < information.weaponsubtype.count; i++)
                        {
                            var 
subtype = information.weaponsubtype[i];
                            if (!
weaponspells.containskey(subtype))
                                
weaponspells.add(subtype, new list<ushort>());
                            if (!
weaponspells[subtype].contains(information.id))
                                
weaponspells[subtype].add(information.id);
                        }
                        break;
                } 

handle.cs
#region melee


كود:
  #region up - down sweep & strike
                            
int rate = 0;
                            if (
attacker.owner.spells.containskey(10490)) rate = 100 - database.spelltable.getspell(10490, attacker.owner).percent;
                            if (
kernel.rate(rate))
                            {
                                if (
attack.spellid >= 12580 && attack.spellid <= 12600 && attacker.epicmonk())
                                {
                                    var 
spell = database.spelltable.getspell(attack.spellid, attacker.owner);
                                    if (
spell != null)
                                    {
                                        
spelluse suse = new spelluse(true);

                                        
suse.attacker = attacker.uid;
                                        
suse.spellid = attack.spellid;
                                        
suse.spelllevel = spell.id;
                                        
suse.x = attacker.x;
                                        
suse.y = attacker.y;
                                        
fan fan = new fan(attacker.x, attacker.y, attacked.x, attacked.y, spell.range, spell.sector);

                                        foreach (
interfaces.imapobject _obj in attacker.owner.screen.objects)
                                        {
                                            if (
_obj == null) continue;
                                            if (
_obj.mapobjtype == mapobjecttype.monster || _obj.mapobjtype == mapobjecttype.entity)
                                            {
                                                
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, spell, ref attack);
                                                        
damages = (damages * 22) / 100;
                                                        
attack.attacked = attacked.uid;
                                                        
attack.damage = damages;
                                                        
suse.effect1 = attack.effect1;
                                                        
suse.addtarget(_obj, damages, attack);
                                                        
receiveattack(attacker, attacked, attack, ref damages, null);
                                                    }
                                                }
                                            }
                                        }
                                        
attacker.sendscreen(suse);
                                        
attacker.attackpacket = null;
                                        return;
                                    }
                                }
                            }
                            else if (
attacker.owner.spells.containskey(10490) && attacker.monk())
                            {
                                var 
spell = database.spelltable.getspell(10490, attacker.owner);

                                if (
kernel.rate(spell.monsterpower - 55) && attacker.owner.spells.containskey(12570) && attacker.epicmonk())
                                {
                                    
spell = database.spelltable.getspell(12570, attacker.owner);
                                    if (
canusespell(spell, attacker.owner))
                                    {
                                        
preparespell(spell, attacker.owner);
                                        
spelluse suse2 = new spelluse(true);
                                        
suse2.attacker = attacker.uid;
                                        
suse2.spellid = spell.id;
                                        
suse2.spelllevel = spell.level;
                                        if (
attacked != null)
                                        {
                                            
suse2.x = attacked.x;
                                            
suse2.y = attacked.y;
                                        }
                                        else
                                        {
                                            
suse2.x = attackedsob.x;
                                            
suse2.y = attackedsob.y;
                                        }
                                        
suse2.spelleffect = 1;
                                        foreach (
interfaces.imapobject _obj in attacker.owner.screen.objects)
                                        {
                                            if (
_obj == null) continue;
                                            if (
_obj.mapobjtype == mapobjecttype.monster)
                                            {
                                                
attacked = _obj as entity;
                                                if (
kernel.getdistance(attacker.x, attacker.y, attacked.x, attacked.y) <= spell.range)
                                                {
                                                    if (
canattack(attacker, attacked, spell, attack.attacktype == attack.melee))
                                                    {
                                                        
uint damage = game.attacking.calculate.melee(attacker, attacked, spell, ref attack);
                                                        
damage = (damage * 22) / 100;
                                                        
attack.damage = 0;
                                                        
receiveattack(attacker, attacked, attack, ref damage, spell);
                                                        
suse2.addtarget(attacked, damage, attack);
                                                    }
                                                }
                                            }
                                            else if (
_obj.mapobjtype == mapobjecttype.entity)
                                            {
                                                
attacked = _obj as entity;
                                                if (
kernel.getdistance(attacker.x, attacker.y, attacked.x, attacked.y) <= spell.range)
                                                {
                                                    if (
canattack(attacker, attacked, spell, attack.attacktype == attack.melee))
                                                    {

                                                        
uint damage = game.attacking.calculate.melee(attacker, attacked, spell, ref attack);
                                                        
damage = (damage * 22) / 100;
                                                        
attack.damage = 0;
                                                        
receiveattack(attacker, attacked, attack, ref damage, spell);
                                                        
suse2.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) <= spell.range)
                                                {
                                                    if (
canattack(attacker, attackedsob, spell))
                                                    {
                                                        
uint damage = game.attacking.calculate.melee(attacker, attackedsob, ref attack);
                                                        
damage = (damage * 22) / 100;
                                                        
attack.damage = 0;
                                                        
receiveattack(attacker, attackedsob, attack, damage, spell);
                                                        
suse2.addtarget(attackedsob, damage, attack);
                                                    }
                                                }
                                            }
                                        }
                                        
attacker.owner.sendscreen(suse2, true);
                                        
attacker.attackpacket = null;
                                        return;

                                    }
                                }
                                else
                                {
                                    if (
canusespell(spell, attacker.owner))
                                    {
                                        
preparespell(spell, attacker.owner);
                                        
trytrip suse = new trytrip(true);
                                        
suse.attacker = attacker.uid;
                                        
suse.spellid = spell.id;
                                        
suse.spelllevel = spell.level;
                                        
// if (kernel.getdistance(attacker.x, attacker.y, x, y) <= attacker.attackrange + 1)
                                        
{
                                            if (
attackedsob != null)
                                            {
                                                if (
canattack(attacker, attackedsob, spell))
                                                {
                                                    
uint damage = calculate.melee(attacker, attackedsob, ref attack);
                                                    
damage = (damage * 22) / 100;
                                                    
suse.attacked = attackedsob.uid;
                                                    
attack.damage = 0;
                                                    
suse.damage = damage;
                                                    
receiveattack(attacker, attackedsob, attack, damage, spell);
                                                    
attacker.owner.sendscreen(suse, true);
                                                }
                                            }
                                            else
                                            {
                                                if (
canattack(attacker, attacked, spell, attack.attacktype == attack.melee))
                                                {
                                                    
uint damage = calculate.melee(attacker, attacked, spell, ref attack);
                                                    
damage = (damage * 22) / 100;
                                                    
suse.attacked = attacked.uid;
                                                    
suse.damage = damage;
                                                    
attack.damage = 0;
                                                    
receiveattack(attacker, attacked, attack, ref damage, spell);
                                                    
attacker.owner.sendscreen(suse, true);
                                                }
                                            }
                                            
attacker.attackpacket = null; return;
                                        }
                                    }
                                }
                                
attacker.attackpacket = null;
                                return;
                            }
                            
#endregion 
اشكرك جدا الحل نافع

قديم 2019-12-01, 12:14 AM
المشاركة 4
Rider
.:: نائب المدير ::.
الإجابات المقدمة: 989
  • غير متواجد
افتراضي رد: مشكلة في فيزيكال الننجا وتربل المونك والبيرت [Source khaled v5]
العفو <3


العلامات المرجعية



الذين يشاهدون محتوى الموضوع الآن : 1 ( الأعضاء 0 والزوار 1)
 

الانتقال السريع

المواضيع المتشابهه للموضوع: مشكلة في فيزيكال الننجا وتربل المونك والبيرت [Source khaled v5]
الموضوع كاتب الموضوع المنتدى مشاركات آخر مشاركة
اضافة المونك كامل Hazem تطوير سيرفرات كونكر 7 2020-02-15 10:59 PM
مشكلة الننجا والرهاب لزم الاميل يبا جمب الاميل لزق علشان يضرب في بعض Mawdo3jded مشكلات السيرفيرات كونكر الشخصيه 2 2019-12-05 07:28 PM
مشكلة بخصوص البروفكشن [Source Khaled v5] youssefabdelmanam مشكلات السيرفيرات كونكر الشخصيه 3 2019-12-01 12:18 AM
حل مشكلة ضربة فيزيكال للنينجا و بروسلي[RayzoV3] Rider تطوير سيرفرات كونكر 1 2019-11-22 07:08 PM
مشكلة فى اسكلة بتاعت الننجا بعد ما نزلت شخصية تانية osama مشكلات السيرفيرات كونكر الشخصيه 4 2019-08-08 09:13 PM


الساعة الآن 03:45 PM