delete dead code and added notes on moving actions out of instructions