Alright I really need some help, out of nowhere the engine wont turn over and Im getting all kinds of electrical problems.

The battery shows 12v
the grounds are good

When I try to turn the key on it doesnt do anything but when I try to turn the headlights on the ecu makes a bad grinding noise and smells like rotten eggs.