Custom 3D printer printing dimensions has changed because of a .gcode file
Your printer is an Ultimaker clone or something else?  All of the original firmwares located on TinkerGnome's Github are configured for Ultimaker printers so if you are using them on something different you will need to configure it before using it.  The easiest option would be editing this print file that changed your settings to your desired settings and then reloading it.

How to find your actual Z? Well that's a bit difficult without more information.  I'm guessing from your description that your printer homes at Z max?  If it's homing at Z max you need to home the machine, jog the Z axis to where you want 0 to be (usually using a piece of paper between the nozzle and bed), then record the Z axis position and enter that as your travel limit in the firmware.  If your printer homes at Z min this could be as simple as changing the homing offset.