You'll need to have the Android SDK installed, particularly the fastboot
tool. (You probably have this already if you've rooted your phone.)
Go to Google's factory images page, find the section called "mysid" near the bottom, and download the 4.0.4 file.
Turn your phone off, then hold both the Volume Up and Down buttons, and press and hold the Power button. You should see the phone's bootloader screen, which looks like a green droid with its front panel open, and an arrow at the top that says Start. Don't press any buttons here, but plug in your USB cable.
Extract the factory image file that you downloaded. Inside, you should find a file called image-mysid-imm76k.zip
. Open a command prompt, cd
to the folder with that file, and run fastboot -w update image-mysid-imm76k.zip
. That'll reflash the phone's factory software image, which should put it back to normal. (You'll be running ICS at this point, but you can do the Jelly Bean OTA upgrade afterward if it's available to you.)
This may wipe all your phone's data — including the "SD card" internal memory — so make a backup of anything important first.
If your AOKP "has no way of installing apps", it sounds like when you installed it, you forgot to install the "gapps" add-on, which includes the Play app as well as other Google apps like Gmail. But the other problems you described shouldn't happen — I've put AOKP on my Galaxy Nexus and it works fine. If you still have problems after flashing the factory image, you'll need to provide more detailed information about what's happening.