Let me get a more down to the issue at hand. Guns don't cause people to use them, nor do "mental health issues" inherently make you violent (and some of the more common ones such as depression or autism make you less likely to be violent, with depression however it can be slightly dangerous, still mostly to themselves, when you get better and potentially quite suddenly have motivation again), you still need a motive for it.
And how does conflict actually arise? Well, it might be conflict about things, scarcity leading to a clash over resources, of course that's an option - that's not exactly whats going on with mass shootings, is it? Well, not if you limit that lens to only material goods anyways.
So whats the type of conflict going on here? And it is very similar whether it is one of your so called "mental health issues" or political extremism by the way: Forced integration. If people felt they could just not interact with society and just do their own thing whatever that may be they wouldn't end up lashing out against it. And, yes, that does include protecting the right of paranoid schizophrenic to own firearms, what you want to actually act against them proving their delusions? And if you do, do you think that makes them like you less or more? And, no, you can simply not prevent violence by taking weapons away, anyone can sabotage infrastructure and get a much higher body count going than any of those mass shootings fairly easily.
You can do it like the UK and imprison people for 5 years merely for having legal books from amazon on knife fighting while having the "wrong ideas" which makes those legal books into "material useful for terrorists" - you think they'll be less dangerous to you, dislike you less, after those 5 years? No, but after 5 years your opposition may be in government and you can blame it on them if something does happen. That is how democracy works.
There is a reason why schools are such a common target - that is a place everyone is forced through. Other than the tax office probably THE symbol for forced integration instead of voluntary association and disassociation. Getting rid of public schools - and in the ideal case much more such as taxation, state police and so on but that wont happen any time soon, though maybe you could allow people to rescind their citizenship and leave at least if you wont allow them to secede with their property in your nation as you should, but you wont do that part but how about letting people leave? - will solve this issue. Get rid of public schools and i promise the amount of school shootings will drop significantly. Whereas with guns, no, in many cases there were already laws in place that if applied would've prevented them from getting firearms, it does not work.
If you just do not force people to interact with people they do not get along with, you will find this problem will subside.