Refactors rules functions to not loop unchanging spots