When it happens sometimes, it looks like a bug, especially in an endless runner type of game. Can you de- and reactivate the object when it is off screen and reset it then? Otherwise use mechanim, and a set animation trigger action to return to a state you want. You can hook up the resting state to any state, and reset it that way.