How does packers work?(help)

I’ve been researching on how to make a protector( Crypter + Packer). I’ve found an interesting thread on Crypters but didn’t find anything fruitful while searching for packers.

I’m not interested in any 3rd party packers and crypters! I’m trying to build my own here. Any good reference would be nice.

The ultimate aim is to build my own botnet along with the Crypter and Packer. I saw a botnet bible here but its not free.

Any help on all three (botnet, crypter and packer) would be appreciated. I’m trying to learn how to make one!