Crypto Punks

cryptopunks - mint your own 24×24 pixel punk images off chain from the True Official Genuine CryptoPunks™ sha256-verified original 10 000 unique character collection; incl. 2x/4x/8x zoom for bigger sizes

New to Crypto Punks? See the Awesome CryptoPunks Bubble (Anno 2021) - Modern 24×24 Pixel Crypto Art on the Blockchain »

Command Line

Use the punk (or cryptopunk) command line tool. Try:

$ punk -h

resulting in:

NAME
    punk - punk (or cryptopunk) command line tool

SYNOPSIS
    punk [global options] command [command options] [arguments...]

VERSION
    2.1.0

GLOBAL OPTIONS
    -d, --dir,
    -o, --out, --outdir=DIR - Output directory (default: .)
    -f, --file=FILE         - True Official Genuine CryptoPunks

Generate Command

Generate punk characters from text attributes (from scratch / zero) via builtin punk spritesheet

Let's try punk #0:

$ punk generate female_2 earring blonde_bob green_eye_shadow

resulting in:

Let's try the -z/--zoom factor 2x, 4x, 8x, etc.:

$ punk --zoom 4 generate female_2 earring blonde_bob green_eye_shadow
# -or-
$ punk -z2 g female_2 earring blonde_bob green_eye_shadow

resulting in:

2x 4x 8x

Let's try never-before-seen super-rare punks:

$ punk generate demon heart_shades
$ punk generate vampire_female wild_hair

resulting in:

Q: What punk archetypes and attributes can I use?

A: See the list command.

List Command

List all punk archetype and attribute names from builtin punk spritesheet

Let's try:

$ punk list
# -or-
$ punk ls

resulting in:

==> Archetypes
  Male 1 / (m)                   - Archetype - Human
  Male 2 / (m)                   - Archetype - Human
  Male 3 / (m)                   - Archetype - Human
  Male 4 / (m)                   - Archetype - Human
  Female 1 / (f)                 - Archetype - Human
  Female 2 / (f)                 - Archetype - Human
  Female 3 / (f)                 - Archetype - Human
  Female 4 / (f)                 - Archetype - Human
  Zombie / (m)                   - Archetype - Zombie
  Zombie Female / (f)            - Archetype - Zombie
  Ape / (m)                      - Archetype - Ape
  Ape Female / (f)               - Archetype - Ape
  Alien / (m)                    - Archetype - Alien
  Alien Female / (f)             - Archetype - Alien
  Demon / (m)                    - Archetype - Demon
  Demon Female / (f)             - Archetype - Demon
  Mummy / (m)                    - Archetype - Mummy
  Mummy Female / (f)             - Archetype - Mummy
  Orc / (m)                      - Archetype - Orc
  Orc Female / (f)               - Archetype - Orc
  Robot / (m)                    - Archetype - Robot
  Robot Female / (f)             - Archetype - Robot
  Skeleton / (m)                 - Archetype - Skeleton
  Skeleton Female / (f)          - Archetype - Skeleton
  Vampire / (m)                  - Archetype - Vampire
  Vampire Female / (f)           - Archetype - Vampire
  Zombie (Ape) / (m)             - Archetype - Zombie
  Alien (Ape) / (m)              - Archetype - Alien
  Alien 0

See the punks.spritesheet for more.

Query Command

Query (builtin off-chain) punk contract for punk text attributes by IDs - use 0 to 9999

Let's try punk #0:

$ punk query 0
# -or-
$ punk q 0

resulting in:

==> (1/1) punk #0...
  female_2  earring  blonde_bob  green_eye_shadow

Let's try some top sellers:

$ punk query 7804 3100 5217 8857
# -or-
$ punk q 7804 3100 5217 8857

resulting in:

==> (1/4) punk #7804...
  alien  cap_forward  pipe  small_shades
==> (2/4) punk #3100...
  alien  headband
==> (3/4) punk #5217...
  ape  gold_chain  knitted_cap
==> (4/4) punk #8857...
  zombie  wild_hair  3d_glasses

Note: Yes, you can pass the text attributes to the generate command to get a free "cleanroom" copy built from scratch / zero that you own 100% forever.

Tile Command

Get punk characters via image tiles from all-in-one punk series composite (./punks.png) - for IDs use 0 to 9999

Step 0 - Download the True Official Genuine CryptoPunks™ composite image

One time / first time only - Download the True Official Genuine CryptoPunks™ composite housing all 10 000 CryptoPunks in a single 2400×2400 image (~830 kb) for free. See punks.png »

Now let's give it a try. Let's save punk #0, #2890, and #8219:

$ punk tile 0 2890 8219

printing:

==> reading >./punks.png<...
     >ac39af4793119ee46bbff351d8cb6b5f23da60222126add4268e261199a2921b< SHA256 hash matching
         

And voila!

Bonus: Try the -z/--zoom factor 2x, 4x, 8x, etc.

Let's give it a try. Let's save punk #0, #2890, and #8219 in 2x format:

$ punk --zoom 2 tile 0 2890 8219
# -or-
$ punk -z2 t 0 2890 8219

printing:

==> reading >./punks.png<...
     >ac39af4793119ee46bbff351d8cb6b5f23da60222126add4268e261199a2921b< SHA256 hash matching
         

And voila!

And x4:

And x8:

And so on.

10 000 More Punks - Unauthorized? No Way?!- Fuck the Establishment - Yes, You Can - Do-It-Yourself - Use Your Own Collections

Use the -f, --file=FILE option to pass along any unauthorized edition. Only make sure all punks are lined-up left-to-right, top-to-bottom in the 24x24 pixel format in the composite image.

Let's try the 10 000 More Punks series housing punks in packs of a hundred each. Let's have a looksie at the first 100 in the series.

Let's save punk #0, #19, #50, and #89 and let's add an offset of 10000 (to start counting at 10000 instead of 0):

$ punk --file ./more-punks-1.png --offset 10000 tile 0 18 40 88

printing:

==> reading >./more-punks-1.png<...
     240x240 (height x width)
==> (1/4) saving punk #10000 to >./punk-10000.png<...
==> (2/4) saving punk #10018 to >./punk-10018.png<...
==> (3/4) saving punk #10040 to >./punk-10040.png<...
==> (4/4) saving punk #10040 to >./punk-10088.png<...

And voila!

And 4x:

Let's try the second pack - that is, punks 100 to 199 in the series.

Let's save punk #0, #79, #80, and #90 and let's add an offset of 10100 (to start counting at 10000 plus 100 instead of 0):

$ punk --file ./more-punks-2.png --offset 10100 tile 0 79 80 90

printing:

==> reading >./more-punks-2.png<...
     240x240 (height x width)
==> (1/4) saving punk #10100 to >./punk-10100.png<...
==> (2/4) saving punk #10179 to >./punk-10179.png<...
==> (3/4) saving punk #10180 to >./punk-10180.png<...
==> (4/4) saving punk #10190 to >./punk-10190.png<...

And voila! Super rare - world's first female alien and much more.

And 4x:

And so on.

Flip Command

Flip (vertically) all punk characters in all-in-one punk series composite (./punks.png)

Let's generate an all new punk series by turning all punks in the classic series from right-looking to left-looking by flipping vertically "one-by-one by hand [thanks to philip the intern]" all punks. Phree the phunks! Let's give it a try:

$ punk flip
#  - same as -
$ punk --file ./punks.png flip

printing:

==> reading >./punks.png<...
     >ac39af4793119ee46bbff351d8cb6b5f23da60222126add4268e261199a2921b< SHA256 hash matching
         

And voila!

Yes, you can use any 24x24 composite. Use the --file option. Example - let's flip the 1000 More Punks collection:

$ punk --file ./morepunks.png flip

And so on.

Shuffle Command

Shuffle all punk characters (randomly) in all-in-one punk series composite (./punks.png)

Let's generate an all new punks series by randomly shuffling "one-by-one by hand [thanks to philip the intern]". Let's give it a try:

$ punk shuffle
#  - same as -
$ punk --file ./punks.png --seed 4142 shuffle

printing:

==> reading >./punks.png<...
     >ac39af4793119ee46bbff351d8cb6b5f23da60222126add4268e261199a2921b< SHA256 hash matching
         

And voila!

Note: The shuffle command also prints out all new index numbers for easy reference (to reuse attributes and so on):

All 10000 index numbers (zero-based) for reference using seed 4142:

[1369,  590, 1635, 3199, 1887, 7719, 5747, 2146, 6671, 7144,
 1428, 7817, 1219,  163, 7186, 8488, 7191, 5240, 7226, 6574,
 1619, 1701, 3018, 4745, 2438, 6474, 4756, 9300, 9382, 9528,
  102, 1847, 2848, 8369, 7825,  842,   66, 1035, 2934, 2442,
  ...
 8789, 7299, 4403, 5972,  338, 5635, 7566,  828, 8987, 9777]

Yes, you can use any 24x24 composite. Use the --file option. Example - let's flip the 1000 More Punks collection:

$ punk --file ./morepunks.png shuffle

And so on.

Usage in Your Scripts

Yes, you can generate punks in your own scripts and much more. See the Programming CryptoPunks & Copypastas Step-by-Step Booklet / Guide »

Install

Just install the gem:

$ gem install cryptopunks

License

The scripts are dedicated to the public domain. Use it as you please with no restrictions whatsoever.

Questions? Comments?

Post them on the CryptoPunksDev reddit. Thanks.