Register for your free account! | Forgot your password?

Go Back   elitepvpers > MMORPGs > Conquer Online 2 > CO2 Private Server
You last visited: Today at 05:45

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

Advertisement



[HELP]Invalid Operation Exception.

Discussion on [HELP]Invalid Operation Exception. within the CO2 Private Server forum part of the Conquer Online 2 category.

Reply
 
Old   #1
 
elite*gold: 0
Join Date: Oct 2008
Posts: 430
Received Thanks: 176
[HELP]Invalid Operation Exception.

Well... Over the past little while, I have fixed quite a few issues regarding stability on the source I'm playing with, but have now found another that has left me stumped.

InvalidOperationException

It's taking effect under the section

Code:
public static void MobAttacksChar(SingleMob Mob, Character Attacked, byte AtkType, uint Dmg)
for the line

Code:
foreach (DictionaryEntry DE [COLOR="Red"]in[/COLOR] AllChars)
And it highlights the red writting, just "in" that's it.

I've spent a bit of time reading around about it, but really can't make sense of why it's even happening for me, so I can't even begin to try and figure out how to fix it.

If anyone has any idea's, a bit of input on the subject would be appreciated.
Incariuz is offline  
Old 12/02/2008, 22:18   #2
 
InfamousNoone's Avatar
 
elite*gold: 20
Join Date: Jan 2008
Posts: 2,012
Received Thanks: 2,885
Long story short, the hashtable was edited (something added/removed) while you were looping through it.
InfamousNoone is offline  
Old 12/02/2008, 22:23   #3
 
sherwin9's Avatar
 
elite*gold: 0
Join Date: Oct 2006
Posts: 222
Received Thanks: 27
Just ignore it, it's not threathning your server isn't it?
sherwin9 is offline  
Old 12/02/2008, 22:54   #4


 
Korvacs's Avatar
 
elite*gold: 20
Join Date: Mar 2006
Posts: 6,126
Received Thanks: 2,518
Quote:
Originally Posted by sherwin9 View Post
Just ignore it, it's not threathning your server isn't it?
....lol? it might only get 10 entrys into the hashtable in which case it means that the check is only performed on some of the clients and not others, how can you say thats not threatening a server?
Korvacs is offline  
Old 12/02/2008, 23:00   #5
 
elite*gold: 0
Join Date: Oct 2008
Posts: 430
Received Thanks: 176
Well infamous, I read something about possible issues a nullreferenceexception could cause in regards to that, or something along those lines, please ignore if I made no sense with that. only thing I can determine under such a circumstance would be this line.

Code:
if (Attacked != null && Charr != null)
I added that in due to an old crash issue I was having in that exact same section. I have actually editted a few other sectins with similar too. My server stability has went up durastically since then, but now this issue has arisen. Could that possibly be the cause of it?

@sherwin.

Yes, it can be an issue. Sure it doesn't occur with less then 25 people on my server, or more then once within a 24 hour period, but it's still a stability issue. And with my learning on building a private server, I would like to know what types of things cause issues, and how to avoid or correct them. Right now I'm using a source I did not build, for the sole reason I would fail miserably from scratch, therefor I need some hands on practise.
Incariuz is offline  
Old 12/02/2008, 23:02   #6
 
InfamousNoone's Avatar
 
elite*gold: 20
Join Date: Jan 2008
Posts: 2,012
Received Thanks: 2,885
Quote:
Originally Posted by sherwin9 View Post
Just ignore it, it's not threathning your server isn't it?
Any error threatens your server (:

Quote:
Originally Posted by Incariuz View Post
Well infamous, I read something about possible issues a nullreferenceexception could cause in regards to that, or something along those lines, please ignore if I made no sense with that. only thing I can determine under such a circumstance would be this line.

Code:
if (Attacked != null && Charr != null)
I added that in due to an old crash issue I was having in that exact same section. I have actually editted a few other sectins with similar too. My server stability has went up durastically since then, but now this issue has arisen. Could that possibly be the cause of it?

@sherwin.

Yes, it can be an issue. Sure it doesn't occur with less then 25 people on my server, or more then once within a 24 hour period, but it's still a stability issue. And with my learning on building a private server, I would like to know what types of things cause issues, and how to avoid or correct them. Right now I'm using a source I did not build, for the sole reason I would fail miserably from scratch, therefor I need some hands on practise.
Nah, one thread was mostlikely adding or removing a client, and another one trying to loop between it, google and learn about thread synchronization, it was one of the first things I looked into implementing when I started ACO.
InfamousNoone is offline  
Thanks
1 User
Old 12/02/2008, 23:07   #7
 
elite*gold: 0
Join Date: Oct 2008
Posts: 430
Received Thanks: 176
Ok, I'll do a bit of research on that then. I may still pop back to ask a few questions depending, but I'll try only to do so as a last resort. Thanks for the info.
Incariuz is offline  
Old 12/03/2008, 08:45   #8
 
elite*gold: 0
Join Date: Dec 2007
Posts: 618
Received Thanks: 213
does "lock statements" work in this case?
alexbigfoot is offline  
Old 12/03/2008, 13:47   #9
 
InfamousNoone's Avatar
 
elite*gold: 20
Join Date: Jan 2008
Posts: 2,012
Received Thanks: 2,885
Quote:
Originally Posted by alexbigfoot View Post
does "lock statements" work in this case?
Only if you used properly. Though lock could be a performance killer on a multi-threaded server.
InfamousNoone is offline  
Old 12/03/2008, 15:22   #10
 
elite*gold: 0
Join Date: Oct 2008
Posts: 430
Received Thanks: 176
That's what I was thinking while reading about it. Sure, it would stop interuption, but on the same note, it could slow down the amount of information being transferred which could cause issues, depending on the information.
Incariuz is offline  
Old 12/03/2008, 15:58   #11
 
elite*gold: 0
Join Date: Dec 2007
Posts: 618
Received Thanks: 213
then how could this problem be stopped? because this problem is killing my server :|
alexbigfoot is offline  
Old 12/03/2008, 17:43   #12
 
elite*gold: 0
Join Date: Oct 2008
Posts: 430
Received Thanks: 176
To be honest, I don't know. Everything I'm searching about the multi thread synchronization is leading me to using the lock method.

I'm going to go over this more later...



make sure I understand it fully before attempting to make changes. If it ends up working out good for me, I'll let you know. Prob won't try till 2morow evening though, have some running around to do, so can't put enough time into reading and testing right now.
Incariuz is offline  
Old 12/03/2008, 17:59   #13


 
Korvacs's Avatar
 
elite*gold: 20
Join Date: Mar 2006
Posts: 6,126
Received Thanks: 2,518
Why do you have more than 1 thread accessing the hash at anyone time anyways?
Korvacs is offline  
Old 12/03/2008, 18:48   #14
 
elite*gold: 0
Join Date: Dec 2007
Posts: 618
Received Thanks: 213
Quote:
Originally Posted by Korvacs View Post
Why do you have more than 1 thread accessing the hash at anyone time anyways?
lol?, u want to say, if only 1 thread is accessing the hashtable, it will never give the error?
alexbigfoot is offline  
Old 12/03/2008, 21:41   #15
 
InfamousNoone's Avatar
 
elite*gold: 20
Join Date: Jan 2008
Posts: 2,012
Received Thanks: 2,885
Quote:
Originally Posted by alexbigfoot View Post
lol?, u want to say, if only 1 thread is accessing the hashtable, it will never give the error?
Yes, but... well; I'll let you figure out my but on your own.
InfamousNoone is offline  
Reply


Similar Threads Similar Threads
K2 Exception
01/15/2010 - Heroes of Newerth - 0 Replies
How can i solve that error? Help me pls
OllyDbg exception help
12/30/2009 - Mabinogi - 1 Replies
When I open a file (any file) with OllyDbg I get this error : Privileged instruction - use Shift+F7/F8/F9 to pass exception to program This is the first time I get the error, I'm using a Windows XP for the editting and it's working fine until today. The error is not fixed when I use Shift+F7/F8/F9. Help?
invalid walk and invalid jump
03/04/2009 - Conquer Online 2 - 10 Replies
I think I found something important for speedhack makers I found that invalid walk and invalid jump messages happens when you have high ping(over 5k) and I think that all TQ done to stop speedhackers is they only added new kind of client check which reads your last position from the server and your new position and then compare them with the time cuz you can jump like 1 pixel in eac .5 sec(not sure) I think of this because : 1- this is the only possible check they can add they can't add...
dc all and exception to some players
01/11/2008 - Conquer Online 2 - 3 Replies
i knw it was possible before when coplus was working but im wondering f any1 can make a dc standalone and with an exception to some player just by inputting the names f any1 can make it that be great :P



All times are GMT +1. The time now is 05:45.


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.