I would go with the Moto X. The S4 is great but the Moto X is made by google and has a lot of extras the S4 dose not.
I too just bought the moto x. Cant wait to get it

Well, not an iphone.
Spec vs spec, the S4 is beefier. Though Motorolas are pretty tough, and I prefer the smaller screen. Then again, it cannot take a microSd card - a feature that is amazingly stupid, yet becoming more common.
I vote S4. Samsung make some pretty nice devices. I just bought a Note 2 to finally replace my Galaxy Nexus.