Added debugging mode for rogue, plus minor fixes