if its going lumpy and sounds like a boxewr engine it sounds like 1 or more cyclinders isn't working, either a missfire, could be a spark issue, or it could be a fuelling issue; maybe a blocked injector.
but it needs the code pulling.
also as said above, light on means need checking but not critical. flashing means you should pull over as soon as possible to avoid engine damage.
personally i wouldn't be taking that car anywhere other than to the garage.