INCLUSION OF LOCAL STRUCTURE EFFECTS IN THEORETICAL X-RAY RESONANT SCATTERING AMPLITUDES USING AB INITIO X-RAY-ABSORPTION SPECTRA CALCULATIONS