This is a concept I got from one of @ZubStudios projects. It isn't much, but it's how to create an action when the red flag is clicked, instead of stopping immediately.