Register for your free account! | Forgot your password?

You last visited: Today at 12:45

  • Please register to post and access all features, it's quick, easy and FREE!


[Release]Fixed SS/FB System

Discussion on [Release]Fixed SS/FB System within the CO2 PServer Guides & Releases forum part of the CO2 Private Server category.

Reply
 
Old 02/01/2010, 09:57   #16
 
elite*gold: 0
Join Date: Aug 2008
Posts: 272
Received Thanks: 61
Quote:
foreach (Character C in World.H_Chars.Values)
{
if (C.Alive && (C != User || Info.Damageing == DamageType.HealHP || Info.Damageing == DamageType.HealMP))
{
if ((!RangeFromChar && MyMath.PointDistance(AimX, AimY, C.Loc.X, C.Loc.Y) <= Info.MaxDist) || MyMath.PointDistance(User.Loc.X, User.Loc.Y, C.Loc.X, C.Loc.Y) <= Info.MaxDist)
if (Info.Targetting == TargetType.Sector && InSector(C.Loc.X, C.Loc.Y) || Info.Targetting != TargetType.Sector)
if (Info.Targetting == TargetType.Linear && Line.Contains(new coords(C.Loc.X, C.Loc.Y)) || Info.Targetting != TargetType.Linear)
if (C.PKAble(User.PKMode, User) && !PlayerTargets.Contains(C) && !World.NoPKMaps.Contains(User.Loc.Map) || Info.ExtraEff == ExtraEffect.UnMount)
if (Game.World.NoPKMaps.Contains(User.Loc.Map) && GetDamage(C) == 0 || !Game.World.NoPKMaps.Contains(User.Loc.Map) || (Info.ExtraEff == ExtraEffect.UnMount && C.StatEff.Contains(StatusEffectEn.Ride)) && C.Equips.Steed.Plus < User.Equips.Steed.Plus)
if (true)
PlayerTargets.Add(C, GetDamage(C));
}
}

give me erro that :S



ramix is offline  
Old 02/01/2010, 10:01   #17
 
elite*gold: 0
Join Date: Dec 2007
Posts: 378
Received Thanks: 163
Quote:
Originally Posted by ramix View Post
give me erro that :S
You need to add the definition of "Line". Look at the other adds to figure out what to do, it's fairly simple.


walmartboi is offline  
Thanks
1 User
Old 02/01/2010, 10:09   #18
 
elite*gold: 0
Join Date: Aug 2008
Posts: 272
Received Thanks: 61
ya loool xD i fixed that
ramix is offline  
Old 02/01/2010, 10:46   #19
 
elite*gold: 0
Join Date: Apr 2006
Posts: 532
Received Thanks: 66
I have the same problem as Ramix but I have no idea on adding a definition >.< I also have the Add takes 2 arguments problem also and yes I moved it from under to over and it got rid of most the problems now I just have the four errors definition problem and three Add takes 2 arguments problem please help lol.

[edit] In my source it is not "public static class mymath" it is just "public class mymath" and if I change it to "public static class mymath" then I only get the one error and that error is "the name line does not exist in the current context"


WHITELIONX is offline  
Old 02/01/2010, 11:42   #20
 
elite*gold: 0
Join Date: Aug 2008
Posts: 272
Received Thanks: 61
Quote:
List<coords> Line = new List<coords>(5);
if (Info.Targetting == TargetType.Linear)
Line = MyMath.LineCoords(User.Loc.X, User.Loc.Y, AimX, AimY, 10);

foreach (Character C in World.H_Chars.Values)
{
if (C.Alive && (C != User || Info.Damageing == DamageType.HealHP || Info.Damageing == DamageType.HealMP))
{
if ((!RangeFromChar && MyMath.PointDistance(AimX, AimY, C.Loc.X, C.Loc.Y) <= Info.MaxDist) || MyMath.PointDistance(User.Loc.X, User.Loc.Y, C.Loc.X, C.Loc.Y) <= Info.MaxDist)
if (Info.Targetting == TargetType.Sector && InSector(C.Loc.X, C.Loc.Y) || Info.Targetting != TargetType.Sector)
if (Info.Targetting == TargetType.Linear && Line.Contains(new coords(C.Loc.X, C.Loc.Y)) || Info.Targetting != TargetType.Linear)
if (C.PKAble(User.PKMode, User) && !PlayerTargets.Contains(C) && !World.NoPKMaps.Contains(User.Loc.Map) || Info.ExtraEff == ExtraEffect.UnMount)
if (Game.World.NoPKMaps.Contains(User.Loc.Map) && GetDamage(C) == 0 || !Game.World.NoPKMaps.Contains(User.Loc.Map) || (Info.ExtraEff == ExtraEffect.UnMount && C.StatEff.Contains(StatusEffectEn.Ride)) && C.Equips.Steed.Plus < User.Equips.Steed.Plus)
if (true)
PlayerTargets.Add(C, GetDamage(C));
}
}

you only need added this in "foreach (Character C in World.H_Chars.Values)"


why in server my friend i cant atack with 2 swords and ss :S ????
ramix is offline  
Thanks
3 Users
Old 02/01/2010, 12:35   #21
 
elite*gold: 0
Join Date: Apr 2006
Posts: 532
Received Thanks: 66
Thank you ramix It sorted the problem out hehe
WHITELIONX is offline  
Old 02/01/2010, 13:19   #22
 
elite*gold: 0
Join Date: Dec 2007
Posts: 378
Received Thanks: 163
This alorithm is actually quite buggy, the original one kind of beats it if you ask me.
walmartboi is offline  
Old 02/01/2010, 16:11   #23
 
elite*gold: 0
Join Date: Mar 2006
Posts: 61
Received Thanks: 88
Great job, good algoritm for line, it's really work a lot better from orginal **** fb/ss.
glover is offline  
Old 02/01/2010, 16:14   #24
 
elite*gold: 0
Join Date: Oct 2006
Posts: 28
Received Thanks: 0
Quote:
Originally Posted by WHITELIONX View Post
I have the same problem as Ramix but I have no idea on adding a definition >.< I also have the Add takes 2 arguments problem also and yes I moved it from under to over and it got rid of most the problems now I just have the four errors definition problem and three Add takes 2 arguments problem please help lol.

[edit] In my source it is not "public static class mymath" it is just "public class mymath" and if I change it to "public static class mymath" then I only get the one error and that error is "the name line does not exist in the current context"
same problem as you, only it seems like u fixed it while i cant :P


Edit: Could u not just upload ur mymath.cs file :P
w.maatman is offline  
Old 02/01/2010, 18:10   #25
 
elite*gold: 0
Join Date: Jun 2009
Posts: 787
Received Thanks: 312
You have to mark the class as static to make extensions inside of it.
_tao4229_ is offline  
Old 02/01/2010, 18:18   #26
 
elite*gold: 0
Join Date: Oct 2006
Posts: 52
Received Thanks: 8
only problem i get after making
Code:
    public class MyMath
into
Code:
    public static class MyMath
i get this error
ASSN9NE is offline  
Old 02/01/2010, 18:38   #27
 
elite*gold: 0
Join Date: Oct 2006
Posts: 52
Received Thanks: 8
well i figured out my own prob for the ones that cant figure it out try the following

search for:

Code:
                    else if (Info.Targetting != TargetType.Sector && Info.Targetting != TargetType.Linear && Info.Targetting != TargetType.Range && Info.Targetting != TargetType.FromPoint)
then in this area:

Code:
                    }
                    else
                        RangeFromChar = false;
                    foreach (Character C in World.H_Chars.Values)
                    {
your gonna add:

Code:
                    List<coords> Line = new List<coords>(5);
so it looks like this:

Code:
                    }
                    else
                        RangeFromChar = false;
                    List<coords> Line = new List<coords>(5);
                    foreach (Character C in World.H_Chars.Values)
                    {
that should fix your Line error
ASSN9NE is offline  
Old 02/01/2010, 20:06   #28
 
elite*gold: 0
Join Date: Oct 2006
Posts: 52
Received Thanks: 8
ok i changed MyMath 2 this public static class MyMath and did the List<coords> steps then
fb/ss works fine against guards,monsters & tg steaks but if i go and pvp fb/ss dont work player Vs player
ASSN9NE is offline  
Old 02/01/2010, 20:09   #29
 
elite*gold: 0
Join Date: Mar 2006
Posts: 61
Received Thanks: 88
hmmm. try to add MyMath.coords if you bad added function coords into mymath.cs :P
glover is offline  
Old 02/02/2010, 00:29   #30
 
elite*gold: 0
Join Date: Apr 2006
Posts: 532
Received Thanks: 66
I tested SS in TG and only hit one scarecrow but to be honest I would rather only hit the one scarecrow compared to hitting four lol


WHITELIONX is offline  
Reply



« [Release]Dragon Spawning | Reworked RC5 Cipher (Unsafe) »

Similar Threads
[Request]Fixed FB/SS system
05/03/2011 - CO2 Private Server - 4 Replies
Most LOTF sources have this problem. If you jump and fb or ss in mid air the aim is off, if anyone can fix it on this source and upload it will get +thanks. http://www.elitepvpers.com/forum/attachments/co2-p server-discussions-questions/28202d1251773349-re-r elease-pazeco-v2-pazeco-v2.rar
Castle system Fixed DB
07/08/2008 - EO PServer Hosting - 7 Replies
Fixed all the castle problem ! just download the DB files and replace u old DBfiles ( close u sql before u replace it )
Mariokiller64's System bug fixed :)(Feb 24th)
03/02/2008 - GunZ - 1 Replies
What this system has. 1.Meds heal 23HP and AP. (lol 23 no one will notice :P) 2.World Items heal 50 HP and AP 3.You can swear. 4.Monsters do 0 damage and do no skills on you. 5.You do not need a non updating launcher BECAUSE the launcher does not detect any changes of the maps or system.mrs files :P. 6.Remember that no CRC injecting is needed.
[Release] FlyFF Termination (System Crashes Fixed!
09/28/2007 - Flyff - 11 Replies
At Locking please .



All times are GMT +2. The time now is 12:45.


Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.

BTC: 3KeUpz52VCbhmLwuwydqxu6U1xsgbT8YT5
ETH: 0xc6ec801B7563A4376751F33b0573308aDa611E05

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2019 elitepvpers All Rights Reserved.