Mhhh, I imagine that the rubik cube should get you into some pretty nasty rotation trouble! What first comes to my mind is when you click on the cube, you should identify which sub-cube gets the hit, then listen carefully for the direction that the mouse moves after that, when the mouse is still down. You should get a 2D vector from that. Maybe by comparing this vector to the orientation of the cube, you could determine which face of the cube is supposed to move. Once you know that you would need to identify which sub-cubes are relevant to this motion and rotate all of them about an axis, which should be cube.transform.forward or something. Anyway, I'm sure this should be complicated and this is what comes to my mind immediately, perhaps the real solution would be much less superficial.
Hope it helps anyway.
