Someone
Thanks guys that was really helpful One last thing i need to know is were in he source i can find he way he client supposed to answer to each packet like the switch statement or anything of that kind that differentiate between each packet so i can know what to do in my bot Thanks again :)
Apokah's first answer was right , if you want to know how the client handles each packet , you gotta check the frames . as an instance , for the identification packets , look for something like identificationFrame.as on the sources .
You can also use 'find all' option wich is available on most code editors (sublim text like ?) and look for your desired packet .
Checking for these frames may not be always helpfull , it can be for coding the identification part of your bot but not for other functionalities like fighting or crafting ...
And as Apokah said again , you gotta take your time and sniff the client's comunications to reverse it on your bot .