I was having a problem where my magsafe charger would stop charging after I started the car. I would have to unplug it and plug it back in to get it to work which was really annoying. Doing some research I discovered that the magsafe has a safety feature that trips it if it's getting a bad power source. I surmised that the voltage drop when my car starts must be tripping the magsafe charger off. The solution I found was to use a battery pack that can output to the USB C while also charging itself through another port. Since doing this I haven't had a problem and I have the added benefit of having a portable battery bank ready to go if I need it. I've included a link to the one that I bought. It charges itself through micro USB while simultaneously powering the magsafe through USB C. Hope this helps someone.
USB C Power Bank, 26800mAh Portable Charger USB C, Charmast Slim Thin 3A High-Speed Battery Pack Type C with 3 Input & 4 Output Compatible with MacBook, iPhone, Samsung, Pixel More https://www.amazon.com/dp/B07P5ZP943/ref=cm_sw_r_cp_api_glt_fabc_21RWZY0ZYBFMY0V5J957?_encoding=UTF8&psc=1