|
You last visited: Today at 17:40
Advertisement
[Release] Super-Basic Server Base
Discussion on [Release] Super-Basic Server Base within the CO2 PServer Guides & Releases forum part of the CO2 Private Server category.
08/16/2011, 06:48
|
#76
|
elite*gold: 0
Join Date: Dec 2010
Posts: 341
Received Thanks: 255
|
I'm curious as to what people think of this source.
Any comments, questions, concerns?
|
|
|
08/16/2011, 09:06
|
#77
|
elite*gold: 12
Join Date: Jul 2011
Posts: 8,282
Received Thanks: 4,190
|
Quote:
Originally Posted by .Kinshi
I'm curious as to what people think of this source.
Any comments, questions, concerns?
|
I have a concern that your packet handler is less efficient than just using a switch. I talked to Hybrid about it too and he said the same thing. I would double check on if that's an appropriate method.
|
|
|
08/17/2011, 01:50
|
#78
|
elite*gold: 0
Join Date: Dec 2010
Posts: 341
Received Thanks: 255
|
Quote:
Originally Posted by Fаng
I have a concern that your packet handler is less efficient than just using a switch. I talked to Hybrid about it too and he said the same thing. I would double check on if that's an appropriate method.
|
Hmm, I had a discussion with Unknownone about it a long long time ago (I've been using this way for a long *** time :P) and he said it was a pretty efficient way to do it.
I might do some further testing.
|
|
|
08/17/2011, 07:14
|
#79
|
elite*gold: 12
Join Date: Jul 2011
Posts: 8,282
Received Thanks: 4,190
|
Quote:
Originally Posted by .Kinshi
Hmm, I had a discussion with Unknownone about it a long long time ago (I've been using this way for a long *** time :P) and he said it was a pretty efficient way to do it.
I might do some further testing.
|
Well, if you think about it, a switch statement would be much simpler. I can see where a dictionary would be more efficient if the switch contained more than 50 cases, but I can't see it being more efficient with less than 30. (Either way, it's just checking values- but a switch is simpler than a dictionary and possibly more efficient).
Definitely do some testing. As I said, it's just a concern. I'd be interested in which is faster. I'm too busy to work with anything anymore (co related).
|
|
|
08/17/2011, 07:31
|
#80
|
elite*gold: 0
Join Date: May 2011
Posts: 1,769
Received Thanks: 756
|
This is how you find the packet processor:
Code:
public TValue this[TKey key]
{
get
{
int index = this.FindEntry(key);
if (index >= 0)
{
return this.entries[index].value;
}
ThrowHelper.ThrowKeyNotFoundException();
return default(TValue);
}
set
{
this.Insert(key, value, false);
}
}
Code:
private int FindEntry(TKey key)
{
if (key == null)
{
ThrowHelper.ThrowArgumentNullException(ExceptionArgument.key);
}
if (this.buckets != null)
{
int num = this.comparer.GetHashCode(key) & 0x7fffffff;
for (int i = this.buckets[num % this.buckets.Length]; i >= 0; i = this.entries[i].next)
{
if ((this.entries[i].hashCode == num) && this.comparer.Equals(this.entries[i].key, key))
{
return i;
}
}
}
return -1;
}
Where a switch case will just take x from y.
Imagine 1000 entries in your dictionary.
What seems faster in your own opinion, looping through all the entries or taking x from y?
A switch case would be much faster IMO.
|
|
|
08/19/2011, 00:18
|
#81
|
elite*gold: 0
Join Date: Jun 2009
Posts: 787
Received Thanks: 314
|
Quote:
Originally Posted by BaussHacker
This is how you find the packet processor:
Where a switch case will just take x from y.
Imagine 1000 entries in your dictionary.
What seems faster in your own opinion, looping through all the entries or taking x from y?
A switch case would be much faster IMO.
|
That doesn't loop through all the entries in the dictionary.
It's a hashtable.
Most of the time it's a single lookup to find the entry, unless two entries have the same hash (mod the number of buckets) in which it then loops through to find the specific entry.
For 1000 entries it's likely to find it in one or very few tries (depending on the amount of "buckets" and the distribution of the hash algorithm).
|
|
|
08/19/2011, 17:04
|
#82
|
elite*gold: 0
Join Date: Sep 2008
Posts: 40
Received Thanks: 2
|
I got this problem,
I really want to learn C# so i thought about using this source, but i can't even run it XD
Quote:
Locating source for 'C:\Users\Tyler\Documents\Visual Studio 2010\Projects\KinSocket\KinSocket\Database\MySqlEn gine.cs'. Checksum: MD5 {55 76 a3 37 12 d7 84 65 c8 2 a9 9c 87 9f ce ae}
The file 'C:\Users\Tyler\Documents\Visual Studio 2010\Projects\KinSocket\KinSocket\Database\MySqlEn gine.cs' does not exist.
Looking in script documents for 'C:\Users\Tyler\Documents\Visual Studio 2010\Projects\KinSocket\KinSocket\Database\MySqlEn gine.cs'...
Looking in the projects for 'C:\Users\Tyler\Documents\Visual Studio 2010\Projects\KinSocket\KinSocket\Database\MySqlEn gine.cs'.
The file was not found in a project.
Looking in directory 'c:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\crt\src\'...
Looking in directory 'c:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\atlmfc\src\mfc\'...
Looking in directory 'c:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\atlmfc\src\atl\'...
Looking in directory 'c:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\atlmfc\include\'...
The debug source files settings for the active solution indicate that the debugger will not ask the user to find the file: C:\Users\Tyler\Documents\Visual Studio 2010\Projects\KinSocket\KinSocket\Database\MySqlEn gine.cs.
The debugger could not locate the source file 'C:\Users\Tyler\Documents\Visual Studio 2010\Projects\KinSocket\KinSocket\Database\MySqlEn gine.cs'
|
|
|
|
08/20/2011, 00:44
|
#83
|
elite*gold: 28
Join Date: Jun 2010
Posts: 2,225
Received Thanks: 868
|
Quote:
theres a space in the name.
|
|
|
08/21/2011, 20:14
|
#84
|
elite*gold: 0
Join Date: Dec 2010
Posts: 341
Received Thanks: 255
|
Quote:
Originally Posted by stefans94
I got this problem,
I really want to learn C# so i thought about using this source, but i can't even run it XD
|
Weird it looks like it's looking for the source of my KinSocket dll.
I don't know why it would be doing that :S
|
|
|
 |
|
Similar Threads
|
~[Verkaufe] 1x 10k Dinar & 3x 3Days-Base-Pass NUR 25e*g [Super-Sonderangebot]~
02/09/2011 - WarRock Trading - 16 Replies
http://i54.tinypic.com/ehnr5t.png
Hi,
Ich verkaufe:
//
//
//
|
Super Basic Multi
04/27/2010 - CO2 Exploits, Hacks & Tools - 1 Replies
My first attempt at this, it looks like they changed some of the features listed in TheBoyWhoLost's multiclient guide.
So this includes only multiclient with date and time.
If you want to bypass play.exe create a shortcut to Conquer.exe
Right click the shortcut and go to Properties.
Add the word blacknull after the Target address.
(Ex; "C:\Program Files\Conquer Online 2.0\Conquer.exe" Blacknull)
uhh enjoy? Hopefully this helps someone :P
If I can learn how to enable PM commands and...
|
CoV Super Group - Base Building
11/26/2005 - General Gaming Discussion - 0 Replies
Once you hit Level 10, you can go to the main building in Port Oakes to register for a Super Group (basically a Guild) which also entitles you to a Base.
I had some experience building a base in Beta, so lets start with basic layout. Your base to begin with will be only 1 room, the portal into it. As you enter you'll notice (with the correct permissions) that you can Edit or Upgrade your base. Editing allows the placement of new rooms, while Upgrading allows the purchase of overall terrain...
|
All times are GMT +1. The time now is 17:42.
|
|