Well to activate that code you can use any event, and just set quake to 1. If you want it to stop set it to 0. The thing is unless the shaking only happens while you are pressing a key, you'll have to use a draw actor event.
So, this will activate it.
player -> Key Down x -> Script Editor
- Code: Select all
quake=1;
And if you want it to stop after a while you can use a timer event that sets it back to 0.