fixed a bug where we try and apply the action of a dead unit