Would it be straightforward to create a voxel based game with unreal4?
No, the engine doesn’t use voxels for anything. What are you trying to do?
Well you could actually make the engine use voxels if you use square textures for everything I guess.
Everything already uses square textures. Voxels != polygons
The engine does not support voxel terrain like Minecraft/etc… out of the box, but check out GitHub - AndrewScheidecker/BrickGame: A demo of Minecraft-style voxel rendering in UE4 for a voxel project built on top of a modified version of 4.1 (also linked to from that page, though you’ll have to be a subscriber to see the modified engine code. If you’re willing to dive in and get your hands dirty, Andrew released all of his code under a fairly permissive license.