Register for your free account! | Forgot your password?

You last visited: Today at 07:54

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

Advertisement



Explaining this error

Discussion on Explaining this error within the CO2 Private Server forum part of the Conquer Online 2 category.

Reply
 
Old   #1
 
elite*gold: 0
Join Date: May 2011
Posts: 84
Received Thanks: 2
Explaining this error

what does this error means, could anyone explain me what actually means?
thanks!


I want to add the bless effect, so when you upgrade your bless to -1 to show Aegis1 effect, -3 to show Aegis2 effect, -5 to show Aegis3 effect and -7 to show Aegis4 effect.

I do like this...
Code:
_String str = new _String(true);
                                                        str.TextsCount = 1;
                                                        str.Type = _String.Effect;
                                                        str.Texts.Add("Aegis4");
                                                        [COLOR="Red"][B]Entity.Owner.Screen.SendScreen(str, true);[/B][/COLOR]
But the problem is at the highlighted code...where the effect to be send, idk how to make it send to everyone, cause it gives me that error I posted above.
HerpDerpNigga is offline  
Old 10/13/2011, 23:16   #2
 
elite*gold: 21
Join Date: Jul 2005
Posts: 9,193
Received Thanks: 5,380
You need to reference an instance of an object...


Entity is what your actual class is called. You need to refer to the ACTUAL PERSON DOIGN THE UPGRADING.


for example... what does the method start with? Where is this? I assume somewhere in your npc use scripting?


Top should be something along the lines of...


public static void HandleNpc(Entity user, ushort npcID, byte linkBack)

However your source handles it... you want user instead of Entity (or however you handle it)


Non static objects ALWAYS need to have a specific object referred to before use. It's like saying "fill up 'car' with gas". It needs to know what car you're talking about... your car? all cars that have ever existed?.... WHAT?!


<Pointless rant>

And this is another reason why naming conventions are useful.... local variables shouldn't be starting with a cap... as far as I'm aware (I could be off base with a few of these...) naming conventions in general are...

Local variable: Start with lower case letter separating words with _ or using camel caps
Eg: int variableName;

Private variable: Start with an underscore and lower case letter. Separate words with _ or use camel caps
Eg: private int _variableName;

Public variables: Start with cap letter, separate words with _ or use camel caps
Eg: public int VariableName;

Constant variables: All letters capitalized. Separate words with _
Eg: public const int VARIABLE_NAME;


I'm sure I've missed some but those are the common naming conventions... being consistent helps make keeping track of things easier (IE: what entity am I referring to?... the one that was passed into this method, am I referring to some constant value?... etc)
pro4never is offline  
Reply


Similar Threads Similar Threads
Someone could help me explaining , How i can open 2 clients with DB-Bot
01/23/2011 - SRO Private Server - 13 Replies
Hello , I need to open 2 db bot clients , or 1 normal and 1 db bot , atleast 1 db bot client , could someone tell me how to do please?
hey guy's im caleb and im looking for some explaining/ help that's been drvingme nuts
01/17/2011 - Say Hello - 0 Replies
Hey guy's im new. and this place seem's ausome, lot's of nice hacks(: But my problem is how the hell do i use em lol im trying to use a hack on gunz but i really don't know what im doing can someone explain for me please and thank you Caleb Scarbrough.
[PK2]Video explaining how to make Sos, Som or Sosun
09/28/2009 - SRO Hacks, Bots, Cheats & Exploits - 31 Replies
Difficult: Hard YouTube - Silkroad Media.pk2 editing - How to make SoSun(Moon,Star)
[Hacks] Preview, Explaining
02/28/2009 - S4 League - 44 Replies
Hi @ all, ZeroTen and me gonna write some Hacks for you. I hope you will enjoy it and have more fun with the game. ZeroTen and me do hack serveral Games for fun and make people happy :D This is what we got so far: Hacks that already work: - Wallhack (not on every pc, have to fix it): YouTube - S4 League - Wallhack



All times are GMT +1. The time now is 07:56.


Powered by vBulletin®
Copyright ©2000 - 2026, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

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