Blender accessories dont follow mesh properly

I’ve rigged my character with automatic weights, but the character’s coat is glitched when I move certain bones. It has a bunch of buttons on it that were previously disconnected from the coat but were later joined. However, all though they are joined, when moving certain bones they start to deform and move, detatching from the coat as if they were seperate objects.

Does anyone know how to fix this?

Automatic weights will sometimes cause bones to influence the wrong parts of an object, especially if those parts are detached.

The easiest solution for buttons is to make each button a separate object, remove the armature modifier on them and use 3 vertices parent instead.

You select the button first, then the coat. You go into edit mode, select 3 vertices of the face closest to the button and then parent with ctrl+p. The button will now be parented to a single triangle of the coat.