Are you sure about Gamzee being the reason Terezi killed Vriska? He is the reason they had a confrontation, but by the end Terezi knew that Vriska was innocent of most of the murders and killed her specifically to prevent her from alerting Jack to the trolls' hideout.

But Terezi could have just knocked Vriska out (like she realized in the future and had John do) but she was blinded (hehe) by rage which was caused by Gamzee