First off, you need to stop shooting indoor flash in Aperture Priority Automatic mode...flash needs to be shot in manual mode to make it easier and more consistent, frame to frame, and across parts of an assignment. In Aperture Priority mode, the f/stop choice is critical, and f/13 is a poor choice for this scenario, causing both a high ISO and a slow shutter speed being required to get "the right exposure". The ISO level of 8,000 is just killing the quality. It looks like flash is about 35 to 40 percent of the exposure and ambient light is the majority of the exposure. This is not a winning combination.
A lower ISO level, like ISO 1,000 or so, and a larger aperture, like say f/8, would have helped, with the flash firing with a pretty intense, close to full-power discharge, with the camera set to fully manual mode, would have given really nice exposures and good results. It's simple: Aperture Priority and flash do NOT mix until you are fully, 100% familiar with what that actually means.
Flash shooting is one of the few types of shooting where 100% manual control over the camera's three exposure parameters, (ISO, f/stop,shutter speed) makes getting the best results EASIER than using aperture priority auto. Aperture Priority Auto is fine in daylight, but when flash is added, then there are actually TWO exposures that are being made, and the camera in this case greatly favored the ambient light, with the ISO 8,000 setting being just disastrous. Automatic flash photography in Aperture Priority mode with many cameras will create a positively huuuuuuuuuuuuge range of weird exposure values, far outside the normal range one might expect, and many,many times the settings in A.P. or Programmed Auto flash are just awful, with shutter speeds than can run from 1/250 down to 1/10 second.