There is no "single" answer because different moves by the opponent have different drawbacks to them. Best I can do is recommend a way of thinking to get you on the right path to me more likely to take advantage of an opponent error, but nothing will work in every case.
The way to think about this is to think why the opponent's move (or strategy) looks bad. Does it push too many pawns? Does it neglect King safety? Does it ruin their pawn structure?
Once you think you've identified why their move is bad, then try to come up with a plan to exploit this. Sometimes these things can be punished immediately, sometimes it will take 20 moves of a positional grind and other times there will be no way to take advantage of their sub-optimal-looking play. However, thinking about it in this way will make it more likely you'll come up with an exploiting idea.
Not always, but usually, if they can have defect in their position then you want to to the opposite to exploit it. If they neglect piece development, then usually you want to keep developing your own pieces efficiently and force open the position (open positions typically favor the side with better piece development). If they cripple their own pawn structure, you might want to keep your pawns healthy and find ways to take advantage of their pawn structure or trade into a winning pawn endgame where their structure will have them suffering.
If you notice particular "bad" things you often recognize in opponent games, but have trouble exploiting, then you can seek advice about those specifically (in this thread or elsewhere).
Best of luck
at my elo ive seen alot of the players play dumb moves that do nothing or only hurt them, how do i train myself to exploit those advantages and win the game because i feel like thats whats keeping me from advancing, not being able to punish or exploit useless or meaningless moves