Depending on your case there are some circumstances where you can be able to resolve your tourist visa overstay without having to leave the country and even be able to get a new visa. However, this is not guaranteed as it depends with the circumstances and eligibility.
The first option is applying for visa extension even with visa overstay. This is difficult considering that you have already the visa extension on the official portal will be blocked once you have overstayed. However, all is not done as you can visit the official Amer Center in Dubai in person.
Once you get there ensure that you clearly explain your situation and they may be able to manually submit your request to the immigration authorities for you to pay the fines and process the visa extension. This methos might be rejected and therefore you should be ready to revert to the initial process of exiting.
Ensure that you have marked your visa expiry date in your calendar and set multiple reminders before and on the actual expiring date so as to be aware of the expiry.
Always use the immigration portal to check your visa status online on weekly basis as the expiry approaches.
If you are planning to stay longer with the tourist visa ensure that you apply for the visa extension early enough to allow the processing and avoid any overstaying complexities and fines.
Ensure that you understand the visa you are holding. If you are having a 30 days tourist visa ensure that you are aware and when it becomes active and expiry and other details such as whether it can be extended or not.