resize script for AC