Command to spawn in-game Player head?

I wrote a script to do it...

This is written in Python and works on vanilla minecraft (even snapshots)

I currently give players a purple_shulker_box the first time they are seen by the server

https://github.com/Veritas83/Minecraft.SNAPSHOT.Commands.Mod/blob/master/commands.by.YT_Veritas0923.py

Line 1150-1153

if freeshulkerbox == True:
    cmdin = "give " + player + " purple_shulker_box 1\n"
    print "[" + get24hrtime() + "] [Script thread/EXEC]: " + cmdin,
    p.stdin.write(cmdin)

Change to:

if freeshulkerbox == True:
    cmdin = "give " + player + " minecraft:skull 1 3 {SkullOwner:" + player + "}\n"
    print "[" + get24hrtime() + "] [Script thread/EXEC]: " + cmdin,
    p.stdin.write(cmdin)

I think this will accomplish what you are asking.

Update:

I just tested this, and it does indeed work. :)

enter image description here