added 'hit' code