I agree, you took a very good step in doing better for this! imo Realizing you do things for attention is one thing, realizing you're going about it in the wrong way is another thing, and working to correct it is still another step! I think those are the hardest steps. While you may find yourself being impatient when you "misstep" it really won't be so horrible IRL. Each time you do, and you will, if you can rethink it, reframe it, then that will help you limit the number of "blunders."
BTW