It sounds like just a general issue with mental fortitude or how tenacious your positive attitude is.
Everyone tilts and everyone is effective by the stress and anxiety of performing poorly, while you can't completely overcome this factor there are things you can do to make it better on yourself.
One is just keep playing, building a consistency is important and practice is the only way to do it. Another is to do what @
NGUY (guitarstage) said and get lots of sleep. You don't realize how grumpy little sleep gets you until you have to do something that relies on your attention. Then when you start performing poorly because of it, you just start short-fusing. Sleep means more focus and just more patience in general.
Also always take online with a grain of salt. Smash 4 isn't super technical but what technical aspects it has are forfeit due to the buffered nature of online inputs. You just don't want to twist yourself up about losing online. It's good fun, but it isn't the be all end all time-to-prove-myself moment I think you think it is. Drop it off that pedestal, and you'll relax and have fun in no time.