improved error handling code when mapping EM engine cave/game elements