|
You last visited: Today at 12:21
Advertisement
archer dmg
Discussion on archer dmg within the CO2 Private Server forum part of the Conquer Online 2 category.
11/10/2014, 00:10
|
#1
|
elite*gold: 0
Join Date: Oct 2007
Posts: 50
Received Thanks: 0
|
archer dmg
what wrong? full +12 archer attacking only 18k birdmands... can any help me?
Quote:
#region Ranged
else if (attack.AttackType == Attack.Ranged)
{
if (attacker.Owner.Screen.TryGetValue(attack.Attacked , out attacked))
{
CheckForExtraWeaponPowers(attacker.Owner, attacked);
if (attacker.Owner.Equipment.TryGetItem(ConquerItem.L eftWeapon) == null)
return;
if (!CanAttack(attacker, attacked, null, attack.AttackType == Attack.Melee))
return;
if (!attacker.Owner.Equipment.Free((byte)ConquerItem. LeftWeapon))
{
Interfaces.IConquerItem arrow = attacker.Owner.Equipment.TryGetItem(ConquerItem.Le ftWeapon);
arrow.Durability -= 1;
ItemUsage usage = new ItemUsage(true) { UID = arrow.UID, dwParam = arrow.Durability, ID = ItemUsage.UpdateDurability };
usage.Send(attacker.Owner);
if (arrow.Durability <= 0 || arrow.Durability > 5000)
{
Network.PacketHandler.ReloadArrows(attacker.Owner. Equipment.TryGetItem(ConquerItem.LeftWeapon), attacker.Owner);
}
}
if (ServerBase.Kernel.GetDistance(attacker.X, attacker.Y, attacked.X, attacked.Y) <= ServerBase.Constants.pScreenDistance)
{
uint damage = Game.Attacking.Calculate.Ranged(attacker, attacked);
attack.Damage = damage;
if (attacker.EntityFlag == EntityFlag.Player && attacked.EntityFlag != EntityFlag.Player)
if (damage > attacked.Hitpoints)
{
attacker.Owner.IncreaseProficiencyExperience(Math. Min(damage, attacked.Hitpoints), 500);
}
else
{
attacker.Owner.IncreaseProficiencyExperience(damag e, 500);
}
ReceiveAttack(attacker, attacked, attack, damage, null);
}
}
else if (attacker.Owner.Screen.TryGetSob(attack.Attacked, out attackedsob))
{
if (CanAttack(attacker, attackedsob, null))
{
if (attacker.Owner.Equipment.TryGetItem(ConquerItem.L eftWeapon) == null)
return;
if (attacker.MapID != 1039)
{
if (!attacker.Owner.Equipment.Free((byte)ConquerItem. LeftWeapon))
{
Interfaces.IConquerItem arrow = attacker.Owner.Equipment.TryGetItem(ConquerItem.Le ftWeapon);
arrow.Durability -= 1;
ItemUsage usage = new ItemUsage(true) { UID = arrow.UID, dwParam = arrow.Durability, ID = ItemUsage.UpdateDurability };
usage.Send(attacker.Owner);
if (arrow.Durability <= 0 || arrow.Durability > 5000)
{
Network.PacketHandler.ReloadArrows(attacker.Owner. Equipment.TryGetItem(ConquerItem.LeftWeapon), attacker.Owner);
}
}
}
if (ServerBase.Kernel.GetDistance(attacker.X, attacker.Y, attackedsob.X, attackedsob.Y) <= ServerBase.Constants.pScreenDistance)
{
uint damage = Game.Attacking.Calculate.Ranged(attacker, attackedsob);
attack.Damage = damage;
ReceiveAttack(attacker, attackedsob, attack, damage, null);
if (damage > attackedsob.Hitpoints)
{
attacker.Owner.IncreaseProficiencyExperience(Math. Min(damage, attackedsob.Hitpoints), 500);
}
else
{
attacker.Owner.IncreaseProficiencyExperience(damag e, 500);
}
}
}
}
else
{
attacker.AttackPacket = null;
}
}
#endregion Ranged
|
|
|
|
11/10/2014, 08:38
|
#2
|
elite*gold: 0
Join Date: Jan 2007
Posts: 485
Received Thanks: 272
|
How about looking in what Game.Attacking.Calculate.Range does?
|
|
|
11/10/2014, 09:45
|
#3
|
elite*gold: 0
Join Date: Oct 2007
Posts: 50
Received Thanks: 0
|
message
here
Quote:
public static uint Ranged(Entity attacker, Entity attacked)
{
if (attacked.EntityFlag == EntityFlag.Player)
{
Conquer_Online_Server.Network.BlessEffect.Effect(a ttacked);
}
//int Damage = 0;
int Damage = Kernel.Rand.Next((int)attacker.MinAttack, (int)attacker.MaxAttack);
// Database.SpellInformation spell = null;
Durability(attacker, attacked, null);
if (attacked.ContainsFlag(Network.GamePackets.Update. Flags.ShurikenVortex))
return 1;
if (attacker.Transformed)
return 0;
if (attacked.Name == "Guard1")
return 1;
if (attacker.Name.Contains("[Guard]"))
return 700000;
if (attacked.Name.Contains("[GM]"))
return 1;
if (attacker.Name.Contains("[GM]"))
return 700000;
//Damage = ServerBase.Kernel.Random.Next(Math.Min((int)attack er.MinAttack, (int)attacker.MaxAttack), Math.Max((int)attacker.MinAttack, (int)attacker.MaxAttack) + 1);
uint add = 0;
int D = 0;
if (attacked.ContainsFlag(Network.GamePackets.Update. Flags.MagicShield))
{
double pr = 0;
switch (attacked.ShieldTime)
{
case 60:
case 65: pr = 1.3; break;
case 70:
case 75: pr = 15; break;
case 120:
case 80: pr = 2; break;
}
D = (int)(attacked.Defence * pr);
}
if (attacked.ContainsFlag(Network.GamePackets.Update. Flags.AzureShield))
{
double pr = 0;
switch (attacked.AzureTime)
{
case 60:
case 65: pr = 1.3; break;
case 70:
case 75: pr = 2; break;
case 120:
case 80: pr = 2; break;
}
Damage -= (int)(attacked.Defence * pr);
}
if (attacker.ContainsFlag(Network.GamePackets.Update. Flags.Stigma))
{
double pr = 0;
switch (attacker.StigmaTime)
{
case 60:
case 65: pr = 0.10; break;
case 70:
case 75: pr = .20; break;
case 80: pr = .30; break;
}
Damage = Damage + (int)Math.Floor(Damage * pr);
}
if (attacked.Dodge > 0)
{
double Dodge = 0;
if (attacked.Dodge <= 94)
Dodge = attacked.Dodge * 0.01;
else
Dodge = 94 * 0.01;
Damage = (int)Math.Floor(Damage - (Damage * Dodge) - D * 20 / 100) / 3;
}
if (attacked.Reborn == 1)
{
Damage = (int)Math.Floor(Damage * .7 - D * 20 / 100);
}
else if (attacked.Reborn == 2)
{
Damage = (int)Math.Floor(Damage * .7 - D * 20 / 100);
if (attacker.Reborn < 2)
Damage = (int)Math.Floor(Damage * .5);
}
double Tort = 0;
Tort += attacked.Gems[7] * 0.06;
Damage = (int)Math.Floor(Damage * (1 - Tort));
if (attacked.ItemBless > 0)
{
Damage = (int)Math.Floor(Damage * (1 - (attacked.ItemBless * 0.01)));
}
if (attacker.ContainsFlag(Network.GamePackets.Update. Flags.Stigma))
Damage = (int)(Damage * attacker.StigmaIncrease);
Damage += attacker.PhysicalDamageIncrease;
Damage -= attacked.PhysicalDamageDecrease;
if (attacker.EntityFlag == EntityFlag.Player)
{
|
Quote:
public static uint Ranged(Entity attacker, SobNpcSpawn attacked)
{
int Damage = 0;
Durability(attacker, null, null);
if (attacker.Transformed)
return 0;
if (attacked.UID == 810 && attacker.Owner.Guild != null)
{
if (Game.ConquerStructures.Society.GuildWar.PoleKeepe r == attacker.Owner.Guild)
{
return 0;
}
}
Damage = ServerBase.Kernel.Random.Next(Math.Min((int)attack er.MinAttack, (int)attacker.MaxAttack), Math.Max((int)attacker.MinAttack, (int)attacker.MaxAttack) + 1);
if (attacker.OnIntensify && Time32.Now >= attacker.IntensifyStamp.AddSeconds(4))
{
Damage *= 2;
attacker.OnIntensify = false;
}
if (ServerBase.Kernel.Rate(5))
{
if (attacker.EntityFlag == EntityFlag.Player)
{
if (attacker.Owner.BlessTime > 0)
{
Damage *= 2;
_String str = new _String(true);
str.UID = attacker.UID;
str.TextsCount = 1;
str.Type = _String.Effect;
str.Texts.Add("LuckyGuy");
attacker.Owner.SendScreen(str, true);
}
}
}
if (attacker.ContainsFlag(Network.GamePackets.Update. Flags.Stigma))
if (!attacker.Transformed)
Damage = (int)(Damage * attacker.StigmaIncrease);
Damage += attacker.PhysicalDamageIncrease;
if (Damage <= 0)
Damage = 1;
return (uint)Damage;
}
public static void Vitals(Entity attacker, bool first)
{
//if (!first)
//{
// attacker.MaxHitpoints -= attacker.Hitpoints;
// attacker.MaxMana -= attacker.Mana;
//}
//HP
double HP = 0;
double HpFactor = 24;
if ((int)attacker.Class >= 11 && (int)attacker.Class <= 15)
{
switch (attacker.Class)
{
case 11:
{
HpFactor = 25.65;
break;
}
case 12:
{
HpFactor = 26.64;
break;
}
case 13:
{
HpFactor = 27.3;
break;
}
case 14:
{
HpFactor = 27.96;
break;
}
case 15:
{
HpFactor = 28.95;
break;
}
}
}
if ((int)attacker.Class >= 61 && (int)attacker.Class <= 65)
{
switch (attacker.Class)
{
case 11:
{
HpFactor = 25.65;
break;
}
case 12:
{
HpFactor = 26.64;
break;
}
case 13:
{
HpFactor = 27.3;
break;
}
case 14:
{
HpFactor = 27.96;
break;
}
case 15:
{
HpFactor = 28.95;
break;
}
}
}
HP += (attacker.Vitality * HpFactor);
HP += (attacker.Spirit * 3) + (attacker.Dodge * 3) + (attacker.Strength * 3);
//CSocket.Client.MaxHP = (int)Math.Floor(HP);
attacker.Hitpoints = (uint)Math.Floor(HP);
attacker.MaxHitpoints += attacker.Hitpoints;
//Mana
int Mana = 0;
int multiplier = 5;
if ((int)attacker.Class >= 100 && (int)attacker.Class <= 145)
{
multiplier = 30;
}
Mana = attacker.Spirit * multiplier;
attacker.Mana = (ushort)Mana;
attacker.MaxMana += attacker.Mana;
}
|
|
|
|
11/11/2014, 06:07
|
#4
|
elite*gold: 0
Join Date: Dec 2010
Posts: 105
Received Thanks: 13
|
"if (attacked.Name == "Guard1")
return 1;
if (attacker.Name.Contains("[Guard]"))
return 700000;"
Oh come on not that base...
|
|
|
 |
Similar Threads
|
[Selling] Level 130 Archer-Archer-Trojan Myth->Gryphon |250BP|
11/15/2013 - Conquer Online 2 Trading - 4 Replies
Selling my level 130 Archer-Archer-Trojan (2nd reborn) on Myth, Gryphon server. Got lots of goodies.
1. Super TrojansCoronet lvl 120 +5 1sc + 1 SDG
2. Super Necklace lvl 112 +4 1sc + 1SDG
3. Super ring lvl 116 +4
4. Super boots lvl 120 +4
5. Super Club lvl 130 +6 2sc + 2SDG
6. Super Club lvl 130 +5 2sc + 2SDG
7. SuperTrojanArmor lvl 121 +5 1sc + 1SDG
8. SuperHeavenFan+5 lvl 100 1sc
|
B> high lvl archer~tro~archer on Ruby server-Dont need gear
11/08/2010 - Conquer Online 2 Trading - 1 Replies
please only post if you are on Ruby server ty:bandit:
|
WTT Archer 60lvl + archer 51lvl + elem 46 for Character with realm set or anyting
07/24/2009 - Archlord Trading - 0 Replies
I want trade my 3 chars with cc good eq etc. I want for this 3 charss char with realm set or anything from realm... char can be 1lv... offers pls send to my mail [email protected]
|
S> 2nd RB Female Archer Archer-Trojan-Archer 130-130-112
09/29/2008 - Conquer Online 2 Trading - 1 Replies
Hey, im selling an Archer-Trojan-Archer female account who has the ability to use chain cyclone which is awesome for plvling. She currently has 236Pot with her mentor on and w/o her on she has 210 potency (for a lvl 112 archer this is great). As i mentioned before she is lvl 130-130-112. Now for her gear:
Ears Super +5 SDG lvl 112
Necky Super +5 SDG lvl 112
Ring Super +6 SDG lvl 110
Bow Super +6 2xSDG lvl 110
Coat Super +6 2xSDG lvl 112
Boots Super +6 SDG lvl 110
Miraculous Gourd
Good...
|
All times are GMT +1. The time now is 12:21.
|
|