|
You last visited: Today at 05:14
Advertisement
[Small Tutorial] Packets in Conquer Online
Discussion on [Small Tutorial] Packets in Conquer Online within the CO2 PServer Guides & Releases forum part of the CO2 Private Server category.
01/08/2012, 19:23
|
#1
|
elite*gold: 12
Join Date: Jul 2011
Posts: 8,282
Received Thanks: 4,191
|
[Small Tutorial] Packets in Conquer Online
Replaced with
|
|
|
01/08/2012, 20:19
|
#2
|
elite*gold: 0
Join Date: Nov 2009
Posts: 342
Received Thanks: 17
|
Great Mr.Fang
|
|
|
01/09/2012, 00:35
|
#3
|
elite*gold: 0
Join Date: Feb 2011
Posts: 335
Received Thanks: 170
|
Quote:
Originally Posted by Y u k i
A ushort is equal to two bytes. It holds a value between 0 and 65,535 (65536 in total)
|
Actually he phrased that wrong. It holds a value between -1 and 65536.
Saying it holds a value between 0 and 65,535 is saying that it can be valued as 1-65534.
|
|
|
01/09/2012, 01:04
|
#4
|
elite*gold: 12
Join Date: Jul 2011
Posts: 8,282
Received Thanks: 4,191
|
Quote:
Originally Posted by Arco.
Actually he phrased that wrong. It holds a value between -1 and 65536.
Saying it holds a value between 0 and 65,535 is saying that it can be valued as 1-65534.
|
Depends on the context. You wouldn't say "pick a number between 1 and 10" to mean 2-9.
In addition to that, I stated the total amount of values (which eliminates that confusion) so there's nothing wrong about the context that I'm using it in.
|
|
|
01/09/2012, 02:47
|
#5
|
elite*gold: 0
Join Date: May 2005
Posts: 1,892
Received Thanks: 920
|
In the context of this post, saying "between" implies non-inclusivity.
|
|
|
01/09/2012, 03:55
|
#6
|
elite*gold: 0
Join Date: Feb 2011
Posts: 335
Received Thanks: 170
|
Quote:
Originally Posted by Fаng
Depends on the context. You wouldn't say "pick a number between 1 and 10" to mean 2-9.
In addition to that, I stated the total amount of values (which eliminates that confusion) so there's nothing wrong about the context that I'm using it in.
|
Yes, I would. That's grammar at its finest. And that doesn't eliminate any confusion, it's wrong based on your previous statement, because there would be 65533 in total.
|
|
|
01/09/2012, 04:05
|
#7
|
elite*gold: 0
Join Date: May 2005
Posts: 1,892
Received Thanks: 920
|
Quote:
Originally Posted by Fаng
You wouldn't say "pick a number between 1 and 10" to mean 2-9.
|
@Arco - I would as well.
@Fang - You're supposed to say "pick a number from 1 to 10", not between, because that'd mean from 2 to 9. Who says between?
|
|
|
01/09/2012, 05:11
|
#8
|
elite*gold: 0
Join Date: Feb 2011
Posts: 335
Received Thanks: 170
|
Quote:
Originally Posted by Fаng
A byte holds an integer between 0 and 255 (256 total). In C++, it's called an Int8.
|
No. After discussing this with Evan, we both agree you are wrong. A byte in C++ is a uchar. And another part where you're wrong, UInt8 would be the correct typecast for it.
|
|
|
01/09/2012, 06:04
|
#9
|
elite*gold: 0
Join Date: Jan 2008
Posts: 1,443
Received Thanks: 1,175
|
Quote:
Originally Posted by Arco.
No. After discussing this with Evan, we both agree you are wrong. A byte in C++ is a uchar. And another part where you're wrong, UInt8 would be the correct typecast for it.
|
True. The 'Byte' in C# is the equivalent of the 'unsigned char' if we consider that a char is implemented as a 8 bits integer.
Anyway, a byte is an integer of any size. Some implementations say that a byte is an integer of 9 bits, some others say that it's 7 bits. To avoid confusion, the C99/POSIX standard implemented the (u)intN_t definitions where it's an (un)signed N bits integer. It's not true to say that a byte is a UInt8. As we shouldn't say that an ushort is a UInt16 as a short is suppose to be at least 16 bits. When defining structure, you should use type name based on the number of bits. And you shouldn't say the number of bytes of a file, but the number of octets as an octets is defined as an 8 bits integer. You should avoid using keywords as short/int/word/byte/etc because they are all dependent of the implementation. They aren't fixed-size integer as the C99/POSIX standard.
So, to be compliant to any language, any implementation.
(U)IntN is the solution
Oh, and to give a good definition for the range of a N bits integer.
Signed: [-2^(N-1), 2^(N-1) - 1]
Unsigned: [0, 2^N - 1]
|
|
|
01/09/2012, 06:20
|
#10
|
elite*gold: 12
Join Date: Jul 2011
Posts: 8,282
Received Thanks: 4,191
|
I guess it would be unprofessional to say "shut the **** up everyone", but nobody here has a valid point that adds to this thread (except for CptSky, thank you so much for that input - it's exactly the kind of criticism that I need). Arco, you need to cut this out dude. It's not appropriate and this "competition" that you feel between us needs to stop. There is no competition between us. I wrote this thread to get proper, professional criticism, not for some 15 year old kid to grammar correct me.
I will make changes to the thread above.
Good day everyone.
|
|
|
01/09/2012, 06:59
|
#11
|
elite*gold: 0
Join Date: May 2005
Posts: 1,892
Received Thanks: 920
|
Quote:
Originally Posted by Fаng
I guess it would be unprofessional to say "shut the **** up everyone", but nobody here has a valid point that adds to this thread (except for CptSky, thank you so much for that input - it's exactly the kind of criticism that I need). Arco, you need to cut this out dude. It's not appropriate and this "competition" that you feel between us needs to stop. There is no competition between us. I wrote this thread to get proper, professional criticism, not for some 15 year old kid to grammar correct me.
I will make changes to the thread above.
Good day everyone.
|
We all had valid points that added to this thread, as evidenced by the changes to the original post. Anyway, continue on.
|
|
|
01/09/2012, 07:24
|
#12
|
elite*gold: 0
Join Date: Dec 2011
Posts: 1,537
Received Thanks: 785
|
Quote:
|
Originally Posted by Korvacs
If you don't know what your talking about, then stop talking.
|
.
|
|
|
01/09/2012, 07:37
|
#13
|
elite*gold: 12
Join Date: Jul 2011
Posts: 8,282
Received Thanks: 4,191
|
Quote:
Originally Posted by I don't have a username
.
|
Sorry, but if you have a better explanation then by all means go for it.
|
|
|
01/09/2012, 07:57
|
#14
|
elite*gold: 0
Join Date: Feb 2011
Posts: 335
Received Thanks: 170
|
Quote:
Originally Posted by Fаng
Sorry, but if you have a better explanation then by all means go for it.
|
He's referring to you trying to reference C++.
|
|
|
01/09/2012, 08:33
|
#15
|
elite*gold: 0
Join Date: Dec 2011
Posts: 1,537
Received Thanks: 785
|
Quote:
Originally Posted by Arco.
He's referring to you trying to reference C++.
|
That ^
Obviously it wouldn't be Int8 as you can't send signed integers in a packet. Well not true there is a way you can, you could do something like:
Code:
bool negative
signed integer
However it's not a real way to do it, but it's equal to the way negative values are stored in your machine.
|
|
|
Similar Threads
|
conquer online private server tutorial?
09/23/2010 - CO2 Private Server - 3 Replies
i need a guide on how to make a private server with working links to the downloads ive been looking for a guide for 3 days and tried so many and just wasted my time please give me a good guide that has working links
|
Conquer Packets
03/02/2007 - CO2 Exploits, Hacks & Tools - 143 Replies
ok, i hope this helps, using chocoman4k COPAC (AWESOME DUDE), u'll need to reach invalide coordinates to know your new coordinates or d/c an conn again, use another client to see u moving, i couldnt test it on guild gate cause my char is a poor noob and it would get killed before it gets the door. Couldnt figure out jumping packet, something weird about wrong msg with first packer recv and second one says invalid jump but still no jumping
sit down
1C 00 F2 03 92 45 11 00 C6 57 12 00 4B 01...
|
All times are GMT +1. The time now is 05:14.
|
|