Go haywire

To become damaged, to stop working properly.

At first, things were going well but later our plans began to go haywire.