javascript - border color change is working only for first time -


i trying make javascript based small game.

here fiddle game

it working except few issues:-

  1. on click of td, if image in td, cell border color should green otherwise if have clicked on wrong td, border color turns red.
    functionality working first time start game. next time showing red border color.

  2. till level 8, changing of border color visible, increase level, user cannot experience whether has hit correct cell or not. want have hit correct cell, color change should visible , stable until image appears cell.

any improvement in code , suggestion appreciable.

when start game second time, call startgame().

in startgame() have $('td').click(), fire second time, on each click, actual click twice (one catch, 1 miss).


Comments

Popular posts from this blog

c# - Send Image in Json : 400 Bad request -

jquery - Fancybox - apply a function to several elements -

An easy way to program an Android keyboard layout app -