• Welcome to Valhalla Legends Archive.
 

[C -> S] 0x51

Started by Trunning, May 07, 2010, 10:24 PM

Previous topic - Next topic
|

Trunning

Well a DWORD is 4 bytes, and there is 6 bytes of cd, so I'm unsure.

Hdx

Look at more then just the 0xCD's

Proud host of the JBLS server www.JBLS.org.
JBLS.org Status:
JBLS/BNLS Server Status

Trunning

Fd? That's leading me to believe a DWORD then a WORD, but I need 2 DWORDS...

Hdx

Read the packet like the server would read it.

Proud host of the JBLS server www.JBLS.org.
JBLS.org Status:
JBLS/BNLS Server Status

Trunning

Yeah I don't know where you're going now.

Hdx

Heres an example. I have a packet with the following format:
(BYTE) A
(WORD) B
(DWORD) C
(String) D

And the following is what it looks like in memory (or sending over the wire):

01 02 03 04 05 06 07 61 62 63 64 65 00
.  .  .  .  .  .  .  a  b  c  d  e  .
 
If I were to read it manually I would get:
A = 0x01
B = 0x0302
C = 0x07060504
D = abcde

See what I get at?

Proud host of the JBLS server www.JBLS.org.
JBLS.org Status:
JBLS/BNLS Server Status

Trunning


Hdx

You said you knew how memory was laid out.
Why do you lie?
Why do you not try to understand things?
Read my post over and over until you realize what I did yo decode ABCD from the packet.
This is a skill is is REQUIRED for network programming.
And it's simple if you just try.

Proud host of the JBLS server www.JBLS.org.
JBLS.org Status:
JBLS/BNLS Server Status

Trunning

Like you said before you don't explain things well, and I do understand how memory is laid out. Don't assume things...

Hdx

Ok, How is a DWORD laid out in memory? Give me an example.

Proud host of the JBLS server www.JBLS.org.
JBLS.org Status:
JBLS/BNLS Server Status

l)ragon

Relax lol, like HDX said you need to go over what you have there. set up some break points again and stick your buffer array in watch, see where its getting that mangled up shit data from.
*^~·.,¸¸,.·´¯`·.,¸¸,.-·~^*ˆ¨¯¯¨ˆ*^~·.,l)ragon,.-·~^*ˆ¨¯¯¨ˆ*^~·.,¸¸,.·´¯`·.,¸¸,.-·~^*

Hdx

Its Hdx not HDX it's annoying when you do that.
Anyways, it's more important that he knows how to read data as opposed to getting this one packet fixed right now.
I've fixed every single packet hes worked with so far. And he hasn't learned anything yet. So I am going to walk him through the basics.

Proud host of the JBLS server www.JBLS.org.
JBLS.org Status:
JBLS/BNLS Server Status

Trunning

Ok fine you got me, I understand certain parts of memory, not everything. And I've learned a few things from the 15 pages of my 3 topics.

Do you have some specific reading on memory then?

Trunning

You just going to sit there a laugh at me, or going to give me some reading to do?

rabbit

Forums aren't IM services.  Just because Hdx has responded quickly so far doesn't mean he will every time you post.  In fact, you're pretty lucky he's responded.  Most people here aren't as helpful with newbies, and many threads won't get a reply for a day or more.  Chill out.  Use Google like most people here would have to you to do in the first place.  Everyone here learned BNCS/BNLS pretty much on their own, with less help than you're getting.
Grif: Yeah, and the people in the red states are mad because the people in the blue states are mean to them and want them to pay money for roads and schools instead of cool things like NASCAR and shotguns.  Also, there's something about ketchup in there.

|