functional potentialDamage function, add init function to store tiles and hero, stop passing tiles and hero, reorganize helpers