moved getPosition to pieces for easier access